@Override public void widgetSelected(SelectionEvent e) { setDialogEnabled(fId, !((Button)e.widget).getSelection()); } });
@Override public void widgetSelected(SelectionEvent e) { setDialogEnabled(fId, !((Button)e.widget).getSelection()); } });
public void widgetSelected(SelectionEvent e) { setDialogEnabled(fId, !((Button)e.widget).getSelection()); } });
@Override protected void handleShellCloseEvent() { super.handleShellCloseEvent(); setDialogEnabled(fId, true); // don't store if closed without pressing a button }
@Override protected void handleShellCloseEvent() { super.handleShellCloseEvent(); setDialogEnabled(fId, true); // don't store if closed without pressing a button }
@Override protected void buttonPressed(int buttonId) { super.buttonPressed(buttonId); String[] buttonLabels= getButtonLabels(); int returnCode= getReturnCode(); if (returnCode < buttonLabels.length && IDialogConstants.CANCEL_LABEL.equals(buttonLabels[returnCode])) setDialogEnabled(fId, true); // don't store if cancelled }
@Override protected void buttonPressed(int buttonId) { super.buttonPressed(buttonId); String[] buttonLabels= getButtonLabels(); int returnCode= getReturnCode(); if (returnCode < buttonLabels.length && IDialogConstants.CANCEL_LABEL.equals(buttonLabels[returnCode])) setDialogEnabled(fId, true); // don't store if cancelled }
protected void warnAboutTypeCommentDeprecation() { String key= IUIConstants.DIALOGSTORE_TYPECOMMENT_DEPRECATED; if (OptionalMessageDialog.isDialogEnabled(key)) { TemplateStore templates= JavaPlugin.getDefault().getTemplateStore(); boolean isOldWorkspace= templates.findTemplate("filecomment") != null && templates.findTemplate("typecomment") != null; //$NON-NLS-1$ //$NON-NLS-2$ if (!isOldWorkspace) { OptionalMessageDialog.setDialogEnabled(key, false); } String title= NewWizardMessages.NewElementWizard_typecomment_deprecated_title; String message= NewWizardMessages.NewElementWizard_typecomment_deprecated_message; OptionalMessageDialog.open(key, getShell(), title, null, message, MessageDialog.INFORMATION, new String[] { IDialogConstants.OK_LABEL }, 0); } }
protected void warnAboutTypeCommentDeprecation() { String key= IUIConstants.DIALOGSTORE_TYPECOMMENT_DEPRECATED; if (OptionalMessageDialog.isDialogEnabled(key)) { TemplateStore templates= JavaPlugin.getDefault().getTemplateStore(); boolean isOldWorkspace= templates.findTemplate("filecomment") != null && templates.findTemplate("typecomment") != null; //$NON-NLS-1$ //$NON-NLS-2$ if (!isOldWorkspace) { OptionalMessageDialog.setDialogEnabled(key, false); } String title= NewWizardMessages.NewElementWizard_typecomment_deprecated_title; String message= NewWizardMessages.NewElementWizard_typecomment_deprecated_message; OptionalMessageDialog.open(key, getShell(), title, null, message, MessageDialog.INFORMATION, new String[] { IDialogConstants.OK_LABEL }, 0); } }
protected void warnAboutTypeCommentDeprecation() { String key= IUIConstants.DIALOGSTORE_TYPECOMMENT_DEPRECATED; if (OptionalMessageDialog.isDialogEnabled(key)) { TemplateStore templates= JavaPlugin.getDefault().getTemplateStore(); boolean isOldWorkspace= templates.findTemplate("filecomment") != null && templates.findTemplate("typecomment") != null; //$NON-NLS-1$ //$NON-NLS-2$ if (!isOldWorkspace) { OptionalMessageDialog.setDialogEnabled(key, false); } String title= NewWizardMessages.NewElementWizard_typecomment_deprecated_title; String message= NewWizardMessages.NewElementWizard_typecomment_deprecated_message; OptionalMessageDialog.open(key, getShell(), title, null, message, MessageDialog.INFORMATION, new String[] { IDialogConstants.OK_LABEL }, 0); } }