From fe30e5d556ee0c792de220bccbb9ec57f4085779 Mon Sep 17 00:00:00 2001 From: Antti Villberg Date: Mon, 29 May 2017 15:05:28 +0300 Subject: [PATCH] OpenDefaultEditor should not cache adapters that cannot be opened #7252 Change-Id: Idf1a4e15fd808c540934dbfc6bc75d5b72016a1b --- .../org/simantics/ui/workbench/editor/OpenDefaultEditor.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bundles/org.simantics.ui/src/org/simantics/ui/workbench/editor/OpenDefaultEditor.java b/bundles/org.simantics.ui/src/org/simantics/ui/workbench/editor/OpenDefaultEditor.java index 4e75611e0..341fbf3a6 100644 --- a/bundles/org.simantics.ui/src/org/simantics/ui/workbench/editor/OpenDefaultEditor.java +++ b/bundles/org.simantics.ui/src/org/simantics/ui/workbench/editor/OpenDefaultEditor.java @@ -46,7 +46,7 @@ public class OpenDefaultEditor implements IDoubleClickAction { protected void safeRun() throws Exception { super.safeRun(); - if (rememberChoice) { + if (rememberChoice && a.getPriority() >= 0) { // Make this choice the default for the next time. EditorRegistry.getInstance().getMappings().put(getResource(), getAdapter()); } -- 2.47.1