use of org.pentaho.ui.xul.containers.XulDeck in project pentaho-kettle by pentaho.
the class TrashBrowseController method selectDeletedFileTable.
private XulTree selectDeletedFileTable(boolean isAdmin) {
XulDeck treeDeck = (XulDeck) document.getElementById("tree-deck");
treeDeck.setSelectedIndex(isAdmin ? 1 : 0);
return (XulTree) document.getElementById(isAdmin ? "deleted-file-table-admin" : "deleted-file-table");
}
use of org.pentaho.ui.xul.containers.XulDeck in project data-access by pentaho.
the class MainWizardController method setActiveStep.
public void setActiveStep(final int step) {
try {
if (this.steps == null || steps.isEmpty()) {
return;
}
final int oldActiveStep = this.activeStep;
if (oldActiveStep >= 0) {
final IWizardStep deactivatingWizardStep = steps.get(oldActiveStep);
if (step > oldActiveStep) {
if (!deactivatingWizardStep.stepDeactivatingForward()) {
return;
}
} else {
if (!deactivatingWizardStep.stepDeactivatingReverse()) {
return;
}
}
}
this.activeStep = step;
final IWizardStep activatingWizardStep = steps.get(activeStep);
updateBindings();
// update the controller panel
final XulDeck deck = (XulDeck) document.getElementById(CONTENT_DECK_ELEMENT_ID);
int index = deck.getChildNodes().indexOf(activatingWizardStep.getUIComponent());
deck.setSelectedIndex(index);
selectDataSourceMenuList(activatingWizardStep, index);
activatingWizardStep.refresh();
if (activeStep > oldActiveStep) {
activatingWizardStep.stepActivatingForward();
} else {
activatingWizardStep.stepActivatingReverse();
}
this.firePropertyChange(ACTIVE_STEP_PROPERTY_NAME, oldActiveStep, this.activeStep);
} catch (Exception e) {
e.printStackTrace();
}
}
Aggregations