]> gerrit.simantics Code Review - simantics/platform.git/commitdiff
Merge "Support labels for property children"
authorTuukka Lehtonen <tuukka.lehtonen@semantum.fi>
Wed, 16 Aug 2017 12:11:47 +0000 (15:11 +0300)
committerGerrit Code Review <gerrit2@www.simantics.org>
Wed, 16 Aug 2017 12:11:47 +0000 (15:11 +0300)
bundles/org.simantics.browsing.ui.swt/src/org/simantics/browsing/ui/swt/widgets/GraphExplorerComposite.java
bundles/org.simantics.modeling.ui/plugin.xml
bundles/org.simantics.scl.compiler/src/org/simantics/scl/compiler/elaboration/expressions/EStringLiteral.java
bundles/org.simantics.scl.runtime/src/org/simantics/scl/runtime/either/Left.java

index f583d7e7f1df374f0466232cf40d786a4b14cf2b..249dad55ccc7c921e01fbff3e1a7730c97eab0ae 100644 (file)
@@ -373,6 +373,7 @@ public class GraphExplorerComposite extends Composite implements Widget, IAdapta
         } else {
                explorer = createExplorerControl(explorerComposite, maxChildren);
         }
+        explorer.addListener(new DefaultMouseListener(explorer));
         
         if (args.containsKey("useNodeBrowseContexts") && Boolean.TRUE.equals(args.get("useNodeBrowseContexts"))) {
                useNodeBrowseContexts = true;
index 64d39a0e2b8190edc26891ea37d6f43212dbcd79..7a29cd7864f0f8a1c4f0b00861ea2a25715acfb3 100644 (file)
          point="org.simantics.ui.doubleClick">
       <doubleClickAction
             name="Expand Browser Node"
-            priority="0.5"
+            priority="-1"
             class="org.simantics.modeling.ui.ExpandNodeHandler">
       </doubleClickAction>
    </extension>
index 58ec41fd2f74b85dbbaf4ee420601b9638ada5e8..ff830720c487ec68dbbb427c7c8d16464f7c9c91 100644 (file)
@@ -22,7 +22,9 @@ public class EStringLiteral extends ASTExpression {
         SCLValue showForPrinting = context.getEnvironment().getValue(Names.Prelude_showForPrinting);
         for(int i=0;i<expressions.length;++i)
             components[i] = new EApply(new EConstant(showForPrinting), expressions[i]);
-        return new EApply(new ELiteral(new StringInterpolation(strings)), components).resolve(context);
+        EApply result = new EApply(new ELiteral(new StringInterpolation(strings)), components);
+        result.setLocationDeep(location);
+        return result.resolve(context);
     }
 
     @Override
@@ -47,7 +49,9 @@ public class EStringLiteral extends ASTExpression {
             context.getErrorLog().log(location, "String interpolation can be a pattern only if has one hole.");
             return new EError();
         }
-        return new EApply(new ELiteral(new StringInterpolation(strings)), expressions);
+        EApply result = new EApply(new ELiteral(new StringInterpolation(strings)), expressions);
+        result.setLocationDeep(location);
+        return result;
     }
 
     @Override
index 1e0c29b1fde0449879333936297817e247a4cb45..7bc37bb349fb15f571c8f7ebc74baedcdb21bf8d 100644 (file)
@@ -18,7 +18,7 @@ public class Left implements Either {
             return true;
         if(obj == null || obj.getClass() != getClass())
             return false;
-        Right other = (Right)obj;
+        Left other = (Left)obj;
         return value == null ? other.value == null : value.equals(other.value);
     }