Example usage for org.eclipse.jface.preference IPreferenceStore setDefault

List of usage examples for org.eclipse.jface.preference IPreferenceStore setDefault

Introduction

In this page you can find the example usage for org.eclipse.jface.preference IPreferenceStore setDefault.

Prototype

void setDefault(String name, boolean value);

Source Link

Document

Sets the default value for the boolean-valued preference with the given name.

Usage

From source file:com.nokia.carbide.remoteconnections.RemoteConnectionsActivator.java

License:Open Source License

private void storeAgentRunningStates() {
    IPreferenceStore preferenceStore = getPreferenceStore();
    for (IDeviceDiscoveryAgent agent : discoveryAgents) {
        String agentKey = AGENT_STATE_KEY_PREFIX + agent.getId();
        if (!preferenceStore.contains(agentKey))
            preferenceStore.setDefault(agentKey, true);
        preferenceStore.setValue(agentKey, agent.isRunning());
    }//from  w w w.  j  av  a2s .  c o  m
    try {
        new InstanceScope().getNode(PLUGIN_ID).flush();
    } catch (BackingStoreException e) {
        logError(e);
    }
}

From source file:com.nokia.carbide.search.system.internal.ui.SearchPreferencePage.java

License:Open Source License

public static void initDefaults(IPreferenceStore store) {
    RGB gray = new RGB(85, 85, 85);
    store.setDefault(EMPHASIZE_POTENTIAL_MATCHES, true);
    store.setDefault(IGNORE_POTENTIAL_MATCHES, false);
    PreferenceConverter.setDefault(store, POTENTIAL_MATCH_FG_COLOR, gray);
    store.setDefault(REUSE_EDITOR, true);
    store.setDefault(DEFAULT_PERSPECTIVE, NO_DEFAULT_PERSPECTIVE);
    store.setDefault(TEXT_SEARCH_ENGINE, ""); //default search engine is empty string //$NON-NLS-1$
    store.setDefault(TEXT_SEARCH_QUERY_PROVIDER, ""); // default query provider is empty string  //$NON-NLS-1$
    store.setDefault(LIMIT_HISTORY, 10);
}

From source file:com.nokia.s60ct.gui.preferences.PreferenceInitializer.java

License:Open Source License

public void initializeDefaultPreferences() {
    IPreferenceStore store = Activator.getDefault().getPreferenceStore();
    store.setDefault(PreferenceConstants.DISPLAY_CLEANUP_DIALOG, false);
    store.setDefault(PreferenceConstants.OUTPUT_FOLDER, "result");
    store.setDefault(PreferenceConstants.USED_ENVIRONMENT, "");
}

From source file:com.nokia.s60tools.analyzetool.preferences.PreferenceInitializer.java

License:Open Source License

@Override
public void initializeDefaultPreferences() {

    IPreferenceStore store = Activator.getPreferences();

    store.setDefault(Constants.LOGGING_MODE, Constants.LOGGING_EXT_FAST);
    store.setDefault(Constants.REPORT_LEVEL, Constants.REPORT_KNOWN);
    store.setDefault(Constants.USE_INTERNAL, false);
    store.setDefault(Constants.ATOOL_FOLDER, Constants.DEFAULT_ATOOL_FOLDER);
    store.setDefault(Constants.USER_SELECTED_FOLDER, Constants.DEFAULT_ATOOL_FOLDER);
    store.setDefault(Constants.CREATE_STATISTIC, false);
    store.setDefault(Constants.USE_ROM_SYMBOL, false);
    store.setDefault(Constants.CALLSTACK_SIZE, 40);
    store.setDefault(Constants.LOGGING_FAST_ENABLED, false);
}

From source file:com.nokia.s60tools.compatibilityanalyser.ui.wizards.CompatibilityAnalyserPreferencesInitializer.java

License:Open Source License

