Search in sources :

Example 6 with SwtBindingFactory

use of org.pentaho.ui.xul.swt.SwtBindingFactory in project pentaho-kettle by pentaho.

the class PartitionsController method doLazyInit.

protected boolean doLazyInit() {
    // Load the SWT Shell from the explorer dialog
    shell = ((SwtDialog) document.getElementById("repository-explorer-dialog")).getShell();
    try {
        mainController = (MainController) this.getXulDomContainer().getEventHandler("mainController");
    } catch (XulException e) {
        return false;
    }
    enableButtons(true, false, false);
    bf = new SwtBindingFactory();
    bf.setDocument(this.getXulDomContainer().getDocumentRoot());
    if (bf != null) {
        createBindings();
    }
    return true;
}
Also used : SwtBindingFactory(org.pentaho.ui.xul.swt.SwtBindingFactory) XulException(org.pentaho.ui.xul.XulException)

Example 7 with SwtBindingFactory

use of org.pentaho.ui.xul.swt.SwtBindingFactory in project pentaho-kettle by pentaho.

the class SecurityController method doLazyInit.

@Override
protected boolean doLazyInit() {
    try {
        mainController = (MainController) this.getXulDomContainer().getEventHandler("mainController");
    } catch (XulException e) {
        return false;
    }
    try {
        boolean serviceInitialized = initService();
        if (!serviceInitialized) {
            return false;
        }
    } catch (Exception e) {
        if (mainController == null || !mainController.handleLostRepository(e)) {
            throw new RuntimeException(e);
        }
        return false;
    }
    try {
        managed = service.isManaged();
        createModel();
        messageBox = (XulMessageBox) document.createElement("messagebox");
        bf = new SwtBindingFactory();
        bf.setDocument(this.getXulDomContainer().getDocumentRoot());
    } catch (Exception e) {
        if (mainController == null || !mainController.handleLostRepository(e)) {
            throw new RuntimeException(e);
        }
    }
    if (bf != null) {
        createBindings();
    }
    if (!managed) {
        showButtons(false, false, false);
    }
    setInitialDeck();
    return true;
}
Also used : SwtBindingFactory(org.pentaho.ui.xul.swt.SwtBindingFactory) XulException(org.pentaho.ui.xul.XulException) XulException(org.pentaho.ui.xul.XulException) ControllerInitializationException(org.pentaho.di.ui.repository.repositoryexplorer.ControllerInitializationException)

Example 8 with SwtBindingFactory

use of org.pentaho.ui.xul.swt.SwtBindingFactory in project pentaho-kettle by pentaho.

the class SlavesController method doLazyInit.

@Override
protected boolean doLazyInit() {
    // Load the SWT Shell from the explorer dialog
    shell = ((SwtDialog) document.getElementById("repository-explorer-dialog")).getShell();
    enableButtons(true, false, false);
    bf = new SwtBindingFactory();
    bf.setDocument(this.getXulDomContainer().getDocumentRoot());
    try {
        mainController = (MainController) this.getXulDomContainer().getEventHandler("mainController");
    } catch (XulException e) {
        return false;
    }
    if (bf != null) {
        createBindings();
    }
    return true;
}
Also used : SwtBindingFactory(org.pentaho.ui.xul.swt.SwtBindingFactory) XulException(org.pentaho.ui.xul.XulException)

Aggregations

SwtBindingFactory (org.pentaho.ui.xul.swt.SwtBindingFactory)8 XulException (org.pentaho.ui.xul.XulException)4 KettleException (org.pentaho.di.core.exception.KettleException)2 ControllerInitializationException (org.pentaho.di.ui.repository.repositoryexplorer.ControllerInitializationException)2 Before (org.junit.Before)1 ObjectId (org.pentaho.di.repository.ObjectId)1 RepositoryDirectoryInterface (org.pentaho.di.repository.RepositoryDirectoryInterface)1 RepositoryExtended (org.pentaho.di.repository.RepositoryExtended)1 UIObjectCreationException (org.pentaho.di.ui.repository.repositoryexplorer.model.UIObjectCreationException)1 UIRepositoryDirectory (org.pentaho.di.ui.repository.repositoryexplorer.model.UIRepositoryDirectory)1 KettleXulLoader (org.pentaho.di.ui.xul.KettleXulLoader)1 BindingFactory (org.pentaho.ui.xul.binding.BindingFactory)1 SwtXulRunner (org.pentaho.ui.xul.swt.SwtXulRunner)1