diff --git a/.gitignore b/.gitignore
index dfd7070..b87fbf1 100644
--- a/.gitignore
+++ b/.gitignore
@@ -32,6 +32,8 @@ build.number
/.settings/
/junit/
/target/
+/__pycache__/
+
*.pdfd
*.dbc
diff --git a/.project b/.project
index 00ecbe4..1f8938a 100644
--- a/.project
+++ b/.project
@@ -21,4 +21,15 @@
org.eclipse.jdt.core.javanature
net.sf.eclipsecs.core.CheckstyleNature
+
+
+ 1646149232192
+
+ 30
+
+ org.eclipse.core.resources.regexFilterMatcher
+ node_modules|.git|__CREATED_BY_JAVA_LANGUAGE_SERVER__
+
+
+
diff --git a/samples/.project b/samples/.project
index 6af6571..373e608 100644
--- a/samples/.project
+++ b/samples/.project
@@ -14,4 +14,15 @@
org.eclipse.jdt.core.javanature
+
+
+ 1646149232193
+
+ 30
+
+ org.eclipse.core.resources.regexFilterMatcher
+ node_modules|.git|__CREATED_BY_JAVA_LANGUAGE_SERVER__
+
+
+
diff --git a/src/org/atriasoft/ewol/widget/Container.java b/src/org/atriasoft/ewol/widget/Container.java
index 48e3ee8..4abba16 100644
--- a/src/org/atriasoft/ewol/widget/Container.java
+++ b/src/org/atriasoft/ewol/widget/Container.java
@@ -11,8 +11,6 @@ import org.atriasoft.ewol.DrawProperty;
import org.atriasoft.ewol.Gravity;
import org.atriasoft.ewol.internal.Log;
import org.atriasoft.ewol.object.EwolObject;
-import org.atriasoft.exml.model.XmlElement;
-import org.atriasoft.exml.model.XmlNode;
/*
* @ingroup ewolWidgetGroup
@@ -78,50 +76,50 @@ public class Container extends Widget {
return null;
}
- @Override
- public boolean loadXML(final XmlElement node) {
- if (node == null) {
- return false;
- }
- // parse generic properties:
- super.loadXML(node);
- // remove previous element:
- subWidgetRemove();
- // parse all the elements:
- for (XmlNode it : node.getNodes()) {
- if (!it.isElement()) {
- // trash here all that is not element
- continue;
- }
- XmlElement pNode = it.toElement();
- String widgetName = pNode.getValue();
- Log.verbose("[" + getId() + "] t=" + getClass().getCanonicalName() + " Load node name : '" + widgetName + "'");
- if (!getWidgetManager().exist(widgetName)) {
- Log.error("Unknown basic node='" + widgetName + "' not in : [" + getWidgetManager().list() + "]");
- continue;
- }
- if (getSubWidget() != null) {
- Log.error("Can only have one subWidget ??? node='" + widgetName + "'");
- continue;
- }
- Log.debug("try to create subwidget : '" + widgetName + "'");
- Widget tmpWidget = getWidgetManager().create(widgetName, pNode);
- if (tmpWidget == null) {
- Log.error("Can not create the widget : '" + widgetName + "'");
- continue;
- }
- // add widget :
- setSubWidget(tmpWidget);
- if (!tmpWidget.loadXML(pNode)) {
- Log.error("can not load widget properties : '" + widgetName + "'");
- return false;
- }
- }
- if (node.getNodes().size() != 0 && this.subWidget == null) {
- Log.warning("Load container with no data inside");
- }
- return true;
- }
+ // @Override
+ // public boolean loadXML(final XmlElement node) {
+ // if (node == null) {
+ // return false;
+ // }
+ // // parse generic properties:
+ // super.loadXML(node);
+ // // remove previous element:
+ // subWidgetRemove();
+ // // parse all the elements:
+ // for (XmlNode it : node.getNodes()) {
+ // if (!it.isElement()) {
+ // // trash here all that is not element
+ // continue;
+ // }
+ // XmlElement pNode = it.toElement();
+ // String widgetName = pNode.getValue();
+ // Log.verbose("[" + getId() + "] t=" + getClass().getCanonicalName() + " Load node name : '" + widgetName + "'");
+ // if (!getWidgetManager().exist(widgetName)) {
+ // Log.error("Unknown basic node='" + widgetName + "' not in : [" + getWidgetManager().list() + "]");
+ // continue;
+ // }
+ // if (getSubWidget() != null) {
+ // Log.error("Can only have one subWidget ??? node='" + widgetName + "'");
+ // continue;
+ // }
+ // Log.debug("try to create subwidget : '" + widgetName + "'");
+ // Widget tmpWidget = getWidgetManager().create(widgetName, pNode);
+ // if (tmpWidget == null) {
+ // Log.error("Can not create the widget : '" + widgetName + "'");
+ // continue;
+ // }
+ // // add widget :
+ // setSubWidget(tmpWidget);
+ // if (!tmpWidget.loadXML(pNode)) {
+ // Log.error("can not load widget properties : '" + widgetName + "'");
+ // return false;
+ // }
+ // }
+ // if (node.getNodes().size() != 0 && this.subWidget == null) {
+ // Log.warning("Load container with no data inside");
+ // }
+ // return true;
+ // }
@Override
public void onChangeSize() {
diff --git a/src/org/atriasoft/ewol/widget/WidgetManager.java b/src/org/atriasoft/ewol/widget/WidgetManager.java
index 5333ae1..48a963d 100644
--- a/src/org/atriasoft/ewol/widget/WidgetManager.java
+++ b/src/org/atriasoft/ewol/widget/WidgetManager.java
@@ -1,9 +1,6 @@
package org.atriasoft.ewol.widget;
import java.lang.ref.WeakReference;
-import java.lang.reflect.InvocationTargetException;
-import java.util.HashMap;
-import java.util.Map;
import org.atriasoft.ewol.internal.Log;
import org.atriasoft.exml.model.XmlElement;
@@ -89,18 +86,18 @@ public class WidgetManager {
* @param klass class interface
*/
public void addWidgetCreator(final String name, final Class> klass) throws Exception {
- if (klass == null) {
- throw new Exception("Can not add widget creator without specified class.");
- }
- //Keep name in lower case :
- final String nameLower = name.toLowerCase();
- final Class> it = WidgetXmlFactory..creatorList.get(nameLower);
- if (it != null) {
- Log.warning("Replace Creator of a specify widget : " + nameLower);
- return;
- }
- this.creatorList.put(nameLower, klass);
- // TODO check constructors ...
+ // if (klass == null) {
+ // throw new Exception("Can not add widget creator without specified class.");
+ // }
+ // //Keep name in lower case :
+ // final String nameLower = name.toLowerCase();
+ // final Class> it = WidgetXmlFactory.creatorList.get(nameLower);
+ // if (it != null) {
+ // Log.warning("Replace Creator of a specify widget : " + nameLower);
+ // return;
+ // }
+ // this.creatorList.put(nameLower, klass);
+ // // TODO check constructors ...
}
/**
@@ -110,33 +107,33 @@ public class WidgetManager {
*/
public Widget create(final String name) {
final String nameLower = name.toLowerCase();
- final Class> it = this.creatorList.get(nameLower);
- if (it != null) {
- try {
- return (Widget) it.getConstructor().newInstance();
- } catch (InstantiationException | IllegalAccessException | IllegalArgumentException | InvocationTargetException | NoSuchMethodException | SecurityException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- return null;
- }
- }
+ // final Class> it = this.creatorList.get(nameLower);
+ // if (it != null) {
+ // try {
+ // return (Widget) it.getConstructor().newInstance();
+ // } catch (InstantiationException | IllegalAccessException | IllegalArgumentException | InvocationTargetException | NoSuchMethodException | SecurityException e) {
+ // // TODO Auto-generated catch block
+ // e.printStackTrace();
+ // return null;
+ // }
+ // }
Log.warning("try to create an UnExistant widget : " + nameLower);
return null;
}
public Widget create(final String name, final XmlElement node) {
final String nameLower = name.toLowerCase();
- final Class> it = this.creatorList.get(nameLower);
- if (it != null) {
- try {
- Widget tmp = (Widget) it.getConstructor().newInstance();
- tmp.loadXML(node);
- } catch (InstantiationException | IllegalAccessException | IllegalArgumentException | InvocationTargetException | NoSuchMethodException | SecurityException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- return null;
- }
- }
+ // final Class> it = this.creatorList.get(nameLower);
+ // if (it != null) {
+ // try {
+ // Widget tmp = (Widget) it.getConstructor().newInstance();
+ // tmp.loadXML(node);
+ // } catch (InstantiationException | IllegalAccessException | IllegalArgumentException | InvocationTargetException | NoSuchMethodException | SecurityException e) {
+ // // TODO Auto-generated catch block
+ // e.printStackTrace();
+ // return null;
+ // }
+ // }
Log.warning("try to create an UnExistant widget : " + nameLower);
return null;
}
@@ -148,7 +145,8 @@ public class WidgetManager {
* @return false The Widget Does NOT exist.
*/
public boolean exist(final String name) {
- return this.creatorList.get(name.toLowerCase()) != null;
+ // return this.creatorList.get(name.toLowerCase()) != null;
+ return false;
}
/**
@@ -259,7 +257,8 @@ public class WidgetManager {
* @return Separate with ',' string list.
*/
public String list() {
- return this.creatorList.keySet().toString();
+ //return this.creatorList.keySet().toString();
+ return "";
}
/**