use of org.talend.dataprofiler.core.ui.utils.OpeningHelpWizardDialog in project tdq-studio-se by Talend.
the class CreateDateAnalysisAction method getPredefinedDialog.
@Override
protected WizardDialog getPredefinedDialog() {
AnalysisParameter parameter = new AnalysisParameter();
parameter.setConnectionRepNode(getColumns()[0]);
ColumnWizard wizard = (ColumnWizard) WizardFactory.createAnalysisWizard(AnalysisType.MULTIPLE_COLUMN, parameter);
wizard.setForcePreviousAndNextButtons(true);
TimeSliceOptionPage page = new TimeSliceOptionPage();
wizard.setExtenalPages(new WizardPage[] { page });
return new OpeningHelpWizardDialog(null, wizard, FormEnum.TimeSlicesForm.getHelpHref(), page);
}
use of org.talend.dataprofiler.core.ui.utils.OpeningHelpWizardDialog in project tdq-studio-se by Talend.
the class AnalysisTableTreeViewer method openIndicatorOptionDialog.
/*
* (non-Javadoc)
*
* @see
* org.talend.dataprofiler.core.ui.editor.composite.AbstractColumnDropTree#openIndicatorOptionDialog(org.eclipse
* .swt.widgets.Shell, org.eclipse.swt.widgets.TreeItem)
*/
@Override
public boolean openIndicatorOptionDialog(Shell shell, TreeItem indicatorItem) {
if (isDirty()) {
masterPage.doSave(null);
}
TableIndicatorUnit indicatorUnit = (TableIndicatorUnit) indicatorItem.getData(INDICATOR_UNIT_KEY);
if (FormEnum.isExsitingForm(indicatorUnit)) {
TableIndicatorOptionsWizard wizard = new TableIndicatorOptionsWizard(indicatorUnit);
String href = FormEnum.getFirstFormHelpHref(indicatorUnit);
OpeningHelpWizardDialog optionDialog = new OpeningHelpWizardDialog(shell, wizard, href);
optionDialog.create();
if (Window.OK == optionDialog.open()) {
setDirty(wizard.isDirty());
return hasIndicatorParameters(indicatorUnit);
}
} else {
openNoIndicatorOptionsMessageDialog(shell);
}
return false;
}
use of org.talend.dataprofiler.core.ui.utils.OpeningHelpWizardDialog 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;
}
use of org.talend.dataprofiler.core.ui.utils.OpeningHelpWizardDialog in project tdq-studio-se by Talend.
the class CreatePatternAction method run.
/*
* (non-Javadoc)
*
* @see org.eclipse.jface.action.Action#run()
*/
@Override
public void run() {
if (folder.exists()) {
PatternParameter parameter = new PatternParameter();
FolderProvider folderProvider = new FolderProvider();
folderProvider.setFolderResource(folder);
parameter.setFolderProvider(folderProvider);
CreatePatternWizard fileWizard;
if (this.expression != null && this.lanuage != null) {
fileWizard = (CreatePatternWizard) WizardFactory.createPatternWizard(type, parameter, expression, lanuage);
} else {
fileWizard = (CreatePatternWizard) WizardFactory.createPatternWizard(type, parameter);
}
fileWizard.setPurpose(purpose);
IContext context = HelpSystem.getContext(HelpPlugin.getDefault().getPatternHelpContextID());
IHelpResource[] relatedTopics = context.getRelatedTopics();
String href = relatedTopics[0].getHref();
switch(type) {
case SQL_LIKE:
href = relatedTopics[1].getHref();
break;
default:
break;
}
WizardDialog dialog = new OpeningHelpWizardDialog(Display.getDefault().getActiveShell(), fileWizard, href);
fileWizard.setWindowTitle(getText());
if (WizardDialog.OK == dialog.open())
ProxyRepositoryManager.getInstance().save();
}
}
use of org.talend.dataprofiler.core.ui.utils.OpeningHelpWizardDialog in project tdq-studio-se by Talend.
the class ExportPatternsAction method run.
@Override
public void run() {
Wizard wizard = isForExchange ? new ExportForExchangeWizard(folder.getFullPath().toString()) : new ExportPatternsWizard(node, isForExchange);
WizardDialog dialog = null;
// MOD hcheng 2009-07-07,for 8122.Add an help file in the "Export patterns for Talend exchange wizard".
if (isForExchange) {
IContext context = HelpSystem.getContext(HelpPlugin.getDefault().getPatternHelpContextID());
IHelpResource[] relatedTopics = context.getRelatedTopics();
String href = relatedTopics[3].getHref();
dialog = new OpeningHelpWizardDialog(null, wizard, href);
} else {
// MOD yyi 2009-08-20,for 8689.Add help in "export pattern" wizard.
IContext context = HelpSystem.getContext(HelpPlugin.getDefault().getPatternHelpContextID());
IHelpResource[] relatedTopics = context.getRelatedTopics();
String href = relatedTopics[4].getHref();
dialog = new OpeningHelpWizardDialog(null, wizard, href);
}
wizard.setWindowTitle(getText());
if (WizardDialog.OK == dialog.open()) {
try {
folder.refreshLocal(IResource.DEPTH_INFINITE, null);
} catch (CoreException e) {
log.error(e, e);
}
}
}
Aggregations