@Override
public void initializeDefaultPreferences() {
    IPreferenceStore store = CompatibilityAnalyserPlugin.getCompatabilityAnalyserPrefStore();

    store.setDefault(CompatibilityAnalyserPreferencesConstants.DEFAULT_TOOLS, true);
    store.setDefault(CompatibilityAnalyserPreferencesConstants.LOCAL_TOOLS, false);
    store.setDefault(CompatibilityAnalyserPreferencesConstants.WEB_TOOLS, false);
    store.setDefault(CompatibilityAnalyserPreferencesConstants.SDK_TOOLS, false);

    store.setDefault(CompatibilityAnalyserPreferencesConstants.CORETOOLS_URL,
            Messages.getString("Coretools.URL"));
    store.setDefault(CompatibilityAnalyserPreferencesConstants.KNOWNISSUES_URL,
            Messages.getString("Knownissues.URL"));
    store.setDefault(CompatibilityAnalyserPreferencesConstants.BASELINES_URL,
            Messages.getString("BaselineSDK.URL"));

    store.setDefault(CompatibilityAnalyserPreferencesConstants.DEFAULT_ISSUES, true);
    store.setDefault(CompatibilityAnalyserPreferencesConstants.LATEST_ISSUES, false);
    store.setDefault(CompatibilityAnalyserPreferencesConstants.WEB_ISSUES, false);
    store.setDefault(CompatibilityAnalyserPreferencesConstants.LOCAL_ISSUES, false);

    store.setDefault(CompatibilityAnalyserPreferencesConstants.KNOWNISSUES_PATH_LOCAL, "");
    store.setDefault(CompatibilityAnalyserPreferencesConstants.LOCAL_TOOLS_PATH, "");

    store.setDefault(CompatibilityAnalyserPreferencesConstants.USERECURSION_LAST_SELECTION, false);
    store.setDefault(CompatibilityAnalyserPreferencesConstants.USEPLATFORMDATA_LAST_SELECTION, true);
    store.setDefault(CompatibilityAnalyserPreferencesConstants.FILTER_REPORTS_LAST_SELECTION, false);
}

From source file:com.nokia.s60tools.crashanalyser.ui.preferences.CrashAnalyserPreferenceInitializer.java

License:Open Source License

public void initializeDefaultPreferences() {
    IPreferenceStore store = CrashAnalyserPlugin.getCrashAnalyserPrefsStore();
    store.setDefault(CrashAnalyserPreferenceConstants.TRACE_LISTENER, true);
    store.setDefault(CrashAnalyserPreferenceConstants.EPOCWIND_LISTENER, false);
    store.setDefault(CrashAnalyserPreferenceConstants.SHOW_VISUALIZER, true);
}

From source file:com.nokia.s60tools.imaker.internal.preferences.ImageFlasherPreferencePage.java

License:Open Source License

private void initializeDefaults() {
    IPreferenceStore store = doGetPreferenceStore();
    store.setDefault(PreferenceConstants.PREFERENCES_DIRECTORY, ""); //$NON-NLS-1$
    store.setDefault(PreferenceConstants.CONFML_SELECTION_DIALOG, false);
}

From source file:com.nokia.sdt.preferences.PreferenceInitializer.java

License:Open Source License

public void initializeDefaultPreferences() {
    IPreferenceStore store = UIModelPlugin.getDefault().getPreferenceStore();
    store.setDefault(PreferenceConstants.P_PROMPT_BEFORE_EVENT_SAVE, true);
    store.setDefault(PreferenceConstants.P_DOUBLE_CLICK_BEHAVIOR, PreferenceConstants.EDIT_LABEL);
    store.setDefault(PreferenceConstants.P_PROMPT_BEFORE_UNDOING_SOURCE_SYNC, true);
    try {/*from w  ww. j a  va  2s.  c  o  m*/
        store.setDefault(PreferenceConstants.P_FILE_HEADER_TEMPLATE_LOCATION,
                getPathToDefaultTemplateLocation());
    } catch (IOException e) {
        // leave pref empty
    }

    /*
       store.setDefault(PreferenceConstants.P_BOOLEAN, true);
       store.setDefault(PreferenceConstants.P_CHOICE, "choice2");
       store.setDefault(PreferenceConstants.P_STRING,
    "Default value");
    */
}

From source file:com.nokia.testfw.codegen.ui.preferences.PreferenceInitializer.java

License:Open Source License

public void initializeDefaultPreferences() {
    IPreferenceStore store = CodegenUIPlugin.getDefault().getPreferenceStore();
    store.setDefault(PreferenceConstants.TEST_FOLDER_NAME, "tsrc");
    store.setDefault(PreferenceConstants.UID3_MAX_VALUE, "0x0EFFFFFF");
    store.setDefault(PreferenceConstants.UID3_MIN_VALUE, "0x0E000000");
    store.setDefault(PreferenceConstants.AUTHER, System.getProperty("user.name"));
}

From source file:com.nokia.testfw.stf.scripteditor.preference.PreferenceInitializer.java

License:Open Source License

@Override
public void initializeDefaultPreferences() {
    IPreferenceStore store = Activator.getDefault().getPreferenceStore();
    store.setDefault(PreferenceConstants.AUTO_ACTIVATION, "true");
    store.setDefault(PreferenceConstants.AUTO_ACTIVATION_DELAY, "200");
}