Java Code Examples for org.pentaho.ui.xul.components.XulMessageBox#setModalParent()
The following examples show how to use
org.pentaho.ui.xul.components.XulMessageBox#setModalParent() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: BaseStepGenericXulDialog.java From pentaho-kettle with Apache License 2.0 | 6 votes |
public int showPromptMessage( final String message, final String title, Object[] buttons ) { try { final XulMessageBox msg = (XulMessageBox) document.createElement( "messagebox" ); msg.setModalParent( modalParent ); msg.setTitle( title ); msg.setMessage( message ); msg.setButtons( buttons ); return msg.open(); } catch ( XulException e ) { log.logError( "Error displaying message: {0}", message ); } return -1; }
Example 2
Source File: XulDatabaseExplorerController.java From pentaho-kettle with Apache License 2.0 | 6 votes |
public void displayRowCount() { if ( this.model.getTable() == null ) { return; } try { GetTableSizeProgressDialog pd = new GetTableSizeProgressDialog( this.dbExplorerDialog.getShell(), this.model.getDatabaseMeta(), this.model.getTable(), model .getSchema() ); Long theCount = pd.open(); if ( theCount != null ) { XulMessageBox theMessageBox = (XulMessageBox) document.createElement( "messagebox" ); theMessageBox.setModalParent( this.dbExplorerDialog.getShell() ); theMessageBox.setTitle( BaseMessages.getString( PKG, "DatabaseExplorerDialog.TableSize.Title" ) ); theMessageBox.setMessage( BaseMessages.getString( PKG, "DatabaseExplorerDialog.TableSize.Message", this.model.getTable(), theCount.toString() ) ); theMessageBox.open(); } } catch ( XulException e ) { LogChannel.GENERAL.logError( "Error displaying row count", e ); } }
Example 3
Source File: BaseStepGenericXulDialog.java From pentaho-kettle with Apache License 2.0 | 5 votes |
public void showMessage( final String message, final String title ) { try { final XulMessageBox msg = (XulMessageBox) document.createElement( "messagebox" ); msg.setModalParent( modalParent ); msg.setTitle( title ); msg.setMessage( message ); msg.open(); } catch ( XulException e ) { log.logError( "Error displaying message: {0}", message ); } }
Example 4
Source File: DataHandler.java From pentaho-kettle with Apache License 2.0 | 5 votes |
protected void showMessage( String message, boolean scroll ) { try { XulMessageBox box = (XulMessageBox) document.createElement( "messagebox" ); box.setMessage( message ); box.setModalParent( ( (XulRoot) document.getElementById( "general-datasource-window" ) ).getRootObject() ); if ( scroll ) { box.setScrollable( true ); box.setWidth( 500 ); box.setHeight( 400 ); } box.open(); } catch ( XulException e ) { System.out.println( "Error creating messagebox " + e.getMessage() ); } }