Change Eclipse-LazyStart: true to Bundle-ActivationPolicy: lazy (upgrade to The Equin...
[phpeclipse.git] / net.sourceforge.phpeclipse / src / net / sourceforge / phpdt / ui / PreferenceConstants.java
index c2b546c..60f8e03 100644 (file)
@@ -17,6 +17,7 @@ import net.sourceforge.phpeclipse.IPreferenceConstants;
 import net.sourceforge.phpeclipse.PHPeclipsePlugin;
 import net.sourceforge.phpeclipse.phpeditor.util.PHPColorProvider;
 
+import org.eclipse.core.runtime.Platform;
 import org.eclipse.jface.action.Action;
 import org.eclipse.jface.preference.IPreferenceStore;
 import org.eclipse.jface.preference.PreferenceConverter;
@@ -948,7 +949,7 @@ public class PreferenceConstants {
         * 
         * @since 2.1
         */
-       public final static String EDITOR_WRAP_STRINGS_SQ = "wrapStringsDQ"; //$NON-NLS-1$
+       public final static String EDITOR_WRAP_STRINGS_SQ = "wrapStringsSQ"; //$NON-NLS-1$
 
        /**
         * A named preference that controls whether the 'escape strings' feature is
@@ -1090,29 +1091,6 @@ public class PreferenceConstants {
        public final static String EDITOR_OVERVIEW_RULER = "overviewRuler"; //$NON-NLS-1$
 
        /**
-        * A named preference that controls if the line number ruler is shown in the
-        * UI.
-        * <p>
-        * Value is of type <code>Boolean</code>.
-        * </p>
-        */
-       public final static String EDITOR_LINE_NUMBER_RULER = "lineNumberRuler"; //$NON-NLS-1$
-
-       /**
-        * A named preference that holds the color used to render line numbers
-        * inside the line number ruler.
-        * <p>
-        * Value is of type <code>String</code>. A RGB color value encoded as a
-        * string using class <code>PreferenceConverter</code>
-        * </p>
-        * 
-        * @see org.eclipse.jface.resource.StringConverter
-        * @see org.eclipse.jface.preference.PreferenceConverter
-        * @see #EDITOR_LINE_NUMBER_RULER
-        */
-       public final static String EDITOR_LINE_NUMBER_RULER_COLOR = "lineNumberColor"; //$NON-NLS-1$
-
-       /**
         * A named preference that holds the color used to render linked positions
         * inside code templates.
         * <p>
@@ -1904,6 +1882,16 @@ public class PreferenceConstants {
        public static final String EDITOR_DISABLE_OVERWRITE_MODE = "disable_overwrite_mode"; //$NON-NLS-1$
 
        /**
+        * A named preference that controls saving of a file on loss of editor focus.
+        * <p>
+        * Value is of type <code>Boolean</code>.
+        * </p>
+        * 
+        * @since 3.0
+        */
+       public static final String EDITOR_SAVE_ON_BLUR = "save_on_blur"; //$NON-NLS-1$
+
+       /**
         * A named preference that controls the "smart semicolon" smart typing
         * handler
         * <p>
@@ -2749,11 +2737,6 @@ public class PreferenceConstants {
 
                store.setDefault(PreferenceConstants.EDITOR_OVERVIEW_RULER, true);
 
-               store.setDefault(PreferenceConstants.EDITOR_LINE_NUMBER_RULER, false);
-               PreferenceConverter.setDefault(store,
-                               PreferenceConstants.EDITOR_LINE_NUMBER_RULER_COLOR, new RGB(0,
-                                               0, 0));
-
                // WorkbenchChainedTextFontFieldEditor.startPropagate(store,
                // JFaceResources.TEXT_FONT);
 
@@ -2944,7 +2927,10 @@ public class PreferenceConstants {
                store.setDefault(PreferenceConstants.EDITOR_CTRL_ALT_SHIFT_HOVER,
                                PreferenceConstants.EDITOR_DEFAULT_HOVER_CONFIGURED_ID);
 
-               String ctrl = Action.findModifierString(SWT.CTRL);
+               int modifier = SWT.CTRL;
+               if (Platform.getOS().equals(Platform.OS_MACOSX))
+                       modifier = SWT.COMMAND;
+               String ctrl = Action.findModifierString(modifier);
                store
                                .setDefault(
                                                PreferenceConstants.EDITOR_TEXT_HOVER_MODIFIERS,
@@ -2952,7 +2938,7 @@ public class PreferenceConstants {
                store
                                .setDefault(
                                                PreferenceConstants.EDITOR_TEXT_HOVER_MODIFIER_MASKS,
-                                               "net.sourceforge.phpdt.ui.BestMatchHover;0;net.sourceforge.phpdt.ui.JavaSourceHover;" + SWT.CTRL); //$NON-NLS-1$
+                                               "net.sourceforge.phpdt.ui.BestMatchHover;0;net.sourceforge.phpdt.ui.JavaSourceHover;" + modifier); //$NON-NLS-1$
                store.setDefault(PreferenceConstants.EDITOR_SHOW_TEXT_HOVER_AFFORDANCE,
                                true);
 
@@ -2963,7 +2949,7 @@ public class PreferenceConstants {
                store
                                .setDefault(
                                                PreferenceConstants.EDITOR_BROWSER_LIKE_LINKS_KEY_MODIFIER_MASK,
-                                               SWT.CTRL);
+                                               modifier);
 
                // mark occurrences
                store.setDefault(PreferenceConstants.EDITOR_MARK_OCCURRENCES, true);