Buix-commits
Threads by month
- ----- 2026 -----
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2005 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2004 -----
- December
- November
- October
- September
- August
- 1440 discussions
Author: tchemit
Date: 2009-01-02 08:27:33 +0000 (Fri, 02 Jan 2009)
New Revision: 1115
Modified:
lutinjaxx/branches/storm_1/pom.xml
Log:
suppression dependence jaxx-core
Modified: lutinjaxx/branches/storm_1/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/pom.xml 2009-01-02 08:27:12 UTC (rev 1114)
+++ lutinjaxx/branches/storm_1/pom.xml 2009-01-02 08:27:33 UTC (rev 1115)
@@ -134,10 +134,6 @@
<groupId>org.codelutin</groupId>
<artifactId>jaxx-compiler-api</artifactId>
<version>${project.version}</version>
- </dependency> <dependency>
- <groupId>org.codelutin</groupId>
- <artifactId>jaxx-core</artifactId>
- <version>${project.version}</version>
</dependency>
<!-- swing extension -->
@@ -163,7 +159,7 @@
<artifactId>jaxx-compiler-validator</artifactId>
<version>${project.version}</version>
</dependency>
-
+
<dependency>
<groupId>org.codelutin</groupId>
<artifactId>jaxx-swing-action</artifactId>
1
0
r1114 - lutinjaxx/branches/storm_1/jaxx-runtime-validator/src/main/java/jaxx/runtime/validator
by tchemit@users.labs.libre-entreprise.org 02 Jan '09
by tchemit@users.labs.libre-entreprise.org 02 Jan '09
02 Jan '09
Author: tchemit
Date: 2009-01-02 08:27:12 +0000 (Fri, 02 Jan 2009)
New Revision: 1114
Modified:
lutinjaxx/branches/storm_1/jaxx-runtime-validator/src/main/java/jaxx/runtime/validator/BeanValidator.java
lutinjaxx/branches/storm_1/jaxx-runtime-validator/src/main/java/jaxx/runtime/validator/ErrorTableRenderer.java
Log:
ajout method isvalid sur le validator pour savoir de l'exterieur si un fieldName est en erreur ou pas sans a avoir a passer par les modeles d'erreurs
Modified: lutinjaxx/branches/storm_1/jaxx-runtime-validator/src/main/java/jaxx/runtime/validator/BeanValidator.java
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-runtime-validator/src/main/java/jaxx/runtime/validator/BeanValidator.java 2009-01-02 08:26:20 UTC (rev 1113)
+++ lutinjaxx/branches/storm_1/jaxx-runtime-validator/src/main/java/jaxx/runtime/validator/BeanValidator.java 2009-01-02 08:27:12 UTC (rev 1114)
@@ -525,6 +525,23 @@
return super.toString() + "<contextName:" + contextName + ">";
}
+ /**
+ * Test if a fieldName is valid for the validator
+ *
+ * @param fieldName the name of the field to test
+ * @return <code>true</code> if field is valid, <code>false</code> otherwise.
+ */
+ public boolean isValid(String fieldName) {
+ if (!isValid()) {
+ for (Object o : getFieldErrors().keySet()) {
+ if (fieldName.equals(o)) {
+ return false;
+ }
+ }
+ }
+ return true;
+ }
+
/** @return <code>true</code> if validation is not active , <code>false</code> otherwise. */
protected boolean checkState() {
return bean == null || (getErrorListModel() == null && getErrorTableModel() == null) || fieldRepresentation.size() == 0;
@@ -565,7 +582,7 @@
// ajout du jxlayer sous ce composant
Container container = c.getParent();
if (container instanceof JXLayer) {
- Constructor<? extends AbstractBeanValidatorUI> cons = uiClass.getConstructor(String.class, String.class,Scope.class, ValidationAware.class);
+ Constructor<? extends AbstractBeanValidatorUI> cons = uiClass.getConstructor(String.class, String.class, Scope.class, ValidationAware.class);
AbstractBeanValidatorUI ui = cons.newInstance(fieldname, c.getName(), scope, validationSupport);
ui.setEnabled(true);
JXLayer<JComponent> jx = (JXLayer<JComponent>) container;
Modified: lutinjaxx/branches/storm_1/jaxx-runtime-validator/src/main/java/jaxx/runtime/validator/ErrorTableRenderer.java
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-runtime-validator/src/main/java/jaxx/runtime/validator/ErrorTableRenderer.java 2009-01-02 08:26:20 UTC (rev 1113)
+++ lutinjaxx/branches/storm_1/jaxx-runtime-validator/src/main/java/jaxx/runtime/validator/ErrorTableRenderer.java 2009-01-02 08:27:12 UTC (rev 1114)
@@ -50,7 +50,7 @@
while (stk.hasMoreTokens()) {
args.add(stk.nextToken());
}
- text = _(errorName, args.toArray(new String[args.size()]));
+ text = _(errorName, args.toArray());
}
} else {
// keep text rendered
1
0
r1113 - lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation
by tchemit@users.labs.libre-entreprise.org 02 Jan '09
by tchemit@users.labs.libre-entreprise.org 02 Jan '09
02 Jan '09
Author: tchemit
Date: 2009-01-02 08:26:20 +0000 (Fri, 02 Jan 2009)
New Revision: 1113
Modified:
lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationTreeCellRenderer.java
lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationTreeModel.java
lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationTreeSelectionAdapter.java
lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationUtil.java
Log:
naivgation divers...
Modified: lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationTreeCellRenderer.java
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationTreeCellRenderer.java 2009-01-02 08:25:38 UTC (rev 1112)
+++ lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationTreeCellRenderer.java 2009-01-02 08:26:20 UTC (rev 1113)
@@ -8,7 +8,9 @@
import org.codelutin.util.StringUtil;
import javax.swing.JTree;
+import javax.swing.UIManager;
import javax.swing.tree.DefaultTreeCellRenderer;
+import javax.swing.tree.TreeCellRenderer;
import javax.swing.tree.TreePath;
import java.awt.Component;
@@ -17,24 +19,33 @@
*
* @author chemit
*/
-public class NavigationTreeCellRenderer extends DefaultTreeCellRenderer {
+public class NavigationTreeCellRenderer implements TreeCellRenderer {
/** to use log facility, just put in your code: log.info(\"...\"); */
static private final Log log = LogFactory.getLog(NavigationTreeCellRenderer.class);
protected JAXXContext context;
+ protected DefaultTreeCellRenderer delegate;
+
protected static long t = 0;
public NavigationTreeCellRenderer(JAXXContext context) {
this.context = context;
+ UIManager.put("Tree.rendererFillBackground", false);
+ delegate = new DefaultTreeCellRenderer();
}
+ public NavigationTreeCellRenderer(JAXXContext context, DefaultTreeCellRenderer delegate) {
+ this.context = context;
+ this.delegate = delegate;
+ }
+
@Override
public Component getTreeCellRendererComponent(JTree tree, Object value, boolean sel, boolean expanded, boolean leaf, int row, boolean hasFocus) {
TreePath path = tree.getPathForRow(row);
if (path == null) {
- return this;
+ return delegate;
}
if (value != null) {
@@ -50,7 +61,7 @@
}
}
- return super.getTreeCellRendererComponent(tree, value, sel, expanded, leaf, row, hasFocus);
+ return delegate.getTreeCellRendererComponent(tree, value, sel, expanded, leaf, row, hasFocus);
}
protected NodeRenderer getNodeRenderer(Object value) {
Modified: lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationTreeModel.java
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationTreeModel.java 2009-01-02 08:25:38 UTC (rev 1112)
+++ lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationTreeModel.java 2009-01-02 08:26:20 UTC (rev 1113)
@@ -197,9 +197,20 @@
@Override
public void nodeChanged(TreeNode node) {
+ nodeChanged(node, false);
+ }
+
+ public void nodeChanged(TreeNode node, boolean deep) {
NavigationTreeNode n = (NavigationTreeNode) node;
- n.clearCache();
+ n.clearCache(!deep);
super.nodeChanged(node);
+ if (deep) {
+ Enumeration childs = node.children();
+ while (childs.hasMoreElements()) {
+ NavigationTreeNode o = (NavigationTreeNode) childs.nextElement();
+ nodeChanged(o, true);
+ }
+ }
}
/**
@@ -446,7 +457,7 @@
// save in cache
setCachedBean(result);
-
+
return result;
}
@@ -517,7 +528,11 @@
}
public void clearCache() {
+ clearCache(false);
+ }
+ public void clearCache(boolean deep) {
+
// clear bean cache
cachedBean = null;
@@ -526,11 +541,13 @@
renderer.setRendererCachedValue(null);
}
- // clear cache in childs
- Enumeration childs = this.children();
- while (childs.hasMoreElements()) {
- NavigationTreeNode o = (NavigationTreeNode) childs.nextElement();
- o.clearCache();
+ if (deep) {
+ // clear cache in childs
+ Enumeration childs = this.children();
+ while (childs.hasMoreElements()) {
+ NavigationTreeNode o = (NavigationTreeNode) childs.nextElement();
+ o.clearCache();
+ }
}
}
Modified: lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationTreeSelectionAdapter.java
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationTreeSelectionAdapter.java 2009-01-02 08:25:38 UTC (rev 1112)
+++ lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationTreeSelectionAdapter.java 2009-01-02 08:26:20 UTC (rev 1113)
@@ -19,12 +19,16 @@
/** to use log facility, just put in your code: log.info(\"...\"); */
static private final Log log = LogFactory.getLog(NavigationTreeSelectionAdapter.class);
- static public final String NAVIGATION_CONTEXT_PATH = "navigation-context-path";
+ //static public final String NAVIGATION_CONTEXT_PATH = "navigation-context-path";
- static public final String NAVIGATION_SELECTED_NODE = "navigation-selected-node";
+ //static public final String NAVIGATION_SELECTED_NODE = "navigation-selected-node";
static public final String NAVIGATION_SELECTED_BEAN = "navigation-selected-bean";
+ static public final JAXXContextEntryDef<String> NAVIGATION_SELECTED_PATH_ENTRY_DEF = JAXXContextEntryDef.newDef("navigation-selected-path", String.class);
+
+ static public final JAXXContextEntryDef<NavigationTreeNode> NAVIGATION_SELECTED_NODE_ENTRY_DEF = JAXXContextEntryDef.newDef("navigation-selected-node", NavigationTreeNode.class);
+
static public final JAXXContextEntryDef<Boolean> GO_BACK_DEF = JAXXContextEntryDef.newDef("goBack", Boolean.class);
/** defined the stategy of instanciation of ui */
@@ -179,10 +183,10 @@
}
// save in context current node context path
- context.setContextValue(node.getContextPath(), NAVIGATION_CONTEXT_PATH);
+ NAVIGATION_SELECTED_PATH_ENTRY_DEF.setContextValue(context, node.getContextPath());
// save in context current node
- context.setContextValue(node, NAVIGATION_SELECTED_NODE);
+ NAVIGATION_SELECTED_NODE_ENTRY_DEF.setContextValue(context, node);
// really open the ui associated with the selected node
openUI(newUI, node);
Modified: lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationUtil.java
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationUtil.java 2009-01-02 08:25:38 UTC (rev 1112)
+++ lutinjaxx/branches/storm_1/jaxx-runtime-swing/src/main/java/jaxx/runtime/swing/navigation/NavigationUtil.java 2009-01-02 08:26:20 UTC (rev 1113)
@@ -23,11 +23,11 @@
static private final Log log = LogFactory.getLog(NavigationUtil.class);
public static String getCurrentNavigationNath(JAXXContext context) {
- return context.getContextValue(String.class, NavigationTreeSelectionAdapter.NAVIGATION_CONTEXT_PATH);
+ return NavigationTreeSelectionAdapter.NAVIGATION_SELECTED_PATH_ENTRY_DEF.getContextValue(context);
}
public static NavigationTreeNode getSelectedNode(JAXXContext context) {
- return context.getContextValue(NavigationTreeNode.class, NavigationTreeSelectionAdapter.NAVIGATION_SELECTED_NODE);
+ return NavigationTreeSelectionAdapter.NAVIGATION_SELECTED_NODE_ENTRY_DEF.getContextValue(context);
}
public static <O> O getSelectedBean(JAXXContext context, Class<O> clazz) {
1
0
r1112 - lutinjaxx/branches/storm_1/jaxx-compiler-api/src/main/java/jaxx/compiler
by tchemit@users.labs.libre-entreprise.org 02 Jan '09
by tchemit@users.labs.libre-entreprise.org 02 Jan '09
02 Jan '09
Author: tchemit
Date: 2009-01-02 08:25:38 +0000 (Fri, 02 Jan 2009)
New Revision: 1112
Modified:
lutinjaxx/branches/storm_1/jaxx-compiler-api/src/main/java/jaxx/compiler/JAXXCompiler.java
lutinjaxx/branches/storm_1/jaxx-compiler-api/src/main/java/jaxx/compiler/JAXXCompilerLaunchor.java
Log:
nettoyage code apres refactor + amelioration de la compile -utilisation d'une enum pour definir la phase en cours
Modified: lutinjaxx/branches/storm_1/jaxx-compiler-api/src/main/java/jaxx/compiler/JAXXCompiler.java
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-compiler-api/src/main/java/jaxx/compiler/JAXXCompiler.java 2009-01-02 08:23:35 UTC (rev 1111)
+++ lutinjaxx/branches/storm_1/jaxx-compiler-api/src/main/java/jaxx/compiler/JAXXCompiler.java 2009-01-02 08:25:38 UTC (rev 1112)
@@ -69,7 +69,7 @@
/**
* Compiles JAXX files into Java classes.
- * <p/>
+ * <p/>
* use {@link Generator} ... todo finish javadoc
*/
public class JAXXCompiler {
@@ -1090,7 +1090,7 @@
assert jaxxFile.getName().equalsIgnoreCase(className.substring(className.lastIndexOf(".") + 1) + ".jaxx") :
"expecting file name to match " + className + ", but found " + jaxxFile.getName();
if (jaxxFile.getName().equals(className.substring(className.lastIndexOf(".") + 1) + ".jaxx")) { // check case match
- if (JAXXCompilerLaunchor.get().currentPass == JAXXCompilerLaunchor.PASS_2) {
+ if (JAXXCompilerLaunchor.get().currentPass != JAXXCompilerLaunchor.LifeCycle.compile_first_pass) {
throw new AssertionError("Internal error: adding dependency class " + className + " during second compilation pass");
}
JAXXCompilerLaunchor.get().jaxxFileClassNames.add(className);
@@ -1319,170 +1319,6 @@
return System.getProperty("line.separator", "\n");
}
- /**
- * Compiled a set of files, with the class names specified explicitly. The class compiled from files[i] will be named classNames[i].
- * Returns <code>true</code> if compilation succeeds, <code>false</code> if it fails. Warning and error messages are sent to
- * <code>System.err</code>.
- *
- * @param files the .jaxx files to compile
- * @param classNames the names of the classes being compiled
- * @param options the compiler options to use
- * @return <code>true</code> if compilation succeeds, <code>false</code> otherwise
- */
- /*public static synchronized boolean compile(File[] files, String[] classNames, CompilerOptions options) {
- reset(); // just to be safe...
- jaxxFiles.addAll(Arrays.asList(files));
- jaxxFileClassNames.addAll(Arrays.asList(classNames));
- try {
- boolean success = true;
-
- // pass 1
- currentPass = PASS_1;
- boolean compiled;
- do {
- compiled = false;
- assert jaxxFiles.size() == jaxxFileClassNames.size();
- java.util.Iterator<File> filesIterator = new ArrayList<File>(jaxxFiles).iterator(); // clone it so it can safely be modified while we're iterating
- java.util.Iterator<String> classNamesIterator = new ArrayList<String>(jaxxFileClassNames).iterator();
- while (filesIterator.hasNext()) {
- File file = filesIterator.next();
- String className = classNamesIterator.next();
- if (options.isVerbose()) {
- log.info("compile first pass for " + className);
- }
- if (symbolTables.get(file) == null) {
- compiled = true;
- if (compilers.containsKey(className)) {
- throw new CompilerException("Internal error: " + className + " is already being compiled, attempting to compile it again");
- }
-
- File destDir = options.getTargetDirectory();
- if (destDir != null) {
- int dotPos = className.lastIndexOf(".");
- if (dotPos != -1) {
- destDir = new File(destDir, className.substring(0, dotPos).replace('.', File.separatorChar));
- }
- if (!destDir.exists() && !destDir.mkdirs()) {
- log.warn("could not create directory " + destDir);
- continue;
- }
- } else {
- //destDir = file.getParentFile();
- }
- Compiler compiler = new JAXXCompiler(file.getParentFile(), file, className, options);
- compilers.put(className, compiler);
- compiler.compileFirstPass();
- assert !symbolTables.values().contains(compiler.getSymbolTable()) : "symbolTable is already registered";
- symbolTables.put(file, compiler.getSymbolTable());
- if (compiler.isFailed()) {
- success = false;
- }
- }
- }
-
- } while (compiled);
-
- // pass 2
- currentPass = PASS_2;
- if (success) {
- assert jaxxFiles.size() == jaxxFileClassNames.size();
- List<File> jaxxFilesClone = new ArrayList<File>(jaxxFiles);
- for (String className : jaxxFileClassNames) {
- Compiler compiler = compilers.get(className);
- if (compiler == null) {
- throw new CompilerException("Internal error: could not find compiler for " + className + " during second pass");
- }
- if (options.isVerbose()) {
-
- log.info("runInitializers for " + className);
- }
- if (!compiler.isFailed()) {
- compiler.runInitializers();
- }
- if (options.isVerbose()) {
-
- log.info("compile second pass for " + className);
- }
- compiler.compileSecondPass();
- if (options.isVerbose()) {
-
- log.info("done with result [" + !compiler.isFailed() + "] for " + className);
- }
- if (!compiler.isFailed()) {
-
- } else {
- success = false;
- }
- }
- if (!jaxxFilesClone.equals(jaxxFiles)) {
- throw new AssertionError("Internal error: compilation set altered during pass 2 (was " + jaxxFilesClone + ", modified to " + jaxxFiles + ")");
- }
- }
-
- // stylesheet application
- if (success) {
- assert jaxxFiles.size() == jaxxFileClassNames.size();
- for (String className : jaxxFileClassNames) {
- Compiler compiler = compilers.get(className);
- if (compiler == null) {
- throw new CompilerException("Internal error: could not find compiler for " + className + " during stylesheet application");
- }
- compiler.applyStylesheets();
- if (compiler.isFailed()) {
- success = false;
- }
- }
- }
-
- // code generation
- if (success) {
- assert jaxxFiles.size() == jaxxFileClassNames.size();
- List<Generator> generators = new ArrayList<Generator>();
- for (Generator generator : ServiceLoader.load(Generator.class)) {
- generators.add(generator);
- }
- for (String className : jaxxFileClassNames) {
- Compiler compiler = compilers.get(className);
- if (compiler == null) {
- throw new CompilerException("Internal error: could not find compiler for " + className + " during code generation");
- }
- compiler.generateCode(generators);
- //compiler.generateCode();
- if (compiler.isFailed()) {
- success = false;
- }
- }
- }
-
- if (warningCount == 1) {
- System.err.println("1 warning");
- } else if (warningCount > 0) {
- System.err.println(warningCount + " warnings");
- }
- if (errorCount == 1) {
- System.err.println("1 error");
- } else if (errorCount > 0) {
- System.err.println(errorCount + " errors");
- }
- return success;
- }
- catch (CompilerException e) {
- System.err.println(e.getMessage());
- e.printStackTrace();
- return false;
- }
- catch (Throwable e) {
- e.printStackTrace();
- return false;
- }
- finally {
- //TC - 20081018 only reset when no error was detected
- if (options.isResetAfterCompile() && errorCount == 0) {
- reset();
- }
- }
- }*/
-
// 1.5 adds getCanonicalName; unfortunately we can't depend on 1.5 features yet
public static String getCanonicalName(Class clazz) {
if (clazz.isArray()) {
Modified: lutinjaxx/branches/storm_1/jaxx-compiler-api/src/main/java/jaxx/compiler/JAXXCompilerLaunchor.java
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-compiler-api/src/main/java/jaxx/compiler/JAXXCompilerLaunchor.java 2009-01-02 08:23:35 UTC (rev 1111)
+++ lutinjaxx/branches/storm_1/jaxx-compiler-api/src/main/java/jaxx/compiler/JAXXCompilerLaunchor.java 2009-01-02 08:25:38 UTC (rev 1112)
@@ -1,14 +1,13 @@
package jaxx.compiler;
import jaxx.CompilerException;
+import jaxx.reflect.ClassDescriptorLoader;
import jaxx.spi.Initializer;
-import jaxx.reflect.ClassDescriptorLoader;
import jaxx.tags.DefaultObjectHandler;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import java.io.File;
-import java.io.IOException;
import java.lang.reflect.Constructor;
import java.lang.reflect.InvocationTargetException;
import java.util.ArrayList;
@@ -21,116 +20,122 @@
/** @author chemit */
public class JAXXCompilerLaunchor {
-
/** log */
protected static final Log log = LogFactory.getLog(JAXXCompilerLaunchor.class);
+ enum LifeCycle {
+ init,// state before compilation
+ compile_first_pass, // state when first pass of compilation
+ compile_second_pass, // state when second pass of compilation
+ stylesheet_pass, // state when applygin stylesheet phase after compilation
+ generate_pass // state when generation phase
+ }
+
protected static final int PASS_1 = 0;
protected static final int PASS_2 = 1;
+
+ /** shared instance of unique launchor at a givne time. */
protected static JAXXCompilerLaunchor singleton;
- protected CompilerOptions options;
-
- protected final File[] files;
- protected final String[] classNames;
-
- public JAXXCompilerLaunchor(File base, String[] relativePaths, CompilerOptions options) {
- this.options = options;
- files = new File[relativePaths.length];
- classNames = new String[relativePaths.length];
- for (int i = 0; i < files.length; i++) {
- files[i] = new File(base, relativePaths[i]);
- classNames[i] = relativePaths[i].substring(0, relativePaths[i].lastIndexOf("."));
- classNames[i] = classNames[i].replace(File.separatorChar, '.');
- classNames[i] = classNames[i].replace('/', '.');
- classNames[i] = classNames[i].replace('\\', '.');
- classNames[i] = classNames[i].replace(':', '.');
- }
- if (options.isVerbose()) {
- log.info("files : " + Arrays.toString(files));
- }
- }
-
- public JAXXCompilerLaunchor(File[] files, String[] classNames, CompilerOptions options) {
- this.options = options;
- this.files = files;
- this.classNames = classNames;
- if (options.isVerbose()) {
- log.info("files : " + Arrays.toString(files));
- }
- }
-
- public JAXXCompilerLaunchor() {
- this.options = new CompilerOptions();
- files = null;
- classNames = null;
- }
-
/**
- * Compiled a set of files, expressed as paths relative to a base directory. The class names of the compiled files are derived
- * from the relative path strings (e.g. "example/Foo.jaxx" compiles into a class named "example.Foo"). Returns <code>true</code>
- * if compilation succeeds, <code>false</code> if it fails. Warning and error messages are sent to <code>System.err</code>.
+ * Create a new empty launchor and set it as current launchor accessible via method {@link #get()}
*
- * @return <code>true</code> if compilation succeeds, <code>false</code> otherwise
+ * @return the new instanciated launchor
*/
- public static JAXXCompilerLaunchor newLaunchor() {
- if (singleton != null) {
- //singleton.reset();
- }
- singleton = new JAXXCompilerLaunchor();
-
- return singleton;
+ public static synchronized JAXXCompilerLaunchor newLaunchor() {
+ return newLaunchor((File[]) null, null, null);
}
/**
- * Compiled a set of files, expressed as paths relative to a base directory. The class names of the compiled files are derived
- * from the relative path strings (e.g. "example/Foo.jaxx" compiles into a class named "example.Foo"). Returns <code>true</code>
- * if compilation succeeds, <code>false</code> if it fails. Warning and error messages are sent to <code>System.err</code>.
+ * Create a new launchor and set it as current launchor accessible via method {@link #get()}.
+ * <p/>
+ * The launchor will be prepared to compile a set of files, expressed as paths relative to a base directory.
+ * The class names of the compiled files are derived from the relative path strings
+ * (e.g. "example/Foo.jaxx" compiles into a class named "example.Foo").
*
* @param base the directory against which to resolve relative paths
* @param relativePaths a list of relative paths to .jaxx files being compiled
* @param options the compiler options to use
- * @return <code>true</code> if compilation succeeds, <code>false</code> otherwise
+ * @return the new instanciated launchor
*/
- public static JAXXCompilerLaunchor newLaunchor(File base, String[] relativePaths, CompilerOptions options) {
- if (singleton != null) {
- //singleton.reset();
+ public static synchronized JAXXCompilerLaunchor newLaunchor(File base, String[] relativePaths, CompilerOptions options) {
+ File[] files = new File[relativePaths.length];
+ String[] classNames = new String[relativePaths.length];
+ for (int i = 0; i < files.length; i++) {
+ files[i] = new File(base, relativePaths[i]);
+ classNames[i] = relativePaths[i].substring(0, relativePaths[i].lastIndexOf("."));
+ classNames[i] = classNames[i].replace(File.separatorChar, '.');
+ classNames[i] = classNames[i].replace('/', '.');
+ classNames[i] = classNames[i].replace('\\', '.');
+ classNames[i] = classNames[i].replace(':', '.');
}
- singleton = new JAXXCompilerLaunchor(base, relativePaths, options);
-
- return singleton;
+ return newLaunchor(files, classNames, options);
}
/**
- * Compiled a set of files, with the class names specified explicitly. The class compiled from files[i] will be named classNames[i].
- * Returns <code>true</code> if compilation succeeds, <code>false</code> if it fails. Warning and error messages are sent to
- * <code>System.err</code>.
+ * Create a new launchor and set it as current launchor accessible via method {@link #get()}.
+ * <p/>
+ * The launchor will be prepared to compile a set of files, with the class names specified explicitly.
+ * The class compiled from files[i] will be named classNames[i].
*
* @param files the .jaxx files to compile
* @param classNames the names of the classes being compiled
* @param options the compiler options to use
- * @return <code>true</code> if compilation succeeds, <code>false</code> otherwise
+ * @return the new instanciated launchor
*/
- public static JAXXCompilerLaunchor newLaunchor(File[] files, String[] classNames, CompilerOptions options) {
+ public static synchronized JAXXCompilerLaunchor newLaunchor(File[] files, String[] classNames, CompilerOptions options) {
if (singleton != null) {
- //singleton.reset();
+ singleton.reset();
}
singleton = new JAXXCompilerLaunchor(files, classNames, options);
return singleton;
}
- public static JAXXCompilerLaunchor get() {
+ /**
+ * @return the current launchor
+ * @throws NullPointerException if no launchor was registred via a <code>newLaunchor-like</code> method.
+ */
+ public static JAXXCompilerLaunchor get() throws NullPointerException {
if (singleton == null) {
throw new NullPointerException("no launchor was registred via newLaunchor method");
}
return singleton;
}
+ /** @return <code> if there is a launchor registred, <code>false</code> otherwise. */
public static boolean isRegistred() {
return singleton != null;
}
+ /**
+ * Load the {@link jaxx.spi.Initializer} services found via the{@link ServiceLoader} mecanism.
+ *
+ * @param verbose <ocde>true</code> to print initializers
+ */
+ public static void loadLibraries(boolean verbose) {
+ //BeanInfoUtil.reset();
+ ClassLoader classloader = Thread.currentThread().getContextClassLoader();
+ if (verbose) {
+ log.info("with cl " + classloader);
+ }
+ ServiceLoader<Initializer> loader = ServiceLoader.load(Initializer.class, classloader);
+ for (Initializer initializer : loader) {
+ if (verbose) {
+ log.info("load initializer " + initializer);
+ }
+ initializer.initialize();
+ }
+ }
+
+ /** options of the launchor and underlines compilers */
+ protected CompilerOptions options;
+ /** original list of files to compile */
+ protected final File[] files;
+ /** original list of classes to compile */
+ protected final String[] classNames;
+
+ /** Files to be treated while compilation. */
protected List<File> jaxxFiles = new ArrayList<File>();
/** Class names corresponding to the files in the jaxxFiles list. */
@@ -142,26 +147,22 @@
/** Maps the names of classes being compiled to their symbol tables (created after the first compiler pass). */
protected Map<File, SymbolTable> symbolTables = new HashMap<File, SymbolTable>();
- protected int currentPass;
+ protected LifeCycle currentPass;
+ //protected int currentPass;
protected int errorCount;
protected int warningCount;
- public static void loadLibraries(boolean verbose) throws IOException, ClassNotFoundException, InstantiationException, IllegalAccessException {
- //BeanInfoUtil.reset();
- ClassLoader classloader = Thread.currentThread().getContextClassLoader();
- if (verbose) {
- log.info("with cl " + classloader);
+ protected JAXXCompilerLaunchor(File[] files, String[] classNames, CompilerOptions options) {
+ this.options = options == null ? new CompilerOptions() : options;
+ this.files = files;
+ this.classNames = classNames;
+ if (this.options.isVerbose()) {
+ log.info("files : " + Arrays.toString(files));
}
- ServiceLoader<Initializer> loader = ServiceLoader.load(Initializer.class, classloader);
- for (Initializer initializer : loader) {
- if (verbose) {
- log.info("load initializer " + initializer);
- }
- initializer.initialize();
- }
}
+
public void init() {
// forces static initializer to run if it hasn't yet
}
@@ -175,6 +176,7 @@
symbolTables.clear();
compilers.clear();
}
+
public String getVersion() {
return "1.0.4";
}
@@ -243,7 +245,7 @@
boolean success = true;
// pass 1
- currentPass = PASS_1;
+ currentPass = LifeCycle.compile_first_pass;
boolean compiled;
do {
compiled = false;
@@ -287,90 +289,84 @@
}
} while (compiled);
+ if (!success) {
+ return report(false);
+ }
// pass 2
- currentPass = PASS_2;
- if (success) {
- assert jaxxFiles.size() == jaxxFileClassNames.size();
- List<File> jaxxFilesClone = new ArrayList<File>(jaxxFiles);
- for (String className : jaxxFileClassNames) {
- JAXXCompiler compiler = compilers.get(className);
- if (compiler == null) {
- throw new CompilerException("Internal error: could not find compiler for " + className + " during second pass");
- }
- if (options.isVerbose()) {
+ currentPass = LifeCycle.compile_second_pass;
- log.info("runInitializers for " + className);
- }
- if (!compiler.isFailed()) {
- compiler.runInitializers();
- }
- if (options.isVerbose()) {
+ assert jaxxFiles.size() == jaxxFileClassNames.size();
+ List<File> jaxxFilesClone = new ArrayList<File>(jaxxFiles);
+ for (String className : jaxxFileClassNames) {
+ JAXXCompiler compiler = compilers.get(className);
+ if (compiler == null) {
+ throw new CompilerException("Internal error: could not find compiler for " + className + " during second pass");
+ }
+ if (options.isVerbose()) {
- log.info("compile second pass for " + className);
- }
- compiler.compileSecondPass();
- if (options.isVerbose()) {
+ log.info("runInitializers for " + className);
+ }
+ if (!compiler.isFailed()) {
+ compiler.runInitializers();
+ }
+ if (options.isVerbose()) {
- log.info("done with result [" + !compiler.isFailed() + "] for " + className);
- }
- if (!compiler.isFailed()) {
-
- } else {
- success = false;
- }
+ log.info("compile second pass for " + className);
}
- if (!jaxxFilesClone.equals(jaxxFiles)) {
- throw new AssertionError("Internal error: compilation set altered during pass 2 (was " + jaxxFilesClone + ", modified to " + jaxxFiles + ")");
+ compiler.compileSecondPass();
+ if (options.isVerbose()) {
+ log.info("done with result [" + !compiler.isFailed() + "] for " + className);
}
+ if (compiler.isFailed()) {
+ success = false;
+ }
}
+ if (!jaxxFilesClone.equals(jaxxFiles)) {
+ throw new AssertionError("Internal error: compilation set altered during pass 2 (was " + jaxxFilesClone + ", modified to " + jaxxFiles + ")");
+ }
+ if (!success) {
+ return report(false);
+ }
+
// stylesheet application
- if (success) {
- assert jaxxFiles.size() == jaxxFileClassNames.size();
- for (String className : jaxxFileClassNames) {
- JAXXCompiler compiler = compilers.get(className);
- if (compiler == null) {
- throw new CompilerException("Internal error: could not find compiler for " + className + " during stylesheet application");
- }
- compiler.applyStylesheets();
- if (compiler.isFailed()) {
- success = false;
- }
+ currentPass = LifeCycle.stylesheet_pass;
+ assert jaxxFiles.size() == jaxxFileClassNames.size();
+ for (String className : jaxxFileClassNames) {
+ JAXXCompiler compiler = compilers.get(className);
+ if (compiler == null) {
+ throw new CompilerException("Internal error: could not find compiler for " + className + " during stylesheet application");
}
+ compiler.applyStylesheets();
+ if (compiler.isFailed()) {
+ success = false;
+ }
}
+ if (!success) {
+ return report(false);
+ }
// code generation
- if (success) {
- assert jaxxFiles.size() == jaxxFileClassNames.size();
- List<Generator> generators = new ArrayList<Generator>();
- for (Generator generator : ServiceLoader.load(Generator.class)) {
- generators.add(generator);
+ currentPass = LifeCycle.generate_pass;
+ assert jaxxFiles.size() == jaxxFileClassNames.size();
+ List<Generator> generators = new ArrayList<Generator>();
+ for (Generator generator : ServiceLoader.load(Generator.class)) {
+ generators.add(generator);
+ }
+ for (String className : jaxxFileClassNames) {
+ JAXXCompiler compiler = compilers.get(className);
+ if (compiler == null) {
+ throw new CompilerException("Internal error: could not find compiler for " + className + " during code generation");
}
- for (String className : jaxxFileClassNames) {
- JAXXCompiler compiler = compilers.get(className);
- if (compiler == null) {
- throw new CompilerException("Internal error: could not find compiler for " + className + " during code generation");
- }
- compiler.generateCode(generators);
- //compiler.generateCode();
- if (compiler.isFailed()) {
- success = false;
- }
+ compiler.generateCode(generators);
+ //compiler.generateCode();
+ if (compiler.isFailed()) {
+ success = false;
}
}
- if (warningCount == 1) {
- System.err.println("1 warning");
- } else if (warningCount > 0) {
- System.err.println(warningCount + " warnings");
- }
- if (errorCount == 1) {
- System.err.println("1 error");
- } else if (errorCount > 0) {
- System.err.println(errorCount + " errors");
- }
- return success;
+ return report(success);
}
catch (CompilerException e) {
System.err.println(e.getMessage());
@@ -389,6 +385,20 @@
}
}
+ protected boolean report(boolean success) {
+ if (warningCount == 1) {
+ System.err.println("1 warning");
+ } else if (warningCount > 0) {
+ System.err.println(warningCount + " warnings");
+ }
+ if (errorCount == 1) {
+ System.err.println("1 error");
+ } else if (errorCount > 0) {
+ System.err.println(errorCount + " errors");
+ }
+ return success;
+ }
+
protected JAXXCompiler newCompiler(File parentFile, File file, String className) throws InvocationTargetException, IllegalAccessException, InstantiationException, NoSuchMethodException {
Constructor<? extends JAXXCompiler> cons = options.getCompilerClass().getConstructor(File.class, File.class, String.class, CompilerOptions.class);
return cons.newInstance(parentFile, file, className, options);
1
0
r1111 - in lutinjaxx/branches/storm_1/jaxx-example: . Components/src/main/java/examples/Components Components/src/main/resources/i18n Components/src/site/fr/rst
by tchemit@users.labs.libre-entreprise.org 02 Jan '09
by tchemit@users.labs.libre-entreprise.org 02 Jan '09
02 Jan '09
Author: tchemit
Date: 2009-01-02 08:23:35 +0000 (Fri, 02 Jan 2009)
New Revision: 1111
Added:
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Calculator.css
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/CalculatorDemo.jaxx
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/CalculatorEngine.java
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/CounterDemo.jaxx
Removed:
lutinjaxx/branches/storm_1/jaxx-example/Calculator/
lutinjaxx/branches/storm_1/jaxx-example/Counter/
Modified:
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties
lutinjaxx/branches/storm_1/jaxx-example/Components/src/site/fr/rst/index.rst
lutinjaxx/branches/storm_1/jaxx-example/pom.xml
Log:
simplification des examples : y'en a plus qu'un :) todo supprimer ce module et n'avoir que jaxx-example
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Calculator.css (from rev 1109, lutinjaxx/branches/storm_1/jaxx-example/Calculator/src/main/java/examples/Calculator/Calculator.css)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Calculator.css (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Calculator.css 2009-01-02 08:23:35 UTC (rev 1111)
@@ -0,0 +1,49 @@
+
+#table {
+ border: {BorderFactory.createEmptyBorder(4, 4, 4, 4)};
+ font-face: "Trebuchet MS";
+}
+
+#display {
+ background: #BCE5AD;
+ opaque: true;
+ horizontalAlignment: right;
+ border: {BorderFactory.createBevelBorder(BevelBorder.LOWERED)};
+ font-size: 22;
+ font-weight: bold;
+}
+
+#display:{object.getText().startsWith("-")} {
+ foreground: red;
+}
+
+JButton {
+ font-size: 18;
+ width: 80;
+ height: 35;
+}
+
+JButton.digit {
+ foreground: blue;
+}
+
+JButton#dot {
+ font-size: 20;
+}
+
+JButton.operator {
+ font-size: 16;
+ foreground: #009900;
+}
+
+JButton.clear {
+ foreground: red;
+}
+
+JButton:mouseover {
+ font-weight: bold;
+}
+
+JButton.operator:mouseover {
+ font-weight: normal;
+}
\ No newline at end of file
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/CalculatorDemo.jaxx (from rev 1109, lutinjaxx/branches/storm_1/jaxx-example/Calculator/src/main/java/examples/Calculator/Calculator.jaxx)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/CalculatorDemo.jaxx (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/CalculatorDemo.jaxx 2009-01-02 08:23:35 UTC (rev 1111)
@@ -0,0 +1,49 @@
+<DemoPanel>
+ <style source='Calculator.css'/>
+ <script><![CDATA[
+ plus.setText("+");
+ sign.setText("+/-");
+]]></script>
+ <!-- use fully-qualified name just in case this is compiled into a different package -->
+ <examples.Components.CalculatorEngine id='engine'/>
+
+ <Table id='demoPanel' fill='both'>
+ <row>
+ <cell columns='4'><JLabel id='display' text='{engine.getDisplayText()}'/></cell>
+ </row>
+
+ <row>
+ <cell columns='2'><JButton id='c' text='C' onActionPerformed='engine.clear()' styleClass='clear'/></cell>
+ <cell><JButton id='ce' text='CE' onActionPerformed='engine.clearEntry()' styleClass='clear'/></cell>
+ <cell><JButton id='equals' text='=' onActionPerformed='engine.equal()' styleClass='operator'/></cell>
+ </row>
+
+ <row>
+ <cell><JButton id='d7' text='7' onActionPerformed='engine.digit(7)' styleClass='digit'/></cell>
+ <cell><JButton id='d8' text='8' onActionPerformed='engine.digit(8)' styleClass='digit'/></cell>
+ <cell><JButton id='d9' text='9' onActionPerformed='engine.digit(9)' styleClass='digit'/></cell>
+ <cell><JButton id='plus' onActionPerformed='engine.add()' styleClass='operator'/></cell>
+ </row>
+
+ <row>
+ <cell><JButton id='d4' text='4' onActionPerformed='engine.digit(4)' styleClass='digit'/></cell>
+ <cell><JButton id='d5' text='5' onActionPerformed='engine.digit(5)' styleClass='digit'/></cell>
+ <cell><JButton id='d6' text='6' onActionPerformed='engine.digit(6)' styleClass='digit'/></cell>
+ <cell><JButton id='subtract' text='-' onActionPerformed='engine.subtract()' styleClass='operator'/></cell>
+ </row>
+
+ <row>
+ <cell><JButton id='d1' text='1' onActionPerformed='engine.digit(1)' styleClass='digit'/></cell>
+ <cell><JButton id='d2' text='2' onActionPerformed='engine.digit(2)' styleClass='digit'/></cell>
+ <cell><JButton id='d3' text='3' onActionPerformed='engine.digit(3)' styleClass='digit'/></cell>
+ <cell><JButton id='multiply' text='x' onActionPerformed='engine.multiply()' styleClass='operator'/></cell>
+ </row>
+
+ <row>
+ <cell><JButton id='d0' text='0' onActionPerformed='engine.digit(0)' styleClass='digit'/></cell>
+ <cell><JButton id='sign' onActionPerformed='engine.toggleSign()' styleClass='operator'/></cell>
+ <cell><JButton id='dot' text='.' onActionPerformed='engine.dot()' styleClass='digit'/></cell>
+ <cell><JButton id='divide' text='÷' onActionPerformed='engine.divide()' styleClass='operator'/></cell>
+ </row>
+ </Table>
+</DemoPanel>
\ No newline at end of file
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/CalculatorEngine.java (from rev 1109, lutinjaxx/branches/storm_1/jaxx-example/Calculator/src/main/java/examples/Calculator/CalculatorEngine.java)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/CalculatorEngine.java (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/CalculatorEngine.java 2009-01-02 08:23:35 UTC (rev 1111)
@@ -0,0 +1,165 @@
+package examples.Components;
+
+import java.beans.*;
+import java.math.*;
+
+public class CalculatorEngine {
+ public static final String DISPLAY_TEXT_PROPERTY = "displayText";
+
+ public static final int ADD = 0;
+ public static final int SUBTRACT = 1;
+ public static final int MULTIPLY =2;
+ public static final int DIVIDE = 3;
+ public static final int RESULT = 4;
+
+ private int operation = -1;
+ private boolean clear = true; // true to clear on next key
+ private String displayText = "0";
+ private BigDecimal value;
+ private PropertyChangeSupport propertyChangeSupport = new PropertyChangeSupport(this);
+
+
+ public String getDisplayText() {
+ return displayText;
+ }
+
+
+ public void setDisplayText(String displayText) {
+ String oldDisplayText = this.displayText;
+ this.displayText = displayText;
+ firePropertyChange(DISPLAY_TEXT_PROPERTY, oldDisplayText, displayText);
+ }
+
+
+ public void clear() {
+ clearEntry();
+ value = new BigDecimal(0);
+ operation = -1;
+ }
+
+
+ public void clearEntry() {
+ setDisplayText("0");
+ clear = true;
+ }
+
+
+ private void checkClear() {
+ if (clear) {
+ setDisplayText("");
+ clear = false;
+ }
+ }
+
+
+ public void digit(int digit) {
+ checkClear();
+ setDisplayText(getDisplayText() + String.valueOf(digit));
+ }
+
+
+ public void dot() {
+ checkClear();
+ if (getDisplayText().indexOf('.') == -1) {
+ if (getDisplayText().length() == 0)
+ setDisplayText("0.");
+ else
+ setDisplayText(getDisplayText() + '.');
+ }
+ }
+
+
+ public void toggleSign() {
+ String text = getDisplayText();
+ if (text.startsWith("-"))
+ text = text.substring(1);
+ else if (!text.equals("0"))
+ text = '-' + text;
+ setDisplayText(text);
+ }
+
+
+ public void equal() {
+ BigDecimal displayValue = new BigDecimal(getDisplayText());
+ BigDecimal newValue = displayValue;
+ switch (operation) {
+ case ADD: newValue = value.add(displayValue); break;
+ case SUBTRACT: newValue = value.subtract(displayValue); break;
+ case MULTIPLY: newValue = value.multiply(displayValue); break;
+ case DIVIDE: newValue = value.divide(displayValue, 8, BigDecimal.ROUND_HALF_UP); break;
+ }
+ value = newValue;
+ setDisplayText(toString(newValue));
+ clear = true;
+ operation = -1;
+ }
+
+
+ public static String toString(BigDecimal decimal) {
+ // can't use stripTrailingZeros, as it wasn't introduced until 1.5
+ String result = decimal.toString();
+ if (result.indexOf(".") != -1) {
+ while (result.endsWith("0"))
+ result = result.substring(0, result.length() - 1);
+ if (result.endsWith("."))
+ result = result.substring(0, result.length() - 1);
+ }
+ return result;
+ }
+
+
+ public void operation(int operation) {
+ if (this.operation != -1)
+ equal();
+ else {
+ value = new BigDecimal(getDisplayText());
+ clear = true;
+ }
+ this.operation = operation;
+ }
+
+
+ public void add() {
+ operation(ADD);
+ }
+
+
+ public void subtract() {
+ operation(SUBTRACT);
+ }
+
+
+ public void multiply() {
+ operation(MULTIPLY);
+ }
+
+
+ public void divide() {
+ operation(DIVIDE);
+ }
+
+
+ public void addPropertyChangeListener(PropertyChangeListener listener) {
+ propertyChangeSupport.addPropertyChangeListener(listener);
+ }
+
+
+ public void addPropertyChangeListener(String property, PropertyChangeListener listener) {
+ propertyChangeSupport.addPropertyChangeListener(property, listener);
+ }
+
+
+ public void removePropertyChangeListener(PropertyChangeListener listener) {
+ propertyChangeSupport.removePropertyChangeListener(listener);
+ }
+
+
+ public void removePropertyChangeListener(String property, PropertyChangeListener listener) {
+ propertyChangeSupport.removePropertyChangeListener(property, listener);
+ }
+
+
+ protected void firePropertyChange(String property, Object oldValue, Object newValue) {
+ propertyChangeSupport.firePropertyChange(property, oldValue, newValue);
+ }
+}
\ No newline at end of file
Modified: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx 2008-12-30 15:38:45 UTC (rev 1110)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx 2009-01-02 08:23:35 UTC (rev 1111)
@@ -23,44 +23,50 @@
}
}
}'>
- <item value='Buttons'>
- <item value='{buttonDemo}'/>
- <item value='{checkBoxDemo}'/>
- <item value='{radioButtonDemo}'/>
- <item value='{toggleButtonDemo}'/>
- </item>
+ <item value="Components">
+ <item value='Buttons'>
+ <item value='{buttonDemo}'/>
+ <item value='{checkBoxDemo}'/>
+ <item value='{radioButtonDemo}'/>
+ <item value='{toggleButtonDemo}'/>
+ </item>
- <item value='Form elements'>
- <item value='Text'>
- <item value='{passwordFieldDemo}'/>
- <item value='{textFieldDemo}'/>
- <item value='{textAreaDemo}'/>
+ <item value='Form elements'>
+ <item value='Text'>
+ <item value='{passwordFieldDemo}'/>
+ <item value='{textFieldDemo}'/>
+ <item value='{textAreaDemo}'/>
+ </item>
+
+ <item value='{comboBoxDemo}'/>
+ <item value='{listDemo}'/>
+ <item value='{sliderDemo}'/>
+ <item value='{spinnerDemo}'/>
</item>
- <item value='{comboBoxDemo}'/>
- <item value='{listDemo}'/>
- <item value='{sliderDemo}'/>
- <item value='{spinnerDemo}'/>
- </item>
+ <item value='Layout components'>
+ <item value='{splitPaneDemo}'/>
+ </item>
- <item value='Layout components'>
- <item value='{splitPaneDemo}'/>
- </item>
+ <item value='Menus'>
+ <item value='{menuItemDemo}'/>
+ <item value='{checkBoxMenuItemDemo}'/>
+ <item value='{radioButtonMenuItemDemo}'/>
+ </item>
- <item value='Menus'>
- <item value='{menuItemDemo}'/>
- <item value='{checkBoxMenuItemDemo}'/>
- <item value='{radioButtonMenuItemDemo}'/>
- </item>
+ <item value='Windows'>
+ <item value='{dialogDemo}'/>
+ </item>
- <item value='Windows'>
- <item value='{dialogDemo}'/>
+ <item value='{progressBarDemo}'/>
+
</item>
- <item value='{progressBarDemo}'/>
+ <item value='{labelStyleDemo}'/>
- <item value='{labelStyleDemo}'/>
-
+ <item value='{counterDemo}'/>
+ <item value='{calculatorDemo}'/>
+
<item value='New features'>
<item value='Validation'>
<item value='{validationDemo1}'/>
@@ -95,6 +101,8 @@
<ValidationTableDemo id='validationDemo2' constraints='validationDemo2.getLabel()'/>
<BeanDataBindingDemo id='dataBindingDemo' constraints='dataBindingDemo.getLabel()'/>
<LabelStyleDemo id='labelStyleDemo' constraints='labelStyleDemo.getLabel()'/>
+ <CounterDemo id='counterDemo' constraints='counterDemo.getLabel()'/>
+ <CalculatorDemo id='calculatorDemo' constraints='calculatorDemo.getLabel()'/>
</JPanel>
</JSplitPane>
</Application>
\ No newline at end of file
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/CounterDemo.jaxx (from rev 1109, lutinjaxx/branches/storm_1/jaxx-example/Counter/src/main/java/examples/Counter/Counter.jaxx)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/CounterDemo.jaxx (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/CounterDemo.jaxx 2009-01-02 08:23:35 UTC (rev 1111)
@@ -0,0 +1,12 @@
+<DemoPanel>
+ <script>int count;</script>
+ <JPanel id='demoPanel'>
+ <JTextField text='{count}' constraints='BorderLayout.NORTH'/>
+ <HBox constraints='BorderLayout.SOUTH'>
+ <JButton text='Dec (-)' onActionPerformed='count--'/>
+ <JButton text='Reset' onActionPerformed='count = 0'/>
+ <JButton text='Inc (+)' onActionPerformed='count++'/>
+ </HBox>
+ </JPanel>
+
+</DemoPanel>
\ No newline at end of file
Modified: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties 2008-12-30 15:38:45 UTC (rev 1110)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties 2009-01-02 08:23:35 UTC (rev 1111)
@@ -1,3 +1,6 @@
+-=
+.=
+0=
1=
10=
12=
@@ -6,18 +9,27 @@
2=
24=
3=
+4=
+5=
+6=
+7=
+8=
+9=
Age\:=
Animal=
Blue=
Blue\:=
Bold=
Button\ label\:=
+C=
+CE=
Cancel=
Comments\:=
Component\ Demo=
Config\ file\ \:=
Config\ file\:=
Cyan=
+Dec\ (-)=
Demo=
Directory\ file\:=
Editable=
@@ -31,6 +43,7 @@
Green=
Green\:=
Greet=
+Inc\ (+)=
Italic=
JMenu\ demo=
Last\ Name\:=
@@ -45,6 +58,7 @@
Ratio\:=
Red=
Red\:=
+Reset=
Show\ Background=
Show\ password\ dialog=
Sign\ on=
@@ -67,6 +81,7 @@
Working\ directory\:=
Yellow=
Your\ name\:=
+\\u00f7=
adjust\ the\ spacing=
between\ these\ lines=
cancel=
@@ -81,3 +96,4 @@
validator.field=Champ
validator.message=Message
validator.scope=...
+x=
Modified: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties 2008-12-30 15:38:45 UTC (rev 1110)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties 2009-01-02 08:23:35 UTC (rev 1111)
@@ -1,3 +1,6 @@
+-=
+.=
+0=
1=
10=
12=
@@ -6,18 +9,27 @@
2=
24=
3=
+4=
+5=
+6=
+7=
+8=
+9=
Age\:=
Animal=
Blue=
Blue\:=
Bold=
Button\ label\:=
+C=
+CE=
Cancel=
Comments\:=
Component\ Demo=
Config\ file\ \:=
Config\ file\:=
Cyan=
+Dec\ (-)=
Demo=
Directory\ file\:=
Editable=
@@ -31,6 +43,7 @@
Green=
Green\:=
Greet=
+Inc\ (+)=
Italic=
JMenu\ demo=
Last\ Name\:=
@@ -45,6 +58,7 @@
Ratio\:=
Red=
Red\:=
+Reset=
Show\ Background=
Show\ password\ dialog=
Sign\ on=
@@ -67,6 +81,7 @@
Working\ directory\:=
Yellow=
Your\ name\:=
+\\u00f7=
adjust\ the\ spacing=
between\ these\ lines=
cancel=
@@ -81,3 +96,4 @@
validator.field=Champ
validator.message=Message
validator.scope=...
+x=
Modified: lutinjaxx/branches/storm_1/jaxx-example/Components/src/site/fr/rst/index.rst
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/site/fr/rst/index.rst 2008-12-30 15:38:45 UTC (rev 1110)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/site/fr/rst/index.rst 2009-01-02 08:23:35 UTC (rev 1111)
@@ -6,6 +6,13 @@
of the SwingSet demo. Various pages use advanced features such as data binding, scripting, event handling, and
CSS stylesheets.
+Examples/Calculator
+===================
+
+This is an implementation of Challenge #2 from the `XUL Grand Coding Challenge 2004`_ . Because this example program
+has been implemented in so many different languages, you can easily compare JAXX's
+syntax against the competition and decide for yourself which you prefer.
+
Screen shot
-----------
Modified: lutinjaxx/branches/storm_1/jaxx-example/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/pom.xml 2008-12-30 15:38:45 UTC (rev 1110)
+++ lutinjaxx/branches/storm_1/jaxx-example/pom.xml 2009-01-02 08:23:35 UTC (rev 1111)
@@ -25,9 +25,7 @@
</dependencies>
<modules>
- <module>Calculator</module>
<module>Components</module>
- <module>Counter</module>
</modules>
<!-- ************************************************************* -->
1
0
r1110 - lutinjaxx/branches/storm_1/jaxx-example
by tchemit@users.labs.libre-entreprise.org 30 Dec '08
by tchemit@users.labs.libre-entreprise.org 30 Dec '08
30 Dec '08
Author: tchemit
Date: 2008-12-30 15:38:45 +0000 (Tue, 30 Dec 2008)
New Revision: 1110
Removed:
lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/
Log:
move LabelStyle example to Components example
1
0
r1109 - in lutinjaxx/branches/storm_1/jaxx-example: . Components/src/main/java/examples/Components Components/src/main/resources/i18n LabelStyle/src/main/java/examples/LabelStyle
by tchemit@users.labs.libre-entreprise.org 30 Dec '08
by tchemit@users.labs.libre-entreprise.org 30 Dec '08
30 Dec '08
Author: tchemit
Date: 2008-12-30 15:31:02 +0000 (Tue, 30 Dec 2008)
New Revision: 1109
Added:
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/LabelStyle.css
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/LabelStyleDemo.jaxx
Removed:
lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/src/main/java/examples/LabelStyle/LabelStyle.css
lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/src/main/java/examples/LabelStyle/LabelStyle.jaxx
Modified:
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties
lutinjaxx/branches/storm_1/jaxx-example/pom.xml
Log:
move LabelStyle example to Components example
Modified: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx 2008-12-30 15:12:39 UTC (rev 1108)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx 2008-12-30 15:31:02 UTC (rev 1109)
@@ -12,7 +12,7 @@
]]></script>
<JSplitPane>
- <!--JSplitPane dividerLocation='200'-->
+ <!--JSplitPane dividerLocation='200'-->
<JScrollPane>
<JTree id='list' showsRootHandles='true' onValueChanged='changePanel()'
cellRenderer='{new javax.swing.tree.DefaultTreeCellRenderer() {
@@ -59,12 +59,15 @@
<item value='{progressBarDemo}'/>
- <item value='Validation'>
- <item value='{validationDemo1}'/>
- <item value='{validationDemo2}'/>
+ <item value='{labelStyleDemo}'/>
+
+ <item value='New features'>
+ <item value='Validation'>
+ <item value='{validationDemo1}'/>
+ <item value='{validationDemo2}'/>
+ </item>
+ <item value='{dataBindingDemo}'/>
</item>
-
- <item value='{dataBindingDemo}'/>
</JTree>
</JScrollPane>
@@ -91,6 +94,7 @@
<ValidationListDemo id='validationDemo1' constraints='validationDemo1.getLabel()'/>
<ValidationTableDemo id='validationDemo2' constraints='validationDemo2.getLabel()'/>
<BeanDataBindingDemo id='dataBindingDemo' constraints='dataBindingDemo.getLabel()'/>
+ <LabelStyleDemo id='labelStyleDemo' constraints='labelStyleDemo.getLabel()'/>
</JPanel>
</JSplitPane>
</Application>
\ No newline at end of file
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/LabelStyle.css (from rev 1107, lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/src/main/java/examples/LabelStyle/LabelStyle.css)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/LabelStyle.css (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/LabelStyle.css 2008-12-30 15:31:02 UTC (rev 1109)
@@ -0,0 +1,34 @@
+JSlider {
+ paintTicks: true;
+}
+
+JSlider.color {
+ minorTickSpacing: 10;
+ majorTickSpacing: 50;
+ border: { BorderFactory.createEmptyBorder(1, 1, 1, 1) };
+}
+
+JSlider.color:focused {
+ border: { BorderFactory.createLineBorder(Color.BLACK, 1) };
+}
+
+JSlider#red:focused {
+ background: #E7ADAD;
+}
+
+JSlider#green:focused {
+ background: #B2E7AD;
+}
+
+JSlider#blue:focused {
+ background: #ADB2E7;
+}
+
+JSlider#dummySize {
+ minorTickSpacing: 2;
+ majorTickSpacing: 6;
+}
+
+JRadioButton {
+ enabled: { backgroundCheckbox.isSelected() };
+}
\ No newline at end of file
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/LabelStyleDemo.jaxx (from rev 1107, lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/src/main/java/examples/LabelStyle/LabelStyle.jaxx)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/LabelStyleDemo.jaxx (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/LabelStyleDemo.jaxx 2008-12-30 15:31:02 UTC (rev 1109)
@@ -0,0 +1,64 @@
+<DemoPanel>
+ <style source="LabelStyle.css"/>
+
+ <Table id='demoPanel' anchor='north' fill='both'>
+ <row>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell><JLabel text='Text:'/></cell>
+ <cell weightx='1'><JTextField id='text' text='Data Binding'/></cell>
+ </row>
+
+ <row>
+ <cell><JLabel text='Red:'/></cell>
+ <cell><JSlider id='red' value='128' maximum='255' styleClass='color'/></cell>
+ </row>
+
+ <row>
+ <cell><JLabel text='Green:'/></cell>
+ <cell><JSlider id='green' value='0' maximum='255' styleClass='color'/></cell>
+ </row>
+
+ <row>
+ <cell><JLabel text='Blue:'/></cell>
+ <cell><JSlider id='blue' value='255' maximum='255' styleClass='color'/></cell>
+ </row>
+
+ <row>
+ <cell><JLabel text='Size:'/></cell>
+ <cell><JSlider id='dummySize' value='36' minimum='6' maximum='60'/></cell>
+ </row>
+
+ <row>
+ <cell columns='2' fill='both' weighty='1'>
+ <JPanel border='{BorderFactory.createTitledBorder("Preview")}'
+ height='90'
+ layout='{new BorderLayout()}'>
+ <VBox background='{(Color)( backgroundCheckbox.isSelected() ? backgroundColor.getSelectedValue() : null)}'
+ margin='0'
+ horizontalAlignment='center'
+ verticalAlignment='middle'>
+ <JLabel text='{text.getText()}' font-size='{dummySize.getValue()}' foreground='{new Color(red.getValue(), green.getValue(), blue.getValue())}'/>
+ </VBox>
+ </JPanel>
+ </cell>
+ </row>
+ </Table>
+ </cell>
+
+ <cell>
+ <VBox spacing='0' border='{BorderFactory.createTitledBorder("Background")}'>
+ <JCheckBox id='backgroundCheckbox' text='Show Background'/>
+ <JRadioButton text='Red' buttonGroup='backgroundColor' value='{Color.RED}' selected='true'/>
+ <JRadioButton text='Orange' buttonGroup='backgroundColor' value='{Color.ORANGE}'/>
+ <JRadioButton text='Yellow' buttonGroup='backgroundColor' value='{Color.YELLOW}'/>
+ <JRadioButton text='Green' buttonGroup='backgroundColor' value='{Color.GREEN}'/>
+ <JRadioButton text='Cyan' buttonGroup='backgroundColor' value='{Color.CYAN}'/>
+ <JRadioButton text='Blue' buttonGroup='backgroundColor' value='{Color.BLUE}'/>
+ <JRadioButton text='Purple' buttonGroup='backgroundColor' value='{new Color(160, 30, 255)}'/>
+ </VBox>
+ </cell>
+ </row>
+ </Table>
+</DemoPanel>
\ No newline at end of file
Modified: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties 2008-12-30 15:12:39 UTC (rev 1108)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties 2008-12-30 15:31:02 UTC (rev 1109)
@@ -8,6 +8,8 @@
3=
Age\:=
Animal=
+Blue=
+Blue\:=
Bold=
Button\ label\:=
Cancel=
@@ -15,6 +17,7 @@
Component\ Demo=
Config\ file\ \:=
Config\ file\:=
+Cyan=
Demo=
Directory\ file\:=
Editable=
@@ -25,6 +28,8 @@
First\ Name\:=
FirstName\:=
Font\ size=
+Green=
+Green\:=
Greet=
Italic=
JMenu\ demo=
@@ -34,11 +39,17 @@
Mineral=
Normal\ text\:=
OK=
+Orange=
Password\:=
+Purple=
Ratio\:=
+Red=
+Red\:=
+Show\ Background=
Show\ password\ dialog=
Sign\ on=
Simple\ Button=
+Size\:=
Source=
Spacing\:=
Start=
@@ -54,6 +65,7 @@
View=
Welcome\ to\ the\ JAXX\ framework\!=
Working\ directory\:=
+Yellow=
Your\ name\:=
adjust\ the\ spacing=
between\ these\ lines=
Modified: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties 2008-12-30 15:12:39 UTC (rev 1108)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties 2008-12-30 15:31:02 UTC (rev 1109)
@@ -8,6 +8,8 @@
3=
Age\:=
Animal=
+Blue=
+Blue\:=
Bold=
Button\ label\:=
Cancel=
@@ -15,6 +17,7 @@
Component\ Demo=
Config\ file\ \:=
Config\ file\:=
+Cyan=
Demo=
Directory\ file\:=
Editable=
@@ -25,6 +28,8 @@
First\ Name\:=
FirstName\:=
Font\ size=
+Green=
+Green\:=
Greet=
Italic=
JMenu\ demo=
@@ -34,11 +39,17 @@
Mineral=
Normal\ text\:=
OK=
+Orange=
Password\:=
+Purple=
Ratio\:=
+Red=
+Red\:=
+Show\ Background=
Show\ password\ dialog=
Sign\ on=
Simple\ Button=
+Size\:=
Source=
Spacing\:=
Start=
@@ -54,6 +65,7 @@
View=
Welcome\ to\ the\ JAXX\ framework\!=
Working\ directory\:=
+Yellow=
Your\ name\:=
adjust\ the\ spacing=
between\ these\ lines=
Deleted: lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/src/main/java/examples/LabelStyle/LabelStyle.css
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/src/main/java/examples/LabelStyle/LabelStyle.css 2008-12-30 15:12:39 UTC (rev 1108)
+++ lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/src/main/java/examples/LabelStyle/LabelStyle.css 2008-12-30 15:31:02 UTC (rev 1109)
@@ -1,34 +0,0 @@
-JSlider {
- paintTicks: true;
-}
-
-JSlider.color {
- minorTickSpacing: 10;
- majorTickSpacing: 50;
- border: { BorderFactory.createEmptyBorder(1, 1, 1, 1) };
-}
-
-JSlider.color:focused {
- border: { BorderFactory.createLineBorder(Color.BLACK, 1) };
-}
-
-JSlider#red:focused {
- background: #E7ADAD;
-}
-
-JSlider#green:focused {
- background: #B2E7AD;
-}
-
-JSlider#blue:focused {
- background: #ADB2E7;
-}
-
-JSlider#dummySize {
- minorTickSpacing: 2;
- majorTickSpacing: 6;
-}
-
-JRadioButton {
- enabled: { backgroundCheckbox.isSelected() };
-}
\ No newline at end of file
Deleted: lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/src/main/java/examples/LabelStyle/LabelStyle.jaxx
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/src/main/java/examples/LabelStyle/LabelStyle.jaxx 2008-12-30 15:12:39 UTC (rev 1108)
+++ lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/src/main/java/examples/LabelStyle/LabelStyle.jaxx 2008-12-30 15:31:02 UTC (rev 1109)
@@ -1,64 +0,0 @@
-<Application title="LabelStyle.jaxx">
- <style source="LabelStyle.css"/>
-
- <Table anchor='north' fill='both'>
- <row>
- <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
- <Table anchor='west' fill='both'>
- <row>
- <cell><JLabel text='Text:'/></cell>
- <cell weightx='1'><JTextField id='text' text='Data Binding'/></cell>
- </row>
-
- <row>
- <cell><JLabel text='Red:'/></cell>
- <cell><JSlider id='red' value='128' maximum='255' styleClass='color'/></cell>
- </row>
-
- <row>
- <cell><JLabel text='Green:'/></cell>
- <cell><JSlider id='green' value='0' maximum='255' styleClass='color'/></cell>
- </row>
-
- <row>
- <cell><JLabel text='Blue:'/></cell>
- <cell><JSlider id='blue' value='255' maximum='255' styleClass='color'/></cell>
- </row>
-
- <row>
- <cell><JLabel text='Size:'/></cell>
- <cell><JSlider id='dummySize' value='36' minimum='6' maximum='60'/></cell>
- </row>
-
- <row>
- <cell columns='2' fill='both' weighty='1'>
- <JPanel border='{BorderFactory.createTitledBorder("Preview")}'
- height='90'
- layout='{new BorderLayout()}'>
- <VBox background='{(Color)( backgroundCheckbox.isSelected() ? backgroundColor.getSelectedValue() : null)}'
- margin='0'
- horizontalAlignment='center'
- verticalAlignment='middle'>
- <JLabel text='{text.getText()}' font-size='{dummySize.getValue()}' foreground='{new Color(red.getValue(), green.getValue(), blue.getValue())}'/>
- </VBox>
- </JPanel>
- </cell>
- </row>
- </Table>
- </cell>
-
- <cell>
- <VBox spacing='0' border='{BorderFactory.createTitledBorder("Background")}'>
- <JCheckBox id='backgroundCheckbox' text='Show Background'/>
- <JRadioButton text='Red' buttonGroup='backgroundColor' value='{Color.RED}' selected='true'/>
- <JRadioButton text='Orange' buttonGroup='backgroundColor' value='{Color.ORANGE}'/>
- <JRadioButton text='Yellow' buttonGroup='backgroundColor' value='{Color.YELLOW}'/>
- <JRadioButton text='Green' buttonGroup='backgroundColor' value='{Color.GREEN}'/>
- <JRadioButton text='Cyan' buttonGroup='backgroundColor' value='{Color.CYAN}'/>
- <JRadioButton text='Blue' buttonGroup='backgroundColor' value='{Color.BLUE}'/>
- <JRadioButton text='Purple' buttonGroup='backgroundColor' value='{new Color(160, 30, 255)}'/>
- </VBox>
- </cell>
- </row>
- </Table>
-</Application>
\ No newline at end of file
Modified: lutinjaxx/branches/storm_1/jaxx-example/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/pom.xml 2008-12-30 15:12:39 UTC (rev 1108)
+++ lutinjaxx/branches/storm_1/jaxx-example/pom.xml 2008-12-30 15:31:02 UTC (rev 1109)
@@ -28,8 +28,6 @@
<module>Calculator</module>
<module>Components</module>
<module>Counter</module>
- <module>LabelStyle</module>
- <module>BeanDataBinding</module>
</modules>
<!-- ************************************************************* -->
1
0
r1108 - in lutinjaxx/branches/storm_1/jaxx-example: . Components/src/main/java/examples/Components Components/src/main/resources/i18n
by tchemit@users.labs.libre-entreprise.org 30 Dec '08
by tchemit@users.labs.libre-entreprise.org 30 Dec '08
30 Dec '08
Author: tchemit
Date: 2008-12-30 15:12:39 +0000 (Tue, 30 Dec 2008)
New Revision: 1108
Added:
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/BaseBeanDataBinding.jaxx
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/BeanDataBindingDemo.jaxx
Removed:
lutinjaxx/branches/storm_1/jaxx-example/BeanDataBinding/
Modified:
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties
Log:
move BeanDataBinding example to Components example
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/BaseBeanDataBinding.jaxx (from rev 1101, lutinjaxx/branches/storm_1/jaxx-example/BeanDataBinding/src/main/java/examples/BeanDataBinding/BaseBeanDataBinding.jaxx)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/BaseBeanDataBinding.jaxx (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/BaseBeanDataBinding.jaxx 2008-12-30 15:12:39 UTC (rev 1108)
@@ -0,0 +1,21 @@
+<DemoPanel>
+
+ <!-- a full java bean property of the class -->
+ <Boolean id='editing' javaBean='false'/>
+
+ <!-- not full java bean property (must add script...) -->
+ <Boolean id='editing2' constructorParams='false'/>
+
+ <String id='contentMessage' javaBean='"message..."'/>
+
+ <script>
+ public Boolean isEditing2() { return editing2; }
+
+ public void setEditing2(Boolean newValue) {
+ Boolean oldValue = this.editing2;
+ this.editing2 = newValue;
+ firePropertyChange("editing2", oldValue, newValue) ;
+ }
+ </script>
+
+</DemoPanel>
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/BeanDataBindingDemo.jaxx (from rev 1101, lutinjaxx/branches/storm_1/jaxx-example/BeanDataBinding/src/main/java/examples/BeanDataBinding/BeanDataBinding.jaxx)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/BeanDataBindingDemo.jaxx (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/BeanDataBindingDemo.jaxx 2008-12-30 15:12:39 UTC (rev 1108)
@@ -0,0 +1,46 @@
+<BaseBeanDataBinding>
+
+ <Boolean id='editing3' javaBean='true'/>
+
+ <Table id='demoPanel'>
+ <row>
+ <cell columns='2'>
+ <JLabel text='{getContentMessage()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JPanel>
+ <JButton visible='{!isEditing()}' text='edit' onActionPerformed='setEditing(true);'/>
+ <JButton visible='{isEditing()}' text='close' onActionPerformed='setEditing(false);'/>
+ </JPanel>
+ </cell>
+ <cell weightx='1' fill='both'>
+ <JTextField enabled='{isEditing()}' text='to edit'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JPanel>
+ <JButton visible='{!isEditing2()}' text='edit2' onActionPerformed='setEditing2(true);'/>
+ <JButton visible='{isEditing2()}' text='close2' onActionPerformed='setEditing2(false);'/>
+ </JPanel>
+ </cell>
+ <cell weightx='1' fill='both'>
+ <JTextField enabled='{isEditing2()}' text="to edit 2"/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JPanel>
+ <JButton visible='{!isEditing3()}' text='edit3' onActionPerformed='setEditing3(true);'/>
+ <JButton visible='{isEditing3()}' text='close3' onActionPerformed='setEditing3(false);'/>
+ </JPanel>
+ </cell>
+ <cell weightx='1' fill='both'>
+ <JTextField id='edit3' enabled='{isEditing3()}' text="{getContentMessage()}" onKeyReleased='setContentMessage(edit3.getText())'/>
+ </cell>
+ </row>
+ </Table>
+
+</BaseBeanDataBinding>
Modified: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx 2008-12-30 13:30:16 UTC (rev 1107)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx 2008-12-30 15:12:39 UTC (rev 1108)
@@ -58,10 +58,13 @@
</item>
<item value='{progressBarDemo}'/>
+
<item value='Validation'>
<item value='{validationDemo1}'/>
<item value='{validationDemo2}'/>
</item>
+
+ <item value='{dataBindingDemo}'/>
</JTree>
</JScrollPane>
@@ -87,6 +90,7 @@
<JTextAreaDemo id='textAreaDemo' constraints='textAreaDemo.getLabel()'/>
<ValidationListDemo id='validationDemo1' constraints='validationDemo1.getLabel()'/>
<ValidationTableDemo id='validationDemo2' constraints='validationDemo2.getLabel()'/>
+ <BeanDataBindingDemo id='dataBindingDemo' constraints='dataBindingDemo.getLabel()'/>
</JPanel>
</JSplitPane>
</Application>
\ No newline at end of file
Modified: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties 2008-12-30 13:30:16 UTC (rev 1107)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties 2008-12-30 15:12:39 UTC (rev 1108)
@@ -58,6 +58,13 @@
adjust\ the\ spacing=
between\ these\ lines=
cancel=
+close=
+close2=
+close3=
+edit=
+edit2=
+edit3=
+ttt=
valid=
validator.field=Champ
validator.message=Message
Modified: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties 2008-12-30 13:30:16 UTC (rev 1107)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties 2008-12-30 15:12:39 UTC (rev 1108)
@@ -58,6 +58,13 @@
adjust\ the\ spacing=
between\ these\ lines=
cancel=
+close=
+close2=
+close3=
+edit=
+edit2=
+edit3=
+ttt=
valid=
validator.field=Champ
validator.message=Message
1
0
r1107 - in lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources: . i18n
by tchemit@users.labs.libre-entreprise.org 30 Dec '08
by tchemit@users.labs.libre-entreprise.org 30 Dec '08
30 Dec '08
Author: tchemit
Date: 2008-12-30 13:30:16 +0000 (Tue, 30 Dec 2008)
New Revision: 1107
Added:
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties
Log:
passage en 1.0-SNAPSHOT
deplacement des examples Validation (et autres a finir) dans Components
Added: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-en_GB.properties 2008-12-30 13:30:16 UTC (rev 1107)
@@ -0,0 +1,64 @@
+1=
+10=
+12=
+14=
+18=
+2=
+24=
+3=
+Age\:=
+Animal=
+Bold=
+Button\ label\:=
+Cancel=
+Comments\:=
+Component\ Demo=
+Config\ file\ \:=
+Config\ file\:=
+Demo=
+Directory\ file\:=
+Editable=
+Email\ Address\:=
+Email\:=
+Enabled=
+Fancy\ Button=
+First\ Name\:=
+FirstName\:=
+Font\ size=
+Greet=
+Italic=
+JMenu\ demo=
+Last\ Name\:=
+LastName\:=
+Message\ Box=
+Mineral=
+Normal\ text\:=
+OK=
+Password\:=
+Ratio\:=
+Show\ password\ dialog=
+Sign\ on=
+Simple\ Button=
+Source=
+Spacing\:=
+Start=
+Stop=
+Supported\ Swing\ components\:=
+Text2\:=
+Text\:=
+Underline=
+Upper\ case\ text\:=
+Use\ the\ spinner\ to=
+Username\:=
+Vegetable=
+View=
+Welcome\ to\ the\ JAXX\ framework\!=
+Working\ directory\:=
+Your\ name\:=
+adjust\ the\ spacing=
+between\ these\ lines=
+cancel=
+valid=
+validator.field=Champ
+validator.message=Message
+validator.scope=...
Added: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/i18n/Components-fr_FR.properties 2008-12-30 13:30:16 UTC (rev 1107)
@@ -0,0 +1,64 @@
+1=
+10=
+12=
+14=
+18=
+2=
+24=
+3=
+Age\:=
+Animal=
+Bold=
+Button\ label\:=
+Cancel=
+Comments\:=
+Component\ Demo=
+Config\ file\ \:=
+Config\ file\:=
+Demo=
+Directory\ file\:=
+Editable=
+Email\ Address\:=
+Email\:=
+Enabled=
+Fancy\ Button=
+First\ Name\:=
+FirstName\:=
+Font\ size=
+Greet=
+Italic=
+JMenu\ demo=
+Last\ Name\:=
+LastName\:=
+Message\ Box=
+Mineral=
+Normal\ text\:=
+OK=
+Password\:=
+Ratio\:=
+Show\ password\ dialog=
+Sign\ on=
+Simple\ Button=
+Source=
+Spacing\:=
+Start=
+Stop=
+Supported\ Swing\ components\:=
+Text2\:=
+Text\:=
+Underline=
+Upper\ case\ text\:=
+Use\ the\ spinner\ to=
+Username\:=
+Vegetable=
+View=
+Welcome\ to\ the\ JAXX\ framework\!=
+Working\ directory\:=
+Your\ name\:=
+adjust\ the\ spacing=
+between\ these\ lines=
+cancel=
+valid=
+validator.field=Champ
+validator.message=Message
+validator.scope=...
1
0
30 Dec '08
Author: tchemit
Date: 2008-12-30 13:29:56 +0000 (Tue, 30 Dec 2008)
New Revision: 1106
Added:
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Identity.java
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Model.java
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Validation.css
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/ValidationListDemo.jaxx
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/ValidationTableDemo.jaxx
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/examples/Components/Identity-validation.xml
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/examples/Components/Model-validation.xml
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/log4j.properties
Removed:
lutinjaxx/branches/storm_1/jaxx-example/Validation/
Modified:
lutinjaxx/branches/storm_1/jaxx-compiler-api/pom.xml
lutinjaxx/branches/storm_1/jaxx-compiler-swing/pom.xml
lutinjaxx/branches/storm_1/jaxx-compiler-validator/pom.xml
lutinjaxx/branches/storm_1/jaxx-example/BeanDataBinding/pom.xml
lutinjaxx/branches/storm_1/jaxx-example/Calculator/pom.xml
lutinjaxx/branches/storm_1/jaxx-example/Components/pom.xml
lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx
lutinjaxx/branches/storm_1/jaxx-example/Counter/pom.xml
lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/pom.xml
lutinjaxx/branches/storm_1/jaxx-example/pom.xml
lutinjaxx/branches/storm_1/jaxx-runtime-api/pom.xml
lutinjaxx/branches/storm_1/jaxx-runtime-swing/pom.xml
lutinjaxx/branches/storm_1/jaxx-runtime-validator/pom.xml
lutinjaxx/branches/storm_1/jaxx-swing-action/pom.xml
lutinjaxx/branches/storm_1/jaxx-util/pom.xml
lutinjaxx/branches/storm_1/maven-jaxx-plugin/pom.xml
lutinjaxx/branches/storm_1/pom.xml
Log:
passage en 1.0-SNAPSHOT
deplacement des examples Validation (et autres a finir) dans Components
Modified: lutinjaxx/branches/storm_1/jaxx-compiler-api/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-compiler-api/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-compiler-api/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -11,7 +11,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>lutinjaxx</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<artifactId>jaxx-compiler-api</artifactId>
Modified: lutinjaxx/branches/storm_1/jaxx-compiler-swing/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-compiler-swing/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-compiler-swing/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -10,7 +10,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>lutinjaxx</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<artifactId>jaxx-compiler-swing</artifactId>
Modified: lutinjaxx/branches/storm_1/jaxx-compiler-validator/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-compiler-validator/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-compiler-validator/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -10,7 +10,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>lutinjaxx</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<artifactId>jaxx-compiler-validator</artifactId>
Modified: lutinjaxx/branches/storm_1/jaxx-example/BeanDataBinding/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/BeanDataBinding/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-example/BeanDataBinding/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -9,7 +9,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>jaxx-example</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<groupId>org.codelutin.jaxx-example</groupId>
Modified: lutinjaxx/branches/storm_1/jaxx-example/Calculator/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Calculator/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-example/Calculator/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -9,7 +9,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>jaxx-example</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<groupId>org.codelutin.jaxx-example</groupId>
Modified: lutinjaxx/branches/storm_1/jaxx-example/Components/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -1,4 +1,5 @@
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
@@ -9,12 +10,19 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>jaxx-example</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<groupId>org.codelutin.jaxx-example</groupId>
<artifactId>Components</artifactId>
+ <dependencies>
+ <dependency>
+ <groupId>org.codelutin</groupId>
+ <artifactId>jaxx-runtime-validator</artifactId>
+ <scope>compile</scope>
+ </dependency>
+ </dependencies>
<!-- ************************************************************* -->
<!-- *** Project Information ************************************* -->
<!-- ************************************************************* -->
@@ -42,6 +50,31 @@
</includes>
</resource>
</resources>
+
+ <plugins>
+ <plugin>
+ <groupId>org.codelutin</groupId>
+ <artifactId>maven-i18n-plugin</artifactId>
+ <configuration>
+ <entries>
+ <entry>
+ <basedir>${maven.gen.dir}/java/</basedir>
+ <includes>
+ <param>**\/**.java</param>
+ </includes>
+ </entry>
+ </entries>
+ </configuration>
+ <executions>
+ <execution>
+ <goals>
+ <goal>parserJava</goal>
+ <goal>gen</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
</build>
<!-- ************************************************************* -->
<!-- *** Build Environment ************************************** -->
Modified: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Components.jaxx 2008-12-30 13:29:56 UTC (rev 1106)
@@ -1,16 +1,21 @@
-<Application title="Component Demo" width='600' height='600' defaultCloseOperation='exit_on_close'>
- <script>
- protected void changePanel() {
- Object value = list.getSelectionValue();
- if (value instanceof DemoPanel) {
- cardLayout.show(preview, ((DemoPanel) value).getLabel());
- }
- }
- </script>
- <JSplitPane dividerLocation='200'>
- <JScrollPane>
- <JTree id='list' showsRootHandles='true' onValueChanged='changePanel()'
- cellRenderer='{new javax.swing.tree.DefaultTreeCellRenderer() {
+<Application title="Component Demo" width='1024' height='800' defaultCloseOperation='exit_on_close'>
+ <script><![CDATA[
+protected void changePanel() {
+ Object value = list.getSelectionValue();
+ if (value instanceof DemoPanel) {
+ cardLayout.show(preview, ((DemoPanel) value).getLabel());
+ }
+}
+
+// init i18n
+org.codelutin.i18n.I18n.init();
+
+]]></script>
+ <JSplitPane>
+ <!--JSplitPane dividerLocation='200'-->
+ <JScrollPane>
+ <JTree id='list' showsRootHandles='true' onValueChanged='changePanel()'
+ cellRenderer='{new javax.swing.tree.DefaultTreeCellRenderer() {
public Component getTreeCellRendererComponent(JTree tree, Object value, boolean sel, boolean expanded, boolean leaf, int row, boolean hasFocus) {
if (value instanceof DemoPanel)
value = ((DemoPanel) value).getLabel();
@@ -18,64 +23,70 @@
}
}
}'>
- <item value='Buttons'>
- <item value='{buttonDemo}'/>
- <item value='{checkBoxDemo}'/>
- <item value='{radioButtonDemo}'/>
- <item value='{toggleButtonDemo}'/>
- </item>
-
- <item value='Form elements'>
- <item value='Text'>
- <item value='{passwordFieldDemo}'/>
- <item value='{textFieldDemo}'/>
- <item value='{textAreaDemo}'/>
- </item>
-
- <item value='{comboBoxDemo}'/>
- <item value='{listDemo}'/>
- <item value='{sliderDemo}'/>
- <item value='{spinnerDemo}'/>
- </item>
-
- <item value='Layout components'>
- <item value='{splitPaneDemo}'/>
- </item>
+ <item value='Buttons'>
+ <item value='{buttonDemo}'/>
+ <item value='{checkBoxDemo}'/>
+ <item value='{radioButtonDemo}'/>
+ <item value='{toggleButtonDemo}'/>
+ </item>
- <item value='Menus'>
- <item value='{menuItemDemo}'/>
- <item value='{checkBoxMenuItemDemo}'/>
- <item value='{radioButtonMenuItemDemo}'/>
- </item>
-
- <item value='Windows'>
- <item value='{dialogDemo}'/>
- </item>
+ <item value='Form elements'>
+ <item value='Text'>
+ <item value='{passwordFieldDemo}'/>
+ <item value='{textFieldDemo}'/>
+ <item value='{textAreaDemo}'/>
+ </item>
- <item value='{progressBarDemo}'/>
- </JTree>
- </JScrollPane>
-
- <java.awt.CardLayout id='cardLayout'/>
-
- <JPanel id='preview' layout='{cardLayout}'>
- <examples.Components.JButtonDemo id='buttonDemo' constraints='buttonDemo.getLabel()'/>
- <examples.Components.JCheckBoxDemo id='checkBoxDemo' constraints='checkBoxDemo.getLabel()'/>
- <examples.Components.JCheckBoxMenuItemDemo id='checkBoxMenuItemDemo' constraints='checkBoxMenuItemDemo.getLabel()'/>
- <examples.Components.JComboBoxDemo id='comboBoxDemo' constraints='comboBoxDemo.getLabel()'/>
- <examples.Components.JDialogDemo id='dialogDemo' constraints='dialogDemo.getLabel()'/>
- <examples.Components.JListDemo id='listDemo' constraints='listDemo.getLabel()'/>
- <examples.Components.JMenuItemDemo id='menuItemDemo' constraints='menuItemDemo.getLabel()'/>
- <examples.Components.JPasswordFieldDemo id='passwordFieldDemo' constraints='passwordFieldDemo.getLabel()'/>
- <examples.Components.JProgressBarDemo id='progressBarDemo' constraints='progressBarDemo.getLabel()'/>
- <examples.Components.JSliderDemo id='sliderDemo' constraints='sliderDemo.getLabel()'/>
- <examples.Components.JSpinnerDemo id='spinnerDemo' constraints='spinnerDemo.getLabel()'/>
- <examples.Components.JSplitPaneDemo id='splitPaneDemo' constraints='splitPaneDemo.getLabel()'/>
- <examples.Components.JRadioButtonDemo id='radioButtonDemo' constraints='radioButtonDemo.getLabel()'/>
- <examples.Components.JRadioButtonMenuItemDemo id='radioButtonMenuItemDemo' constraints='radioButtonMenuItemDemo.getLabel()'/>
- <examples.Components.JToggleButtonDemo id='toggleButtonDemo' constraints='toggleButtonDemo.getLabel()'/>
- <examples.Components.JTextFieldDemo id='textFieldDemo' constraints='textFieldDemo.getLabel()'/>
- <examples.Components.JTextAreaDemo id='textAreaDemo' constraints='textAreaDemo.getLabel()'/>
- </JPanel>
- </JSplitPane>
+ <item value='{comboBoxDemo}'/>
+ <item value='{listDemo}'/>
+ <item value='{sliderDemo}'/>
+ <item value='{spinnerDemo}'/>
+ </item>
+
+ <item value='Layout components'>
+ <item value='{splitPaneDemo}'/>
+ </item>
+
+ <item value='Menus'>
+ <item value='{menuItemDemo}'/>
+ <item value='{checkBoxMenuItemDemo}'/>
+ <item value='{radioButtonMenuItemDemo}'/>
+ </item>
+
+ <item value='Windows'>
+ <item value='{dialogDemo}'/>
+ </item>
+
+ <item value='{progressBarDemo}'/>
+ <item value='Validation'>
+ <item value='{validationDemo1}'/>
+ <item value='{validationDemo2}'/>
+ </item>
+ </JTree>
+ </JScrollPane>
+
+ <java.awt.CardLayout id='cardLayout'/>
+
+ <JPanel id='preview' layout='{cardLayout}'>
+ <JButtonDemo id='buttonDemo' constraints='buttonDemo.getLabel()'/>
+ <JCheckBoxDemo id='checkBoxDemo' constraints='checkBoxDemo.getLabel()'/>
+ <JCheckBoxMenuItemDemo id='checkBoxMenuItemDemo' constraints='checkBoxMenuItemDemo.getLabel()'/>
+ <JComboBoxDemo id='comboBoxDemo' constraints='comboBoxDemo.getLabel()'/>
+ <JDialogDemo id='dialogDemo' constraints='dialogDemo.getLabel()'/>
+ <JListDemo id='listDemo' constraints='listDemo.getLabel()'/>
+ <JMenuItemDemo id='menuItemDemo' constraints='menuItemDemo.getLabel()'/>
+ <JPasswordFieldDemo id='passwordFieldDemo' constraints='passwordFieldDemo.getLabel()'/>
+ <JProgressBarDemo id='progressBarDemo' constraints='progressBarDemo.getLabel()'/>
+ <JSliderDemo id='sliderDemo' constraints='sliderDemo.getLabel()'/>
+ <JSpinnerDemo id='spinnerDemo' constraints='spinnerDemo.getLabel()'/>
+ <JSplitPaneDemo id='splitPaneDemo' constraints='splitPaneDemo.getLabel()'/>
+ <JRadioButtonDemo id='radioButtonDemo' constraints='radioButtonDemo.getLabel()'/>
+ <JRadioButtonMenuItemDemo id='radioButtonMenuItemDemo' constraints='radioButtonMenuItemDemo.getLabel()'/>
+ <JToggleButtonDemo id='toggleButtonDemo' constraints='toggleButtonDemo.getLabel()'/>
+ <JTextFieldDemo id='textFieldDemo' constraints='textFieldDemo.getLabel()'/>
+ <JTextAreaDemo id='textAreaDemo' constraints='textAreaDemo.getLabel()'/>
+ <ValidationListDemo id='validationDemo1' constraints='validationDemo1.getLabel()'/>
+ <ValidationTableDemo id='validationDemo2' constraints='validationDemo2.getLabel()'/>
+ </JPanel>
+ </JSplitPane>
</Application>
\ No newline at end of file
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Identity.java (from rev 1101, lutinjaxx/branches/storm_1/jaxx-example/Validation/src/main/java/examples/Validation/Identity.java)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Identity.java (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Identity.java 2008-12-30 13:29:56 UTC (rev 1106)
@@ -0,0 +1,103 @@
+package examples.Components;
+
+import java.beans.PropertyChangeListener;
+import java.beans.PropertyChangeSupport;
+import java.io.File;
+
+public class Identity {
+
+ protected String firstName = "";
+
+ protected String lastName = "";
+
+ protected String email = "dummy(a)codelutin.com";
+
+ protected int age = 51;
+
+ protected File config = new File("/tmp");
+
+ protected File dir = new File("/tmp");
+
+ PropertyChangeSupport p;
+
+ public Identity() {
+ p = new PropertyChangeSupport(this);
+ }
+
+ public void addPropertyChangeListener(PropertyChangeListener listener) {
+ p.addPropertyChangeListener(listener);
+ }
+
+ public void addPropertyChangeListener(String propertyName, PropertyChangeListener listener) {
+ p.addPropertyChangeListener(propertyName, listener);
+ }
+
+ public void removePropertyChangeListener(PropertyChangeListener listener) {
+ p.removePropertyChangeListener(listener);
+ }
+
+ public void removePropertyChangeListener(String propertyName, PropertyChangeListener listener) {
+ p.removePropertyChangeListener(propertyName, listener);
+ }
+
+
+ public String getFirstName() {
+ return firstName;
+ }
+
+ public String getLastName() {
+ return lastName;
+ }
+
+ public String getEmail() {
+ return email;
+ }
+
+ public int getAge() {
+ return age;
+ }
+
+ public File getConfig() {
+ return config;
+ }
+
+ public File getDir() {
+ return dir;
+ }
+
+ public void setFirstName(String firstName) {
+ String oldFirstName = this.firstName;
+ this.firstName = firstName;
+ p.firePropertyChange("firstName", oldFirstName, firstName);
+ }
+
+ public void setLastName(String lastName) {
+ String oldLastName = this.lastName;
+ this.lastName = lastName;
+ p.firePropertyChange("lastName", oldLastName, lastName);
+ }
+
+ public void setEmail(String email) {
+ String oldEmail = this.email;
+ this.email = email;
+ p.firePropertyChange("email", oldEmail, email);
+ }
+
+ public void setAge(int age) {
+ int oldAge = this.age;
+ this.age = age;
+ p.firePropertyChange("age", oldAge, age);
+ }
+
+ public void setConfig(File config) {
+ File oldConfig = this.config;
+ this.config = config;
+ p.firePropertyChange("config", oldConfig, config);
+ }
+
+ public void setDir(File dir) {
+ File oldDir = this.dir;
+ this.dir = dir;
+ p.firePropertyChange("dir", oldDir, dir);
+ }
+}
\ No newline at end of file
Property changes on: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Identity.java
___________________________________________________________________
Name: svn:mergeinfo
+
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Model.java (from rev 1101, lutinjaxx/branches/storm_1/jaxx-example/Validation/src/main/java/examples/Validation/Model.java)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Model.java (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Model.java 2008-12-30 13:29:56 UTC (rev 1106)
@@ -0,0 +1,66 @@
+package examples.Components;
+
+import java.beans.*;
+
+public class Model {
+
+ protected String text = "text";
+
+ protected String text2 = "text2";
+
+ protected int ratio = 51;
+
+
+ PropertyChangeSupport p;
+
+ public Model() {
+ p = new PropertyChangeSupport(this);
+ }
+
+ public void addPropertyChangeListener(PropertyChangeListener listener) {
+ p.addPropertyChangeListener(listener);
+ }
+
+ public void addPropertyChangeListener(String propertyName, PropertyChangeListener listener) {
+ p.addPropertyChangeListener(propertyName, listener);
+ }
+
+ public void removePropertyChangeListener(PropertyChangeListener listener) {
+ p.removePropertyChangeListener(listener);
+ }
+
+ public void removePropertyChangeListener(String propertyName, PropertyChangeListener listener) {
+ p.removePropertyChangeListener(propertyName, listener);
+ }
+
+
+ public String getText() {
+ return text;
+ }
+
+ public String getText2() {
+ return text2;
+ }
+
+ public int getRatio() {
+ return ratio;
+ }
+
+ public void setText(String text) {
+ String oldText = this.text;
+ this.text = text;
+ p.firePropertyChange("text", oldText, text);
+ }
+
+ public void setText2(String text2) {
+ String oldText2 = this.text2;
+ this.text2 = text2;
+ p.firePropertyChange("text2", oldText2, text2);
+ }
+
+ public void setRatio(int ratio) {
+ int oldRatio = this.ratio;
+ this.ratio = ratio;
+ p.firePropertyChange("ratio",oldRatio, ratio);
+ }
+}
\ No newline at end of file
Property changes on: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Model.java
___________________________________________________________________
Name: svn:mergeinfo
+
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Validation.css (from rev 1101, lutinjaxx/branches/storm_1/jaxx-example/Validation/src/main/java/examples/Validation/Validation.css)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Validation.css (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/Validation.css 2008-12-30 13:29:56 UTC (rev 1106)
@@ -0,0 +1,5 @@
+JSlider {
+ paintTicks: true;
+ minorTickSpacing: 5;
+ majorTickSpacing: 10;
+}
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/ValidationListDemo.jaxx (from rev 1101, lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/JButtonDemo.jaxx)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/ValidationListDemo.jaxx (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/ValidationListDemo.jaxx 2008-12-30 13:29:56 UTC (rev 1106)
@@ -0,0 +1,306 @@
+<DemoPanel>
+ <style source="Validation.css"/>
+
+ <!-- models -->
+ <Model id='model1'/>
+ <Model id='model2'/>
+ <Identity id='identity'/>
+
+ <!-- errors model -->
+ <jaxx.runtime.validator.BeanValidatorErrorListModel id='errors' onContentsChanged='ok.setEnabled(errors.isEmpty())'/>
+
+ <!-- validators -->
+ <BeanValidator id='validator' bean='model1' uiClass="jaxx.runtime.validator.ui.ImageValidationUI">
+ <field name="text"/>
+ <field name="text2"/>
+ <field name="ratio"/>
+ </BeanValidator>
+ <BeanValidator id='validator2' bean='model2' uiClass="jaxx.runtime.validator.ui.IconValidationUI" scope='WARNING'>
+ <field name="text" component="_text"/>
+ <field name="text2" component="_text2"/>
+ <field name="ratio" component="_ratio"/>
+ </BeanValidator>
+ <BeanValidator id='validator3' autoField='true' bean='identity' uiClass="jaxx.runtime.validator.ui.TranslucentValidationUI">
+ <field name="email" component="email2"/>
+ </BeanValidator>
+
+ <Table fill='both' id='demoPanel'>
+ <row>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <JPanel border='{BorderFactory.createTitledBorder("Form")}'
+ layout='{new GridLayout()}' width='250' height='120'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell>
+ <JLabel text='Text:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='text' text='{model1.getText()}'
+ onKeyReleased='model1.setText(text.getText())'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Text2:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='text2' text='{model1.getText2()}'
+ onKeyReleased='model1.setText2(text2.getText())'/>
+ </cell>
+ </row>
+
+ <row>
+ <cell>
+ <JLabel text='Ratio:'/>
+ </cell>
+ <cell>
+ <JSlider id='ratio' minimum='0' maximum='100' value='{model1.getRatio()}'
+ onStateChanged='model1.setRatio(ratio.getValue())'/>
+ </cell>
+ </row>
+ </Table>
+ </JPanel>
+ </cell>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <JPanel border='{BorderFactory.createTitledBorder("Model")}'
+ layout='{new GridLayout()}' width='250' height='120'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell>
+ <JLabel text='Text:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{model1.getText()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Text2:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{model1.getText2()}'/>
+ </cell>
+ </row>
+
+ <row>
+ <cell>
+ <JLabel text='Ratio:'/>
+ </cell>
+ <cell>
+ <JLabel text='{model1.getRatio()}'/>
+ </cell>
+ </row>
+ </Table>
+ </JPanel>
+ </cell>
+ </row>
+ <row>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <JPanel border='{BorderFactory.createTitledBorder("Form2")}'
+ layout='{new GridLayout()}' width='250' height='120'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell>
+ <JLabel text='Text:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='_text' text='{model2.getText()}'
+ onKeyReleased='model2.setText(_text.getText())'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Text2:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='_text2' text='{model2.getText2()}'
+ onKeyReleased='model2.setText2(_text2.getText())'/>
+ </cell>
+ </row>
+
+ <row>
+ <cell>
+ <JLabel text='Ratio:'/>
+ </cell>
+ <cell>
+ <JSlider id='_ratio' minimum='0' maximum='100' value='{model2.getRatio()}'
+ onStateChanged='model2.setRatio(_ratio.getValue())'/>
+ </cell>
+ </row>
+ </Table>
+ </JPanel>
+ </cell>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <JPanel border='{BorderFactory.createTitledBorder("Model2")}'
+ layout='{new GridLayout()}' width='250' height='120'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell>
+ <JLabel text='Text:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{model2.getText()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Text2:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{model2.getText2()}'/>
+ </cell>
+ </row>
+
+ <row>
+ <cell>
+ <JLabel text='Ratio:'/>
+ </cell>
+ <cell>
+ <JLabel text='{model2.getRatio()}'/>
+ </cell>
+ </row>
+ </Table>
+ </JPanel>
+ </cell>
+ </row>
+ <row>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <JPanel border='{BorderFactory.createTitledBorder("Identify Form")}'
+ layout='{new GridLayout()}' width='250' height='180'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell>
+ <JLabel text='FirstName:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='firstName' text='{identity.getFirstName()}'
+ onKeyReleased='identity.setFirstName(firstName.getText())'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='LastName:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='lastName' text='{identity.getLastName()}'
+ onKeyReleased='identity.setLastName(lastName.getText())'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Email:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='email2' text='{identity.getEmail()}'
+ onKeyReleased='identity.setEmail(email2.getText())'/>
+ </cell>
+ </row>
+
+ <row>
+ <cell>
+ <JLabel text='Age:'/>
+ </cell>
+ <cell>
+ <JSlider id='age' minimum='0' maximum='100' value='{identity.getAge()}'
+ onStateChanged='identity.setAge(age.getValue())'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Config file :'/>
+ </cell>
+ <cell>
+ <JTextField id='config' text='{identity.getConfig()}'
+ onKeyReleased='identity.setConfig(new java.io.File(config.getText()))'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Working directory:'/>
+ </cell>
+ <cell>
+ <JTextField id='dir' text='{identity.getDir()}'
+ onKeyReleased='identity.setDir(new java.io.File(dir.getText()))'/>
+ </cell>
+ </row>
+ </Table>
+ </JPanel>
+ </cell>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <JPanel border='{BorderFactory.createTitledBorder("Identity Model")}'
+ layout='{new GridLayout()}' width='250' height='120'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell>
+ <JLabel text='FirstName:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{identity.getFirstName()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='LastName:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{identity.getLastName()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Email:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{identity.getEmail()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Age:'/>
+ </cell>
+ <cell>
+ <JLabel text='{identity.getAge()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Config file:'/>
+ </cell>
+ <cell>
+ <JLabel text='{identity.getConfig()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Directory file:'/>
+ </cell>
+ <cell>
+ <JLabel text='{identity.getDir()}'/>
+ </cell>
+ </row>
+ </Table>
+ </JPanel>
+ </cell>
+ </row>
+ <row>
+ <cell columns='2' fill="both">
+ <JPanel border='{BorderFactory.createTitledBorder("Errors")}' layout='{new GridLayout()}' height='200' width='500'>
+ <JScrollPane>
+ <JList id='errorList' model='{errors}'/>
+ </JScrollPane>
+ </JPanel>
+ </cell>
+ </row>
+ <row>
+ <cell columns='2' fill="both">
+ <JPanel layout='{new GridLayout(1,2,0,0)}'>
+ <JButton id='cancel' text='cancel'
+ onActionPerformed='JOptionPane.showMessageDialog(this, cancel.getText() + " clicked!", "onActionPerformed", JOptionPane.INFORMATION_MESSAGE);'/>
+ <JButton id='ok' text='valid'
+ onActionPerformed='JOptionPane.showMessageDialog(this, ok.getText() + " clicked!", "onActionPerformed", JOptionPane.INFORMATION_MESSAGE);'/>
+ </JPanel>
+ </cell>
+ </row>
+ </Table>
+
+</DemoPanel>
\ No newline at end of file
Property changes on: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/ValidationListDemo.jaxx
___________________________________________________________________
Name: svn:mergeinfo
+
Added: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/ValidationTableDemo.jaxx
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/ValidationTableDemo.jaxx (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/java/examples/Components/ValidationTableDemo.jaxx 2008-12-30 13:29:56 UTC (rev 1106)
@@ -0,0 +1,326 @@
+<DemoPanel>
+ <style source="Validation.css"/>
+
+ <!-- models -->
+ <Model id='model1'/>
+ <Model id='model2'/>
+ <Identity id='identity'/>
+
+ <!-- errors model -->
+ <jaxx.runtime.validator.BeanValidatorErrorTableModel id='errors2' onTableChanged='ok.setEnabled(errors2.getRowCount()==0)'/>
+
+ <!-- validators -->
+ <BeanValidator id='validator' bean='model1' uiClass="jaxx.runtime.validator.ui.ImageValidationUI">
+ <field name="text"/>
+ <field name="text2"/>
+ <field name="ratio"/>
+ </BeanValidator>
+ <BeanValidator id='validator2' bean='model2' uiClass="jaxx.runtime.validator.ui.IconValidationUI" scope='WARNING'>
+ <field name="text" component="_text"/>
+ <field name="text2" component="_text2"/>
+ <field name="ratio" component="_ratio"/>
+ </BeanValidator>
+ <BeanValidator id='validator3' autoField='true' bean='identity'
+ uiClass="jaxx.runtime.validator.ui.TranslucentValidationUI">
+ <field name="email" component="email2"/>
+ </BeanValidator>
+
+ <script><![CDATA[
+import static org.codelutin.i18n.I18n.n_;
+import jaxx.runtime.swing.Utils;
+
+static boolean wasinit=false;
+
+errorTable.setDefaultRenderer(Object.class, new jaxx.runtime.validator.ErrorTableRenderer());
+Utils.setI18nTableHeaderRenderer(errorTable, n_("validator.scope"), n_("validator.field"), n_("validator.message"));
+public void setVisible(boolean value) {
+ if (!wasinit) {
+ Utils.fixTableColumnWidth(errorTable, 0, 20);
+ wasinit=true;
+ }
+ super.setVisible(value);
+}
+]]></script>
+
+ <Table fill='both' id='demoPanel'>
+ <row>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <JPanel border='{BorderFactory.createTitledBorder("Form")}'
+ layout='{new GridLayout()}' width='250' height='120'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell>
+ <JLabel text='Text:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='text' text='{model1.getText()}'
+ onKeyReleased='model1.setText(text.getText())'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Text2:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='text2' text='{model1.getText2()}'
+ onKeyReleased='model1.setText2(text2.getText())'/>
+ </cell>
+ </row>
+
+ <row>
+ <cell>
+ <JLabel text='Ratio:'/>
+ </cell>
+ <cell>
+ <JSlider id='ratio' minimum='0' maximum='100' value='{model1.getRatio()}'
+ onStateChanged='model1.setRatio(ratio.getValue())'/>
+ </cell>
+ </row>
+ </Table>
+ </JPanel>
+ </cell>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <JPanel border='{BorderFactory.createTitledBorder("Model")}'
+ layout='{new GridLayout()}' width='250' height='120'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell>
+ <JLabel text='Text:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{model1.getText()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Text2:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{model1.getText2()}'/>
+ </cell>
+ </row>
+
+ <row>
+ <cell>
+ <JLabel text='Ratio:'/>
+ </cell>
+ <cell>
+ <JLabel text='{model1.getRatio()}'/>
+ </cell>
+ </row>
+ </Table>
+ </JPanel>
+ </cell>
+ </row>
+ <row>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <JPanel border='{BorderFactory.createTitledBorder("Form2")}'
+ layout='{new GridLayout()}' width='250' height='120'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell>
+ <JLabel text='Text:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='_text' text='{model2.getText()}'
+ onKeyReleased='model2.setText(_text.getText())'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Text2:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='_text2' text='{model2.getText2()}'
+ onKeyReleased='model2.setText2(_text2.getText())'/>
+ </cell>
+ </row>
+
+ <row>
+ <cell>
+ <JLabel text='Ratio:'/>
+ </cell>
+ <cell>
+ <JSlider id='_ratio' minimum='0' maximum='100' value='{model2.getRatio()}'
+ onStateChanged='model2.setRatio(_ratio.getValue())'/>
+ </cell>
+ </row>
+ </Table>
+ </JPanel>
+ </cell>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <JPanel border='{BorderFactory.createTitledBorder("Model2")}'
+ layout='{new GridLayout()}' width='250' height='120'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell>
+ <JLabel text='Text:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{model2.getText()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Text2:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{model2.getText2()}'/>
+ </cell>
+ </row>
+
+ <row>
+ <cell>
+ <JLabel text='Ratio:'/>
+ </cell>
+ <cell>
+ <JLabel text='{model2.getRatio()}'/>
+ </cell>
+ </row>
+ </Table>
+ </JPanel>
+ </cell>
+ </row>
+ <row>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <JPanel border='{BorderFactory.createTitledBorder("Identify Form")}'
+ layout='{new GridLayout()}' width='250' height='180'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell>
+ <JLabel text='FirstName:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='firstName' text='{identity.getFirstName()}'
+ onKeyReleased='identity.setFirstName(firstName.getText())'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='LastName:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='lastName' text='{identity.getLastName()}'
+ onKeyReleased='identity.setLastName(lastName.getText())'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Email:'/>
+ </cell>
+ <cell weightx='1'>
+ <JTextField id='email2' text='{identity.getEmail()}'
+ onKeyReleased='identity.setEmail(email2.getText())'/>
+ </cell>
+ </row>
+
+ <row>
+ <cell>
+ <JLabel text='Age:'/>
+ </cell>
+ <cell>
+ <JSlider id='age' minimum='0' maximum='100' value='{identity.getAge()}'
+ onStateChanged='identity.setAge(age.getValue())'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Config file :'/>
+ </cell>
+ <cell>
+ <JTextField id='config' text='{identity.getConfig()}'
+ onKeyReleased='identity.setConfig(new java.io.File(config.getText()))'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Working directory:'/>
+ </cell>
+ <cell>
+ <JTextField id='dir' text='{identity.getDir()}'
+ onKeyReleased='identity.setDir(new java.io.File(dir.getText()))'/>
+ </cell>
+ </row>
+ </Table>
+ </JPanel>
+ </cell>
+ <cell weightx='1' weighty='1' insets='6, 3, 0, 0'>
+ <JPanel border='{BorderFactory.createTitledBorder("Identity Model")}'
+ layout='{new GridLayout()}' width='250' height='120'>
+ <Table anchor='west' fill='both'>
+ <row>
+ <cell>
+ <JLabel text='FirstName:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{identity.getFirstName()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='LastName:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{identity.getLastName()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Email:'/>
+ </cell>
+ <cell weightx='1'>
+ <JLabel text='{identity.getEmail()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Age:'/>
+ </cell>
+ <cell>
+ <JLabel text='{identity.getAge()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Config file:'/>
+ </cell>
+ <cell>
+ <JLabel text='{identity.getConfig()}'/>
+ </cell>
+ </row>
+ <row>
+ <cell>
+ <JLabel text='Directory file:'/>
+ </cell>
+ <cell>
+ <JLabel text='{identity.getDir()}'/>
+ </cell>
+ </row>
+ </Table>
+ </JPanel>
+ </cell>
+ </row>
+ <row>
+ <cell columns='2' fill="both">
+ <JPanel border='{BorderFactory.createTitledBorder("Errors")}' layout='{new GridLayout()}' height='200'
+ width='500'>
+ <JScrollPane columnHeaderView='{errorTable.getTableHeader()}'>
+ <JTable id='errorTable' model='{errors2}' rowSelectionAllowed='true'
+ autoResizeMode='2' cellSelectionEnabled='false' selectionMode='0'/>
+ </JScrollPane>
+ </JPanel>
+ </cell>
+ </row>
+ <row>
+ <cell columns='2' fill="both">
+ <JPanel layout='{new GridLayout(1,2,0,0)}'>
+ <JButton id='cancel' text='cancel'
+ onActionPerformed='JOptionPane.showMessageDialog(this, cancel.getText() + " clicked!", "onActionPerformed", JOptionPane.INFORMATION_MESSAGE);'/>
+ <JButton id='ok' text='valid'
+ onActionPerformed='JOptionPane.showMessageDialog(this, ok.getText() + " clicked!", "onActionPerformed", JOptionPane.INFORMATION_MESSAGE);'/>
+ </JPanel>
+ </cell>
+ </row>
+ </Table>
+
+</DemoPanel>
\ No newline at end of file
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/examples/Components/Identity-validation.xml (from rev 1101, lutinjaxx/branches/storm_1/jaxx-example/Validation/src/main/resources/examples/Validation/Identity-validation.xml)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/examples/Components/Identity-validation.xml (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/examples/Components/Identity-validation.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -0,0 +1,50 @@
+<!DOCTYPE validators PUBLIC
+ "-//OpenSymphony Group//XWork Validator 1.0.2//EN"
+ "http://www.opensymphony.com/xwork/xwork-validator-1.0.2.dtd">
+<validators>
+ <field name="firstName">
+ <field-validator type="requiredstring" short-circuit="true">
+ <message>You must enter a firstName.</message>
+ </field-validator>
+ </field>
+ <field name="lastName">
+ <field-validator type="requiredstring" short-circuit="true">
+ <message>You must enter a lastName.</message>
+ </field-validator>
+ </field>
+
+ <field name="email">
+ <field-validator type="requiredstring" short-circuit="true">
+ <message>You must enter a value for email.</message>
+ </field-validator>
+ <field-validator type="email" short-circuit="true">
+ <message>Not a valid e-mail.</message>
+ </field-validator>
+ </field>
+
+ <field name="config">
+ <field-validator type="requiredFile" short-circuit="true">
+ <message>You must enter a value for config.</message>
+ </field-validator>
+ <field-validator type="existingFile" short-circuit="true">
+ <message>The configuration file ${config} does not exist.</message>
+ </field-validator>
+ </field>
+
+ <field name="dir">
+ <field-validator type="requiredFile" short-circuit="true">
+ <message>You must enter a value for dir.</message>
+ </field-validator>
+ <field-validator type="existingDirectory" short-circuit="true">
+ <message>The directory ${dir} does not exist.</message>
+ </field-validator>
+ </field>
+
+ <field name="age">
+ <field-validator type="int">
+ <param name="min">18</param>
+ <param name="max">88</param>
+ <message>Age needs to be between ${min} and ${max}</message>
+ </field-validator>
+ </field>
+</validators>
\ No newline at end of file
Property changes on: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/examples/Components/Identity-validation.xml
___________________________________________________________________
Name: svn:mergeinfo
+
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/examples/Components/Model-validation.xml (from rev 1101, lutinjaxx/branches/storm_1/jaxx-example/Validation/src/main/resources/examples/Validation/Model-validation.xml)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/examples/Components/Model-validation.xml (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/examples/Components/Model-validation.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -0,0 +1,41 @@
+<!DOCTYPE validators PUBLIC
+ "-//OpenSymphony Group//XWork Validator 1.0.2//EN"
+ "http://www.opensymphony.com/xwork/xwork-validator-1.0.2.dtd">
+<validators>
+ <!-- Field Validators for email field -->
+ <field name="text">
+ <field-validator type="requiredstring" short-circuit="true">
+ <message>You must enter a value for text.</message>
+ </field-validator>
+ <field-validator type="email" short-circuit="true">
+ <message>Not a valid e-mail for text.</message>
+ </field-validator>
+ </field>
+
+ <field name="text2">
+ <field-validator type="requiredstring" short-circuit="true">
+ <message>You must enter a value for text2.</message>
+ </field-validator>
+ <field-validator type="email" short-circuit="true">
+ <message>Not a valid e-mail for text2.</message>
+ </field-validator>
+ </field>
+
+ <field name="ratio">
+ <field-validator type="int">
+ <param name="min">20</param>
+ <param name="max">50</param>
+ <message>Ratio needs to be between ${min} and ${max}</message>
+ </field-validator>
+ </field>
+
+ <!-- Plain Validator 1 -->
+ <validator type="expression">
+ <param name="expression">text.startsWith("poussin")</param>
+ <message>Email not starts with poussin</message>
+ </validator>
+ <validator type="expression">
+ <param name="expression">text2.startsWith("chemit")</param>
+ <message>Email not starts with chemit</message>
+ </validator>
+</validators>
\ No newline at end of file
Copied: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/log4j.properties (from rev 1101, lutinjaxx/branches/storm_1/jaxx-example/Validation/src/main/resources/log4j.properties)
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/log4j.properties (rev 0)
+++ lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/log4j.properties 2008-12-30 13:29:56 UTC (rev 1106)
@@ -0,0 +1,9 @@
+# Global logging configuration
+log4j.rootLogger=INFO, stdout
+# Console output...
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%5p [%t] (%F:%L) %M - %m%n
+
+#log4j.logger.org.codelutin.jaxx=DEBUG
+log4j.logger.examples=DEBUG
Property changes on: lutinjaxx/branches/storm_1/jaxx-example/Components/src/main/resources/log4j.properties
___________________________________________________________________
Name: svn:mergeinfo
+
Modified: lutinjaxx/branches/storm_1/jaxx-example/Counter/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/Counter/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-example/Counter/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -9,7 +9,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>jaxx-example</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<groupId>org.codelutin.jaxx-example</groupId>
Modified: lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-example/LabelStyle/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -9,7 +9,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>jaxx-example</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<groupId>org.codelutin.jaxx-example</groupId>
Modified: lutinjaxx/branches/storm_1/jaxx-example/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-example/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-example/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -9,7 +9,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>lutinjaxx</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<artifactId>jaxx-example</artifactId>
@@ -29,7 +29,6 @@
<module>Components</module>
<module>Counter</module>
<module>LabelStyle</module>
- <module>Validation</module>
<module>BeanDataBinding</module>
</modules>
Modified: lutinjaxx/branches/storm_1/jaxx-runtime-api/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-runtime-api/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-runtime-api/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -11,7 +11,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>lutinjaxx</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<artifactId>jaxx-runtime-api</artifactId>
Modified: lutinjaxx/branches/storm_1/jaxx-runtime-swing/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-runtime-swing/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-runtime-swing/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -10,7 +10,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>lutinjaxx</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<artifactId>jaxx-runtime-swing</artifactId>
Modified: lutinjaxx/branches/storm_1/jaxx-runtime-validator/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-runtime-validator/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-runtime-validator/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -10,7 +10,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>lutinjaxx</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<artifactId>jaxx-runtime-validator</artifactId>
Modified: lutinjaxx/branches/storm_1/jaxx-swing-action/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-swing-action/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-swing-action/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -11,7 +11,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>lutinjaxx</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<artifactId>jaxx-swing-action</artifactId>
Modified: lutinjaxx/branches/storm_1/jaxx-util/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/jaxx-util/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/jaxx-util/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -9,7 +9,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>lutinjaxx</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<artifactId>jaxx-util</artifactId>
Modified: lutinjaxx/branches/storm_1/maven-jaxx-plugin/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/maven-jaxx-plugin/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/maven-jaxx-plugin/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -10,7 +10,7 @@
<parent>
<groupId>org.codelutin</groupId>
<artifactId>lutinjaxx</artifactId>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
</parent>
<artifactId>maven-jaxx-plugin</artifactId>
Modified: lutinjaxx/branches/storm_1/pom.xml
===================================================================
--- lutinjaxx/branches/storm_1/pom.xml 2008-12-30 10:54:58 UTC (rev 1105)
+++ lutinjaxx/branches/storm_1/pom.xml 2008-12-30 13:29:56 UTC (rev 1106)
@@ -40,7 +40,7 @@
<!-- *** Project Information ************************************* -->
<!-- ************************************************************* -->
<name>lutinjaxx</name>
- <version>0.8-SNAPSHOT</version>
+ <version>1.0-SNAPSHOT</version>
<description>Jaxx lutin library main pom</description>
<inceptionYear>2008</inceptionYear>
1
0