]> gerrit.simantics Code Review - simantics/sysdyn.git/commitdiff
Added splash.bmp and modified build to include the new OpenModelica
authorlempinen <lempinen@ac1ea38d-2e2b-0410-8846-a27921b304fc>
Mon, 2 May 2011 06:11:06 +0000 (06:11 +0000)
committerlempinen <lempinen@ac1ea38d-2e2b-0410-8846-a27921b304fc>
Mon, 2 May 2011 06:11:06 +0000 (06:11 +0000)
git-svn-id: https://www.simantics.org/svn/simantics/sysdyn/trunk@20693 ac1ea38d-2e2b-0410-8846-a27921b304fc

org.simantics.sysdyn.feature/feature.xml
org.simantics.sysdyn.ui/splash.bmp [new file with mode: 0644]
org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/properties/LabelPropertyTabContributor.java
org.simantics.sysdyn.ui/sysdyn.product

index 02b406c4b2a69f7d48c0b2b4e0c30389e74512bb..7b51cef13cd522ad45ba312e8833fdeea0a0619b 100644 (file)
          version="0.0.0"\r
          unpack="false"/>\r
 \r
-   <plugin\r
-         id="org.simantics.diagram.ontology"\r
-         download-size="0"\r
-         install-size="0"\r
-         version="0.0.0"\r
-         unpack="false"/>\r
-\r
-   <plugin\r
-         id="org.simantics.structural.ontology"\r
-         download-size="0"\r
-         install-size="0"\r
-         version="0.0.0"\r
-         unpack="false"/>\r
-\r
    <plugin\r
          id="org.simantics.sysdyn.ontology"\r
          download-size="0"\r
diff --git a/org.simantics.sysdyn.ui/splash.bmp b/org.simantics.sysdyn.ui/splash.bmp
new file mode 100644 (file)
index 0000000..cb932ea
Binary files /dev/null and b/org.simantics.sysdyn.ui/splash.bmp differ
index 392676a8975c1aa7426833b7a00c6e218b3ca3c9..b13a6fa207daa5d06a425e25903fdb95c934caa5 100644 (file)
@@ -26,6 +26,7 @@ import org.simantics.db.management.ISessionContext;
 import org.simantics.db.procedure.AsyncListener;\r
 import org.simantics.db.request.Read;\r
 import org.simantics.layer0.Layer0;\r
+import org.simantics.modeling.ModelingResources;\r
 import org.simantics.ui.SimanticsUI;\r
 import org.simantics.ui.utils.AdaptionUtils;\r
 import org.simantics.utils.datastructures.Callback;\r
@@ -50,8 +51,8 @@ public abstract class LabelPropertyTabContributor extends PropertyTabContributor
        \r
        @Override\r
     public void updatePartName(ISelection forSelection, final Callback<String> updateCallback) {\r
-       final Resource r = AdaptionUtils.adaptToSingle(forSelection, Resource.class);\r
-       if(r == null) {\r
+       final Resource resource = AdaptionUtils.adaptToSingle(forSelection, Resource.class);\r
+       if(resource == null) {\r
                updateCallback.run("Selection properties");\r
                return;\r
        }\r
@@ -62,6 +63,11 @@ public abstract class LabelPropertyTabContributor extends PropertyTabContributor
                                @Override\r
                                public String perform(ReadGraph graph) throws DatabaseException {\r
                                        Layer0 l0 = Layer0.getInstance(graph);\r
+                                       ModelingResources mr = ModelingResources.getInstance(graph);\r
+                                       Resource r = resource;\r
+                                       if(graph.hasStatement(r, mr.ElementToComponent)) {\r
+                                               r = graph.getSingleObject(r, mr.ElementToComponent);\r
+                                       }\r
                                        String label = graph.getPossibleRelatedValue(r, l0.HasLabel);\r
                                        if(label != null)\r
                                                return label;\r
index 9b282a0c8ffca6e1a8f68ee3df3832cb5a19b77b..a95881864858fe90bc8ca32224b1d88995c96374 100644 (file)
@@ -14,6 +14,8 @@
 \r
    <windowImages/>\r
 \r
+   <splash\r
+      location="org.simantics.sysdyn.ui" />\r
    <launcher name="Simantics-Sysdyn">\r
       <solaris/>\r
       <win useIco="false">\r