Examples of ScopedPreferenceStore


Examples of org.eclipse.ui.preferences.ScopedPreferenceStore

  public static String getDevicePortNumber() {
      return plugin.getPreferenceStore().getString(PORT_NUMBER_SETTING);
  }

  public static String getPathToAdb() {
      IPreferenceStore ps = new ScopedPreferenceStore(InstanceScope.INSTANCE,
              "com.android.ide.eclipse.adt");
      return ps.getString("com.android.ide.eclipse.adt.sdk") + File.separator + "platform-tools" + File.separator;
  }
View Full Code Here

Examples of org.eclipse.ui.preferences.ScopedPreferenceStore

  private ScopedPreferenceStore preferenceStore;

  public static final String LINK_WITH_EDITOR_KEY = "linkWithEditor";

  public RailroadViewPreferences() {
    preferenceStore = new ScopedPreferenceStore(ConfigurationScope.INSTANCE, "ANTLR Syntax Diagram");
  }
View Full Code Here

Examples of org.eclipse.ui.preferences.ScopedPreferenceStore

     * @return the preference store
     */
    public IPreferenceStore getPreferenceStore() {
        // Create the preference store lazily.
        if (preferenceStore == null) {
            preferenceStore = new ScopedPreferenceStore(new InstanceScope(),getBundle().getSymbolicName());
        }
        return preferenceStore;
    }
View Full Code Here

Examples of org.eclipse.ui.preferences.ScopedPreferenceStore

  /** */
  public WindowCachePreferencePage() {
    super(GRID);
    setTitle(UIText.WindowCachePreferencePage_title);
    ScopedPreferenceStore store = new ScopedPreferenceStore(
        InstanceScope.INSTANCE, Activator.getPluginId());
    setPreferenceStore(store);
  }
View Full Code Here

Examples of org.eclipse.ui.preferences.ScopedPreferenceStore

  /**
   * The default constructor
   */
  public ProjectsPreferencePage() {
    super(GRID);
    ScopedPreferenceStore store = new ScopedPreferenceStore(
        InstanceScope.INSTANCE, Activator.getPluginId());
    setPreferenceStore(store);
  }
View Full Code Here

Examples of org.eclipse.ui.preferences.ScopedPreferenceStore

    return plugin;
  }

  public IPreferenceStore getPreferenceStore() {
    if (this.preferenceStore == null) {
      this.preferenceStore = new ScopedPreferenceStore(InstanceScope.INSTANCE, getBundle().getSymbolicName());

    }
    return this.preferenceStore;
  }
View Full Code Here

Examples of org.eclipse.ui.preferences.ScopedPreferenceStore

  public ProjectTemplateStore(IProject project) {
    fInstanceStore = PHPUiPlugin.getDefault().getCodeTemplateStore();
    if (project == null) {
      fProjectStore = null;
    } else {
      final ScopedPreferenceStore projectSettings = new ScopedPreferenceStore(
          new ProjectScope(project), PHPUiPlugin.ID);
      fProjectStore = new TemplateStore(projectSettings, KEY) {
        /*
         * Make sure we keep the id of added code templates - add
         * removes it in the usual add() method
         */
        public void add(TemplatePersistenceData data) {
          internalAdd(data);
        }

        public void save() throws IOException {

          StringWriter output = new StringWriter();
          TemplateReaderWriter writer = new TemplateReaderWriter();
          writer.save(getTemplateData(false), output);

          projectSettings.setValue(KEY, output.toString());
          projectSettings.save();
        }
      };
    }
  }
View Full Code Here

Examples of org.eclipse.ui.preferences.ScopedPreferenceStore

    }

    public ArduinoPreferencePage() {
  super(org.eclipse.jface.preference.FieldEditorPreferencePage.GRID);
  setDescription("Arduino Settings for this workspace");
  setPreferenceStore(new ScopedPreferenceStore(InstanceScope.INSTANCE, ArduinoConst.NODE_ARDUINO));
    }
View Full Code Here

Examples of org.eclipse.ui.preferences.ScopedPreferenceStore

      }
      public void removeListener(ILabelProviderListener listener) {
      }
    });
   
    ScopedPreferenceStore store = new ScopedPreferenceStore(
        new ProjectScope(getProject()), ClickPlugin.PLUGIN_ID);
    String vars = store.getString(ClickPlugin.PREF_VELOCITY_VARS);
    if(vars != null && vars.length() > 0){
      models = VariableModel.deserialize(vars);
    }
   
    viewer.setInput(models);
View Full Code Here

Examples of org.eclipse.ui.preferences.ScopedPreferenceStore

    models.clear();
    super.performDefaults();
  }

  public boolean performOk() {
    ScopedPreferenceStore store = new ScopedPreferenceStore(
        new ProjectScope(getProject()), ClickPlugin.PLUGIN_ID);
    store.setValue(ClickPlugin.PREF_VELOCITY_VARS, VariableModel.serialize(models));
    try {
      store.save();
    } catch(IOException ex){
      ClickPlugin.log(ex);
      return false;
    }
    return super.performOk();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.