Java Code Examples for org.eclipse.jface.dialogs.IDialogSettings#addNewSection()
The following examples show how to use
org.eclipse.jface.dialogs.IDialogSettings#addNewSection() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: RecentSettingsStore.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 6 votes |
public void store(IDialogSettings settings) { IDialogSettings projectsSection= settings.addNewSection(SECTION_PROJECTS); //Write all project information to DialogSettings. Set<IJavaProject> keys= fPerProjectSettings.keySet(); for (Iterator<IJavaProject> iter= keys.iterator(); iter.hasNext();) { IJavaProject curr= iter.next(); IDialogSettings proj= projectsSection.addNewSection(curr.getElementName()); if (!keys.contains(curr)) { proj.put(HREF, ""); //$NON-NLS-1$ proj.put(DESTINATION, ""); //$NON-NLS-1$ proj.put(ANTPATH, ""); //$NON-NLS-1$ } else { ProjectData data= fPerProjectSettings.get(curr); proj.put(HREF, data.getHRefs()); proj.put(DESTINATION, data.getDestination()); proj.put(ANTPATH, data.getAntPath()); } projectsSection.addSection(proj); } }
Example 2
Source File: ClasspathContainerSelectionPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 6 votes |
/** * Constructor for ClasspathContainerWizardPage. * * @param containerPages the array of container pages */ protected ClasspathContainerSelectionPage(ClasspathContainerDescriptor[] containerPages) { super("ClasspathContainerWizardPage"); //$NON-NLS-1$ setTitle(NewWizardMessages.ClasspathContainerSelectionPage_title); setDescription(NewWizardMessages.ClasspathContainerSelectionPage_description); setImageDescriptor(JavaPluginImages.DESC_WIZBAN_ADD_LIBRARY); fContainers= containerPages; IDialogSettings settings= JavaPlugin.getDefault().getDialogSettings(); fDialogSettings= settings.getSection(DIALOGSTORE_SECTION); if (fDialogSettings == null) { fDialogSettings= settings.addNewSection(DIALOGSTORE_SECTION); fDialogSettings.put(DIALOGSTORE_CONTAINER_IDX, 0); } validatePage(); }
Example 3
Source File: HiveTab.java From neoscada with Eclipse Public License 1.0 | 5 votes |
private IDialogSettings getDialogBoundsSettings ( final String id ) { final IDialogSettings settings = Activator.getDefault ().getDialogSettings (); IDialogSettings section = settings.getSection ( id ); if ( section == null ) { section = settings.addNewSection ( id ); } return section; }
Example 4
Source File: TermBaseSearchDialog.java From tmxeditor8 with GNU General Public License v2.0 | 5 votes |
private IDialogSettings getDialogSettings() { IDialogSettings settings = Activator.getDefault().getDialogSettings(); IDialogSettings fDialogSettings = settings.getSection(getClass().getName()); if (fDialogSettings == null) fDialogSettings = settings.addNewSection(getClass().getName()); return fDialogSettings; }
Example 5
Source File: ExportTracePackageWizard.java From tracecompass with Eclipse Public License 2.0 | 5 votes |
/** * Constructor for the export trace wizard */ public ExportTracePackageWizard() { IDialogSettings workbenchSettings = Activator.getDefault().getDialogSettings(); IDialogSettings section = workbenchSettings .getSection(STORE_EXPORT_TRACE_WIZARD); if (section == null) { section = workbenchSettings.addNewSection(STORE_EXPORT_TRACE_WIZARD); } setDialogSettings(section); fSelectedTraces = new ArrayList<>(); }
Example 6
Source File: AddCmakeUndefineDialog.java From cmake4eclipse with Eclipse Public License 2.0 | 5 votes |
@Override protected IDialogSettings getDialogBoundsSettings() { IDialogSettings settings = Activator.getDefault().getDialogSettings(); IDialogSettings section = settings.getSection(DIALOG_SETTINGS_SECT); if (section == null) { section = settings.addNewSection(DIALOG_SETTINGS_SECT); } return section; }
Example 7
Source File: CommonsLangToStringDialogStrategy.java From jenerate with Eclipse Public License 1.0 | 5 votes |
@Override public void configureSpecificDialogSettings(IDialogSettings dialogSettings) { IDialogSettings toStringSettings = dialogSettings.getSection(SETTINGS_SECTION); if (toStringSettings == null) { toStringSettings = dialogSettings.addNewSection(SETTINGS_SECTION); } this.toStringDialogSettings = toStringSettings; toStringStyle = toStringSettings.get(SETTINGS_STYLE); if (toStringStyle == null) { toStringStyle = CommonsLangToStringStyle.NO_STYLE.getFullLibraryString(preferencesManager .getCurrentPreferenceValue(JeneratePreferences.PREFERED_COMMON_METHODS_CONTENT_STRATEGY)); } }
Example 8
Source File: FlameGraphView.java From tracecompass with Eclipse Public License 2.0 | 5 votes |
private void saveContentPresentationOption(ContentPresentation contentPresentation) { IDialogSettings settings = Activator.getDefault().getDialogSettings(); IDialogSettings section = settings.getSection(getClass().getName()); if (section == null) { section = settings.addNewSection(getClass().getName()); } section.put(CONTENT_PRESENTATION_OPTION_KEY, contentPresentation.name()); }
Example 9
Source File: JavaSearchPage.java From Eclipse-Postfix-Code-Completion with Eclipse Public License 1.0 | 5 votes |
/** * Stores the current configuration in the dialog store. */ private void writeConfiguration() { IDialogSettings s= getDialogSettings(); s.put(STORE_CASE_SENSITIVE, fIsCaseSensitive); s.put(STORE_INCLUDE_MASK, getIncludeMask()); int historySize= Math.min(fPreviousSearchPatterns.size(), HISTORY_SIZE); s.put(STORE_HISTORY_SIZE, historySize); for (int i= 0; i < historySize; i++) { IDialogSettings histSettings= s.addNewSection(STORE_HISTORY + i); SearchPatternData data= fPreviousSearchPatterns.get(i); data.store(histSettings); } }
Example 10
Source File: ProjectContentsLocationArea.java From APICloud-Studio with GNU General Public License v3.0 | 5 votes |
private IDialogSettings getDialogSettings() { IDialogSettings ideDialogSettings = IDEWorkbenchPlugin.getDefault().getDialogSettings(); IDialogSettings result = ideDialogSettings.getSection(getClass().getName()); if (result == null) { result = ideDialogSettings.addNewSection(getClass().getName()); } return result; }
Example 11
Source File: ExportProjectWizard.java From translationstudio8 with GNU General Public License v2.0 | 5 votes |
public ExportProjectWizard() { setWindowTitle(Messages.getString("wizard.ExportProjectWizard.title")); setNeedsProgressMonitor(true); IDialogSettings workbenchSettings = WorkbenchPlugin.getDefault().getDialogSettings(); IDialogSettings section = workbenchSettings .getSection("ExportProjectWizard");//$NON-NLS-1$ if (section == null) { section = workbenchSettings.addNewSection("ExportProjectWizard");//$NON-NLS-1$ } setDialogSettings(section); }
Example 12
Source File: EclipseFindSettings.java From APICloud-Studio with GNU General Public License v3.0 | 5 votes |
/** * Returns the dialog settings object used to share state between several find/replace dialogs. * * @return the dialog settings to be used */ private IDialogSettings getDialogSettings() { IDialogSettings settings = TextEditorPlugin.getDefault().getDialogSettings(); fDialogSettings = settings.getSection(FIND_REPLACE_DIALOG_CLASS_NAME); if (fDialogSettings == null) fDialogSettings = settings.addNewSection(FIND_REPLACE_DIALOG_CLASS_NAME); return fDialogSettings; }
Example 13
Source File: AddCmakeDefineDialog.java From cmake4eclipse with Eclipse Public License 2.0 | 5 votes |
@Override protected IDialogSettings getDialogBoundsSettings() { IDialogSettings settings = Activator.getDefault().getDialogSettings(); IDialogSettings section = settings.getSection(DIALOG_SETTINGS_SECT); if (section == null) { section = settings.addNewSection(DIALOG_SETTINGS_SECT); } return section; }
Example 14
Source File: BatchJobsDialog.java From tmxeditor8 with GNU General Public License v2.0 | 5 votes |
private IDialogSettings getDialogSettings() { IDialogSettings settings = Activator.getDefault().getDialogSettings(); IDialogSettings fDialogSettings = settings.getSection(getClass().getName()); if (fDialogSettings == null) fDialogSettings = settings.addNewSection(getClass().getName()); return fDialogSettings; }
Example 15
Source File: SearchIndexDataHistory.java From Pydev with Eclipse Public License 1.0 | 5 votes |
public SearchIndexDataHistory(IDialogSettings dialogSettings) { IDialogSettings section = dialogSettings.getSection(PAGE_NAME); if (section == null) { section = dialogSettings.addNewSection(PAGE_NAME); } this.settings = section; }
Example 16
Source File: ImportTraceWizard.java From tracecompass with Eclipse Public License 2.0 | 5 votes |
/** * Default constructor */ public ImportTraceWizard() { IDialogSettings workbenchSettings = Activator.getDefault().getDialogSettings(); IDialogSettings section = workbenchSettings.getSection(IMPORT_WIZARD); if (section == null) { section = workbenchSettings.addNewSection(IMPORT_WIZARD); } setDialogSettings(section); }
Example 17
Source File: ConfigurationWizardDialog.java From bonita-studio with GNU General Public License v2.0 | 5 votes |
public ConfigurationWizardDialog(Shell parentShell, IWizard newWizard) { super(parentShell, newWizard); IDialogSettings workbenchSettings = WorkbenchPlugin.getDefault().getDialogSettings(); dialogSettings = workbenchSettings.getSection(ConfigurationWizardDialog.class.getName()); if (dialogSettings == null) { dialogSettings = workbenchSettings.addNewSection(ConfigurationWizardDialog.class.getName()); } isSimpleMode = dialogSettings.getBoolean(CONFIGURATION_WIZARD_DIALOG_SIMPLE_MODE); }
Example 18
Source File: KeysPreferencePage.java From translationstudio8 with GNU General Public License v2.0 | 5 votes |
protected IDialogSettings getDialogSettings() { IDialogSettings workbenchSettings = WorkbenchPlugin.getDefault().getDialogSettings(); IDialogSettings settings = workbenchSettings.getSection(TAG_DIALOG_SECTION); if (settings == null) { settings = workbenchSettings.addNewSection(TAG_DIALOG_SECTION); } return settings; }
Example 19
Source File: FormatterModifyDialog.java From APICloud-Studio with GNU General Public License v3.0 | 5 votes |
private static IDialogSettings getDialogSettingsSection(IDialogSettings settings, String sectionId) { IDialogSettings section = settings.getSection(sectionId); if (section == null) { section = settings.addNewSection(sectionId); } return section; }
Example 20
Source File: FindReplaceDialog.java From tmxeditor8 with GNU General Public License v2.0 | 5 votes |
private IDialogSettings getDialogSettings() { IDialogSettings settings = Activator.getDefault().getDialogSettings(); IDialogSettings fDialogSettings = settings.getSection(getClass().getName()); if (fDialogSettings == null) fDialogSettings = settings.addNewSection(getClass().getName()); return fDialogSettings; }