Search in sources :

Example 1 with IndicatorOptionsWizard

use of org.talend.dataprofiler.core.ui.wizard.indicator.IndicatorOptionsWizard in project tdq-studio-se by Talend.

the class AbstractColumnDropTree method openIndicatorOptionDialog.

/**
 * open Indicator Option Dialog.
 *
 * @param shell
 * @param indicatorItem
 * @return
 */
public boolean openIndicatorOptionDialog(Shell shell, TreeItem indicatorItem) {
    IndicatorUnit indicatorUnit = (IndicatorUnit) indicatorItem.getData(INDICATOR_UNIT_KEY);
    if (FormEnum.isExsitingForm(indicatorUnit)) {
        IndicatorOptionsWizard wizard = new IndicatorOptionsWizard(indicatorUnit);
        String href = FormEnum.getFirstFormHelpHref(indicatorUnit);
        OpeningHelpWizardDialog optionDialog = new OpeningHelpWizardDialog(shell, wizard, href);
        if (Window.OK == optionDialog.open()) {
            setDirty(wizard.isDirty());
            return hasIndicatorParameters(indicatorUnit);
        }
    } else {
        openNoIndicatorOptionsMessageDialog(shell);
    }
    return false;
}
Also used : IndicatorUnit(org.talend.dataprofiler.core.ui.editor.preview.IndicatorUnit) OpeningHelpWizardDialog(org.talend.dataprofiler.core.ui.utils.OpeningHelpWizardDialog) IndicatorOptionsWizard(org.talend.dataprofiler.core.ui.wizard.indicator.IndicatorOptionsWizard)

Example 2 with IndicatorOptionsWizard

use of org.talend.dataprofiler.core.ui.wizard.indicator.IndicatorOptionsWizard in project tdq-studio-se by Talend.

the class IndicatorsComp method openIndicatorOptionDialog.

public boolean openIndicatorOptionDialog(Shell shell, TreeItem indicatorItem) {
    if (isDirty()) {
        masterPage.doSave(null);
    }
    ColumnSetIndicatorUnit indicatorUnit = (ColumnSetIndicatorUnit) indicatorItem.getData(INDICATOR_KEY);
    if (indicatorUnit.isExsitingForm()) {
        IndicatorOptionsWizard wizard = new IndicatorOptionsWizard(indicatorUnit);
        String href = FormEnum.getFirstFormHelpHref(indicatorUnit);
        OpeningHelpWizardDialog optionDialog = new OpeningHelpWizardDialog(shell, wizard, href);
        if (Window.OK == optionDialog.open()) {
            masterPage.setDirty(wizard.isDirty());
            return hasIndicatorParameters(indicatorUnit.getIndicator());
        }
    } else {
        // $NON-NLS-1$
        MessageDialogWithToggle.openInformation(// $NON-NLS-1$
        shell, // $NON-NLS-1$
        DefaultMessagesImpl.getString("AnalysisColumnTreeViewer.information"), // $NON-NLS-1$
        DefaultMessagesImpl.getString("AnalysisColumnTreeViewer.nooption"));
    }
    return false;
}
Also used : OpeningHelpWizardDialog(org.talend.dataprofiler.core.ui.utils.OpeningHelpWizardDialog) IndicatorOptionsWizard(org.talend.dataprofiler.core.ui.wizard.indicator.IndicatorOptionsWizard) ColumnSetIndicatorUnit(org.talend.dataprofiler.core.ui.editor.preview.ColumnSetIndicatorUnit)

Aggregations

OpeningHelpWizardDialog (org.talend.dataprofiler.core.ui.utils.OpeningHelpWizardDialog)2 IndicatorOptionsWizard (org.talend.dataprofiler.core.ui.wizard.indicator.IndicatorOptionsWizard)2 ColumnSetIndicatorUnit (org.talend.dataprofiler.core.ui.editor.preview.ColumnSetIndicatorUnit)1 IndicatorUnit (org.talend.dataprofiler.core.ui.editor.preview.IndicatorUnit)1