]> gerrit.simantics Code Review - simantics/platform.git/blobdiff - bundles/org.simantics.modeling.ui/src/org/simantics/modeling/ui/preferences/PreferenceInitializer.java
Fixed all line endings of the repository
[simantics/platform.git] / bundles / org.simantics.modeling.ui / src / org / simantics / modeling / ui / preferences / PreferenceInitializer.java
index 28a845b26e58d0b4e7dc2f4d824c3672af7fab9f..526081ec66bcaccd49893e613273de3856c2fb45 100644 (file)
@@ -1,43 +1,43 @@
-/*******************************************************************************\r
- * Copyright (c) 2007, 2010 Association for Decentralized Information Management\r
- * in Industry THTH ry.\r
- * All rights reserved. This program and the accompanying materials\r
- * are made available under the terms of the Eclipse Public License v1.0\r
- * which accompanies this distribution, and is available at\r
- * http://www.eclipse.org/legal/epl-v10.html\r
- *\r
- * Contributors:\r
- *     VTT Technical Research Centre of Finland - initial API and implementation\r
- *******************************************************************************/\r
-package org.simantics.modeling.ui.preferences;\r
-\r
-import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;\r
-import org.eclipse.core.runtime.preferences.DefaultScope;\r
-import org.eclipse.core.runtime.preferences.IScopeContext;\r
-import org.osgi.service.prefs.Preferences;\r
-import org.simantics.modeling.ui.Activator;\r
-import org.simantics.utils.page.PageDesc;\r
-\r
-public class PreferenceInitializer extends AbstractPreferenceInitializer {\r
-\r
-    /* (non-Javadoc)\r
-     * @see org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer#initializeDefaultPreferences()\r
-     */\r
-    @Override\r
-    public void initializeDefaultPreferences() {\r
-        IScopeContext context = DefaultScope.INSTANCE;\r
-        Preferences node = context.getNode(Activator.PLUGIN_ID);\r
-\r
-        node.putDouble(DiagramPreferences.P_SNAP_GRID_SIZE, DiagramPreferences.DEFAULT_SNAP_GRID_SIZE);\r
-        node.put(DiagramPreferences.P_DEFAULT_PAGE_SIZE, PageDesc.serialize(DiagramPreferences.DEFAULT_PAGE_SIZE));\r
-//        node.put(DiagramPreferences.P_DEFAULT_PAGE_ORIENTATION, DiagramPreferences.DEFAULT_PAGE_ORIENTATION.toString());\r
-//        node.put(DiagramPreferences.P_DEFAULT_PAGE_MARGINS, PageDesc.serialize(DiagramPreferences.DEFAULT_PAGE_MARGINS));\r
-        node.putBoolean(DiagramPreferences.P_DISPLAY_PAGE_SIZE, DiagramPreferences.DEFAULT_DISPLAY_PAGE_SIZE);\r
-        node.putBoolean(DiagramPreferences.P_DISPLAY_MARGINS, DiagramPreferences.DEFAULT_DISPLAY_MARGINS);\r
-        node.putBoolean(DiagramPreferences.P_DISPLAY_GRID, DiagramPreferences.DEFAULT_DISPLAY_GRID);\r
-        node.putBoolean(DiagramPreferences.P_DISPLAY_RULER, DiagramPreferences.DEFAULT_DISPLAY_RULER);\r
-\r
-        node.put(ModelingPreferences.P_PROPERTY_PIN_MODE, ModelingPreferences.DEFAULT_PIN_MODE.name());\r
-    }\r
-\r
-}\r
+/*******************************************************************************
+ * Copyright (c) 2007, 2010 Association for Decentralized Information Management
+ * in Industry THTH ry.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ *     VTT Technical Research Centre of Finland - initial API and implementation
+ *******************************************************************************/
+package org.simantics.modeling.ui.preferences;
+
+import org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer;
+import org.eclipse.core.runtime.preferences.DefaultScope;
+import org.eclipse.core.runtime.preferences.IScopeContext;
+import org.osgi.service.prefs.Preferences;
+import org.simantics.modeling.ui.Activator;
+import org.simantics.utils.page.PageDesc;
+
+public class PreferenceInitializer extends AbstractPreferenceInitializer {
+
+    /* (non-Javadoc)
+     * @see org.eclipse.core.runtime.preferences.AbstractPreferenceInitializer#initializeDefaultPreferences()
+     */
+    @Override
+    public void initializeDefaultPreferences() {
+        IScopeContext context = DefaultScope.INSTANCE;
+        Preferences node = context.getNode(Activator.PLUGIN_ID);
+
+        node.putDouble(DiagramPreferences.P_SNAP_GRID_SIZE, DiagramPreferences.DEFAULT_SNAP_GRID_SIZE);
+        node.put(DiagramPreferences.P_DEFAULT_PAGE_SIZE, PageDesc.serialize(DiagramPreferences.DEFAULT_PAGE_SIZE));
+//        node.put(DiagramPreferences.P_DEFAULT_PAGE_ORIENTATION, DiagramPreferences.DEFAULT_PAGE_ORIENTATION.toString());
+//        node.put(DiagramPreferences.P_DEFAULT_PAGE_MARGINS, PageDesc.serialize(DiagramPreferences.DEFAULT_PAGE_MARGINS));
+        node.putBoolean(DiagramPreferences.P_DISPLAY_PAGE_SIZE, DiagramPreferences.DEFAULT_DISPLAY_PAGE_SIZE);
+        node.putBoolean(DiagramPreferences.P_DISPLAY_MARGINS, DiagramPreferences.DEFAULT_DISPLAY_MARGINS);
+        node.putBoolean(DiagramPreferences.P_DISPLAY_GRID, DiagramPreferences.DEFAULT_DISPLAY_GRID);
+        node.putBoolean(DiagramPreferences.P_DISPLAY_RULER, DiagramPreferences.DEFAULT_DISPLAY_RULER);
+
+        node.put(ModelingPreferences.P_PROPERTY_PIN_MODE, ModelingPreferences.DEFAULT_PIN_MODE.name());
+    }
+
+}