summaryrefslogtreecommitdiff
path: root/plugins/ui-designer-core/src/com/intellij/designer/propertyTable/PropertyTablePanel.java
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/ui-designer-core/src/com/intellij/designer/propertyTable/PropertyTablePanel.java')
-rw-r--r--plugins/ui-designer-core/src/com/intellij/designer/propertyTable/PropertyTablePanel.java7
1 files changed, 6 insertions, 1 deletions
diff --git a/plugins/ui-designer-core/src/com/intellij/designer/propertyTable/PropertyTablePanel.java b/plugins/ui-designer-core/src/com/intellij/designer/propertyTable/PropertyTablePanel.java
index a44a34398d3c..5ad9e4465ec5 100644
--- a/plugins/ui-designer-core/src/com/intellij/designer/propertyTable/PropertyTablePanel.java
+++ b/plugins/ui-designer-core/src/com/intellij/designer/propertyTable/PropertyTablePanel.java
@@ -23,6 +23,7 @@ import com.intellij.openapi.actionSystem.*;
import com.intellij.openapi.actionSystem.impl.ActionButton;
import com.intellij.openapi.project.Project;
import com.intellij.openapi.util.Comparing;
+import com.intellij.openapi.util.SystemInfo;
import com.intellij.openapi.wm.IdeFocusManager;
import com.intellij.ui.IdeBorderFactory;
import com.intellij.ui.PopupHandler;
@@ -85,7 +86,11 @@ public final class PropertyTablePanel extends JPanel implements ListSelectionLis
actionGroup.addSeparator();
RestoreDefault restoreDefault = new RestoreDefault(myPropertyTable);
- restoreDefault.registerCustomShortcutSet(actionManager.getAction(IdeActions.ACTION_DELETE).getShortcutSet(), myPropertyTable);
+ // Don't register ACTION_DELETE on Mac; on Mac, the default delete key is VK_DELETE rather than VK_BACK_SPACE
+ // which means users end up accidentally restoring to default when trying to edit inside property editors.
+ if (!SystemInfo.isMac) {
+ restoreDefault.registerCustomShortcutSet(actionManager.getAction(IdeActions.ACTION_DELETE).getShortcutSet(), myPropertyTable);
+ }
actionGroup.add(restoreDefault);
actionGroup.add(new ShowExpert(myPropertyTable));