projects
/
gpl
/
argeo-suite.git
/ commitdiff
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (from parent 1:
d5e0188
)
Working read-only DocBook
author
Mathieu Baudier <mbaudier@argeo.org>
Sat, 17 Jun 2023 10:51:05 +0000
(12:51 +0200)
committer
Mathieu Baudier <mbaudier@argeo.org>
Sat, 17 Jun 2023 10:51:05 +0000
(12:51 +0200)
org.argeo.product.knowledge/OSGI-INF/structureLayer.xml
patch
|
blob
|
history
org.argeo.product.knowledge/OSGI-INF/termsLayer.xml
patch
|
blob
|
history
swt/org.argeo.app.swt/src/org/argeo/app/swt/ux/DefaultEditionLayer.java
patch
|
blob
|
history
swt/org.argeo.app.swt/src/org/argeo/app/swt/ux/SwtAppUi.java
patch
|
blob
|
history
swt/org.argeo.app.ui/OSGI-INF/contentLayer.xml
patch
|
blob
|
history
swt/org.argeo.app.ui/OSGI-INF/leadPane.xml
patch
|
blob
|
history
diff --git
a/org.argeo.product.knowledge/OSGI-INF/structureLayer.xml
b/org.argeo.product.knowledge/OSGI-INF/structureLayer.xml
index 68753f69ebb494a34c23bd106e30217dd31fd9a6..5d77e201e2e923414cd23cb7b37c3e8635cbdccb 100644
(file)
--- a/
org.argeo.product.knowledge/OSGI-INF/structureLayer.xml
+++ b/
org.argeo.product.knowledge/OSGI-INF/structureLayer.xml
@@
-1,5
+1,5
@@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
-<scr:component xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0" name="argeo.product.knowledge.structureLayer">
+<scr:component xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0"
activate="init" deactivate="destroy"
name="argeo.product.knowledge.structureLayer">
<implementation class="org.argeo.app.swt.ux.DefaultEditionLayer"/>
<service>
<provide interface="org.argeo.app.swt.ux.SwtAppLayer"/>
<implementation class="org.argeo.app.swt.ux.DefaultEditionLayer"/>
<service>
<provide interface="org.argeo.app.swt.ux.SwtAppLayer"/>
diff --git
a/org.argeo.product.knowledge/OSGI-INF/termsLayer.xml
b/org.argeo.product.knowledge/OSGI-INF/termsLayer.xml
index 5849ebc14cd9f410b4ec9e51d68ff5636c883327..c3e88822b3e842f7068190e1f844b845aacff48e 100644
(file)
--- a/
org.argeo.product.knowledge/OSGI-INF/termsLayer.xml
+++ b/
org.argeo.product.knowledge/OSGI-INF/termsLayer.xml
@@
-1,5
+1,5
@@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
-<scr:component xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0" name="argeo.product.knowledge.termsLayer">
+<scr:component xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0"
activate="init" deactivate="destroy"
name="argeo.product.knowledge.termsLayer">
<implementation class="org.argeo.app.swt.ux.DefaultEditionLayer"/>
<service>
<provide interface="org.argeo.app.swt.ux.SwtAppLayer"/>
<implementation class="org.argeo.app.swt.ux.DefaultEditionLayer"/>
<service>
<provide interface="org.argeo.app.swt.ux.SwtAppLayer"/>
diff --git
a/swt/org.argeo.app.swt/src/org/argeo/app/swt/ux/DefaultEditionLayer.java
b/swt/org.argeo.app.swt/src/org/argeo/app/swt/ux/DefaultEditionLayer.java
index fd5dca7238c8483290e3ddd320a9a1219c732951..109dd22d4ffe88188887ff25369b3eea7688ff52 100644
(file)
--- a/
swt/org.argeo.app.swt/src/org/argeo/app/swt/ux/DefaultEditionLayer.java
+++ b/
swt/org.argeo.app.swt/src/org/argeo/app/swt/ux/DefaultEditionLayer.java
@@
-3,6
+3,7
@@
package org.argeo.app.swt.ux;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
+import java.util.Objects;
import org.argeo.api.acr.Content;
import org.argeo.app.ux.SuiteIcon;
import org.argeo.api.acr.Content;
import org.argeo.app.ux.SuiteIcon;
@@
-130,6
+131,7
@@
public class DefaultEditionLayer implements SwtAppLayer {
public void init(BundleContext bundleContext, Map<String, Object> properties) {
String pid = (String) properties.get(Constants.SERVICE_PID);
id = pid;
public void init(BundleContext bundleContext, Map<String, Object> properties) {
String pid = (String) properties.get(Constants.SERVICE_PID);
id = pid;
+ Objects.requireNonNull(id, "Layer id must be set.");
weights = LangUtils.toStringList(properties.get(Property.weights.name()));
startMaximized = properties.containsKey(Property.startMaximized.name())
weights = LangUtils.toStringList(properties.get(Property.weights.name()));
startMaximized = properties.containsKey(Property.startMaximized.name())
diff --git
a/swt/org.argeo.app.swt/src/org/argeo/app/swt/ux/SwtAppUi.java
b/swt/org.argeo.app.swt/src/org/argeo/app/swt/ux/SwtAppUi.java
index f5ad2572e7a1f46b10ba0c11c9a71238e6e18d03..9654a8ed81c67a8ee68e5e7c8565b7e773161c09 100644
(file)
--- a/
swt/org.argeo.app.swt/src/org/argeo/app/swt/ux/SwtAppUi.java
+++ b/
swt/org.argeo.app.swt/src/org/argeo/app/swt/ux/SwtAppUi.java
@@
-153,6
+153,11
@@
public class SwtAppUi extends CmsSwtUi implements AppUi {
}
public void addLayer(String id, SwtAppLayer layer) {
}
public void addLayer(String id, SwtAppLayer layer) {
+ if (!id.equals(layer.getId())) {
+ log.error("Layer id as key '" + id + "' is not consistent with layer id '" + layer.getId()
+ + "', ignoring...");
+ return;
+ }
layers.put(id, layer);
}
layers.put(id, layer);
}
diff --git
a/swt/org.argeo.app.ui/OSGI-INF/contentLayer.xml
b/swt/org.argeo.app.ui/OSGI-INF/contentLayer.xml
index 9a550f4445b99e3bef238168167b7da742eab47e..37622b82dca930035a3e4a3e25ba33cf16d768cf 100644
(file)
--- a/
swt/org.argeo.app.ui/OSGI-INF/contentLayer.xml
+++ b/
swt/org.argeo.app.ui/OSGI-INF/contentLayer.xml
@@
-1,5
+1,5
@@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="UTF-8"?>
-<scr:component xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0" name="Content Layer">
+<scr:component xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0"
activate="init" deactivate="destroy"
name="Content Layer">
<implementation class="org.argeo.app.swt.ux.DefaultEditionLayer"/>
<service>
<provide interface="org.argeo.app.swt.ux.SwtAppLayer"/>
<implementation class="org.argeo.app.swt.ux.DefaultEditionLayer"/>
<service>
<provide interface="org.argeo.app.swt.ux.SwtAppLayer"/>
diff --git
a/swt/org.argeo.app.ui/OSGI-INF/leadPane.xml
b/swt/org.argeo.app.ui/OSGI-INF/leadPane.xml
index 57a746863ba45222300aa9bea6a00b746db675f8..9c0df65b595826fdf441317aacf7e7cae83400e2 100644
(file)
--- a/
swt/org.argeo.app.ui/OSGI-INF/leadPane.xml
+++ b/
swt/org.argeo.app.ui/OSGI-INF/leadPane.xml
@@
-8,6
+8,7
@@
<properties entry="config/leadPane.properties"/>
<property name="defaultLayers" type="String">argeo.suite.ui.dashboardLayer
argeo.library.ui.contentLayer
<properties entry="config/leadPane.properties"/>
<property name="defaultLayers" type="String">argeo.suite.ui.dashboardLayer
argeo.library.ui.contentLayer
+argeo.product.knowledge.structureLayer
argeo.people.ui.peopleLayer
argeo.geo.ui.mapLayer
</property>
argeo.people.ui.peopleLayer
argeo.geo.ui.mapLayer
</property>