You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pivot.apache.org by gb...@apache.org on 2009/05/27 15:42:01 UTC

svn commit: r779169 [1/3] - in /incubator/pivot/trunk: ./ core/src/pivot/beans/ core/src/pivot/collections/ core/src/pivot/collections/adapter/ core/src/pivot/serialization/ core/src/pivot/util/concurrent/ core/test/pivot/core/test/ core/test/resources...

Author: gbrown
Date: Wed May 27 13:41:59 2009
New Revision: 779169

URL: http://svn.apache.org/viewvc?rev=779169&view=rev
Log:
Add ByteArraySerializer and associated test case; update RELEASE-NOTES; reduce priority of Dispatcher threads to MIN_PRIORITY; add detab regex to trim-whitespace Ant target and apply to source tree.

Modified:
    incubator/pivot/trunk/RELEASE-NOTES
    incubator/pivot/trunk/build.xml
    incubator/pivot/trunk/core/src/pivot/beans/BeanDictionary.java
    incubator/pivot/trunk/core/src/pivot/collections/ArrayList.java
    incubator/pivot/trunk/core/src/pivot/collections/adapter/ListAdapter.java
    incubator/pivot/trunk/core/src/pivot/serialization/JSONSerializer.java
    incubator/pivot/trunk/core/src/pivot/util/concurrent/Dispatcher.java
    incubator/pivot/trunk/core/test/pivot/core/test/JSONSerializerTest.java
    incubator/pivot/trunk/core/test/pivot/core/test/ResourcesTest.java
    incubator/pivot/trunk/core/test/resources/test1.json
    incubator/pivot/trunk/core/test/resources/test2.json
    incubator/pivot/trunk/core/test/resources/test2_en.json
    incubator/pivot/trunk/core/test/resources/test3.json
    incubator/pivot/trunk/core/test/resources/test3_en.json
    incubator/pivot/trunk/core/test/resources/test3_en_GB.json
    incubator/pivot/trunk/core/test/resources/test4.json
    incubator/pivot/trunk/core/test/resources/test6.json
    incubator/pivot/trunk/core/test/resources/test6_en.json
    incubator/pivot/trunk/core/test/resources/test6_en_GB.json
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/Demo.java
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/Address.java
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/Contact.java
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/DataBinding.java
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/IMAccount.java
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/lists.wtkx
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/menu_buttons.wtkx
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/menu_popup.wtkx
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/meters.wtkx
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/spinners.wtkx
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/StockTracker.json
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/StockTracker_fr.json
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/stocktracker.detail.wtkx
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/stocktracker.wtkx
    incubator/pivot/trunk/tutorials/src/pivot/tutorials/text.wtkx
    incubator/pivot/trunk/web/test/pivot/web/test/QueryDictionaryTest.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/Accordion.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/AccordionSelectionListener.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/Alert.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/BrowserApplicationContext.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/CardPane.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/CardPaneListener.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/Dialog.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/Label.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/ScriptApplication.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/Sheet.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/Slider.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/SliderListener.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/SliderValueListener.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/TabPane.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/TabPaneSelectionListener.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/TableView.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/content/ColorItem.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/content/ListButtonColorRenderer.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/content/ListViewColorRenderer.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/effects/ClipDecorator.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/effects/Transition.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/skin/SliderSkin.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/skin/obsidian/ObsidianTheme.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraAccordionSkin.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraExpanderSkin.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraFrameSkin.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraListButtonSkin.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraMenuButtonSkin.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraPanoramaSkin.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraPushButtonSkin.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraRadioButtonSkin.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraSliderSkin.java
    incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraTabPaneSkin.java
    incubator/pivot/trunk/wtk/test/pivot/wtk/test/CardPaneTest.java
    incubator/pivot/trunk/wtk/test/pivot/wtk/test/CheckedListViewTest.java
    incubator/pivot/trunk/wtk/test/pivot/wtk/test/PushButtonTest.java
    incubator/pivot/trunk/wtk/test/pivot/wtk/test/SliderTest.java
    incubator/pivot/trunk/wtk/test/pivot/wtk/test/form_test.wtkx
    incubator/pivot/trunk/wtk/test/pivot/wtk/text/test/text_area_test.wtkx

Modified: incubator/pivot/trunk/RELEASE-NOTES
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/RELEASE-NOTES?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/RELEASE-NOTES (original)
+++ incubator/pivot/trunk/RELEASE-NOTES Wed May 27 13:41:59 2009
@@ -64,6 +64,9 @@
   that it can be called by the application itself as well as by the system menu
   on Mac OSX (PIVOT-117).
 
+- Add a ByteArraySerializer for serializing arbitrary content, byte per byte
+  (in a buffered way, if possible) (PIVOT-126).
+
 
 Improvements
 ------------
@@ -122,6 +125,8 @@
 - Disable the tab button/accordion header when the corresponding tab/panel is
   disabled (PIVOT-123).
 
+- Add support for comments to JSONSerializer (PIVOT-127).
+
 Bug Fixes
 ---------
 

Modified: incubator/pivot/trunk/build.xml
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/build.xml?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/build.xml (original)
+++ incubator/pivot/trunk/build.xml Wed May 27 13:41:59 2009
@@ -723,22 +723,26 @@
 
     <!-- Remove trailing white space in all source files -->
     <target name="trim-whitespace">
+        <fileset id="trimfiles" dir=".">
+            <include name="BUILD"/>
+            <include name="DISCLAIMER"/>
+            <include name="LICENSE"/>
+            <include name="NOTICE"/>
+            <include name="README"/>
+            <include name="RELEASE-NOTES"/>
+            <include name="**/*.java"/>
+            <include name="**/*.html"/>
+            <include name="**/*.txt"/>
+            <include name="**/*.properties"/>
+            <include name="**/*.xml"/>
+            <include name="**/*.wtkx"/>
+            <include name="**/*.json"/>
+        </fileset>
+        <replaceregexp match="[\t]" replace="    " flags="gm" byline="true">
+            <fileset refid="trimfiles"/>
+        </replaceregexp>
         <replaceregexp match="[\t ]+$" replace="" flags="gm" byline="true">
-            <fileset dir=".">
-                <include name="BUILD"/>
-                <include name="DISCLAIMER"/>
-                <include name="LICENSE"/>
-                <include name="NOTICE"/>
-                <include name="README"/>
-                <include name="RELEASE-NOTES"/>
-                <include name="**/*.java"/>
-                <include name="**/*.html"/>
-                <include name="**/*.txt"/>
-                <include name="**/*.properties"/>
-                <include name="**/*.xml"/>
-                <include name="**/*.wtkx"/>
-                <include name="**/*.json"/>
-            </fileset>
+            <fileset refid="trimfiles"/>
         </replaceregexp>
     </target>
 </project>

Modified: incubator/pivot/trunk/core/src/pivot/beans/BeanDictionary.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/src/pivot/beans/BeanDictionary.java?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/src/pivot/beans/BeanDictionary.java (original)
+++ incubator/pivot/trunk/core/src/pivot/beans/BeanDictionary.java Wed May 27 13:41:59 2009
@@ -146,7 +146,7 @@
      * Returns the bean object this dictionary wraps.
      */
     public Object getBean() {
-    	return bean;
+        return bean;
     }
 
     /**

Modified: incubator/pivot/trunk/core/src/pivot/collections/ArrayList.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/src/pivot/collections/ArrayList.java?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/src/pivot/collections/ArrayList.java (original)
+++ incubator/pivot/trunk/core/src/pivot/collections/ArrayList.java Wed May 27 13:41:59 2009
@@ -203,7 +203,7 @@
 
         if (previousComparator != comparator) {
             if (comparator != null) {
-            	Collections.sort(arrayList, comparator);
+                Collections.sort(arrayList, comparator);
             }
 
             this.comparator = comparator;
@@ -219,7 +219,7 @@
         // when it is created. We can potentially reset the modifier count when all
         // outstanding iterators are finalized.
 
-    	// TODO Alternatively, we could just return an immutable iterator
+        // TODO Alternatively, we could just return an immutable iterator
 
         return arrayList.iterator();
     }

Modified: incubator/pivot/trunk/core/src/pivot/collections/adapter/ListAdapter.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/src/pivot/collections/adapter/ListAdapter.java?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/src/pivot/collections/adapter/ListAdapter.java (original)
+++ incubator/pivot/trunk/core/src/pivot/collections/adapter/ListAdapter.java Wed May 27 13:41:59 2009
@@ -149,7 +149,7 @@
 
         if (previousComparator != comparator) {
             if (comparator != null) {
-            	Collections.sort(list, comparator);
+                Collections.sort(list, comparator);
             }
 
             this.comparator = comparator;

Modified: incubator/pivot/trunk/core/src/pivot/serialization/JSONSerializer.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/src/pivot/serialization/JSONSerializer.java?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/src/pivot/serialization/JSONSerializer.java (original)
+++ incubator/pivot/trunk/core/src/pivot/serialization/JSONSerializer.java Wed May 27 13:41:59 2009
@@ -232,26 +232,26 @@
                 c = reader.read();
 
                 if (c == 't') {
-                	c = '\t';
+                    c = '\t';
                 } else if (c == 'n') {
-                	c = '\n';
+                    c = '\n';
                 } else if (c == 'u') {
-                	StringBuilder unicodeBuilder = new StringBuilder();
-                	while (unicodeBuilder.length() < 4) {
-                		c = reader.read();
-                		unicodeBuilder.append((char)c);
-                	}
+                    StringBuilder unicodeBuilder = new StringBuilder();
+                    while (unicodeBuilder.length() < 4) {
+                        c = reader.read();
+                        unicodeBuilder.append((char)c);
+                    }
 
-                	String unicode = unicodeBuilder.toString();
-                	c = (char)Integer.parseInt(unicode, 16);
+                    String unicode = unicodeBuilder.toString();
+                    c = (char)Integer.parseInt(unicode, 16);
                 } else {
-                	if (!(c == '\\'
-        				|| c == '/'
-                		|| c == '\"'
-            			|| c == '\''
-            			|| c == t)) {
+                    if (!(c == '\\'
+                        || c == '/'
+                        || c == '\"'
+                        || c == '\''
+                        || c == t)) {
                         throw new SerializationException("Unsupported escape sequence in input stream.");
-                	}
+                    }
                 }
             }
 
@@ -481,42 +481,42 @@
         if (object == null) {
             writer.append("null");
         } else if (object instanceof String) {
-        	String string = (String)object;
-        	StringBuilder stringBuilder = new StringBuilder();
+            String string = (String)object;
+            StringBuilder stringBuilder = new StringBuilder();
+
+            for (int i = 0, n = string.length(); i < n; i++) {
+                char c = string.charAt(i);
+
+                switch(c) {
+                    case '\t': {
+                        stringBuilder.append("\\t");
+                        break;
+                    }
+
+                    case '\n': {
+                        stringBuilder.append("\\n");
+                        break;
+                    }
 
-        	for (int i = 0, n = string.length(); i < n; i++) {
-        		char c = string.charAt(i);
+                    case '\\':
+                    case '\"':
+                    case '\'': {
+                        stringBuilder.append("\\" + c);
+                        break;
+                    }
 
-        		switch(c) {
-        			case '\t': {
-        				stringBuilder.append("\\t");
-        				break;
-        			}
-
-        			case '\n': {
-        				stringBuilder.append("\\n");
-        				break;
-        			}
-
-        			case '\\':
-        			case '\"':
-        			case '\'': {
-        				stringBuilder.append("\\" + c);
-        				break;
-        			}
-
-        			default: {
-        				if (charset.name().startsWith("UTF")
-    						|| c <= 0xFF) {
-        					stringBuilder.append(c);
-        				} else {
-        					stringBuilder.append("\\u");
-        					stringBuilder.append(String.format("%04x", (short)c));
-        				}
-        			}
-        		}
+                    default: {
+                        if (charset.name().startsWith("UTF")
+                            || c <= 0xFF) {
+                            stringBuilder.append(c);
+                        } else {
+                            stringBuilder.append("\\u");
+                            stringBuilder.append(String.format("%04x", (short)c));
+                        }
+                    }
+                }
 
-        	}
+            }
 
             writer.append("\"" + stringBuilder.toString() + "\"");
         } else if (object instanceof Number) {

Modified: incubator/pivot/trunk/core/src/pivot/util/concurrent/Dispatcher.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/src/pivot/util/concurrent/Dispatcher.java?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/src/pivot/util/concurrent/Dispatcher.java (original)
+++ incubator/pivot/trunk/core/src/pivot/util/concurrent/Dispatcher.java Wed May 27 13:41:59 2009
@@ -63,6 +63,7 @@
                 // TODO Use the thread pool
                 Thread workerThread = new Thread(runnable,
                     Dispatcher.this.getClass().getName() + "-WorkerThread");
+                workerThread.setPriority(Thread.MIN_PRIORITY);
                 workerThread.start();
             }
         }

Modified: incubator/pivot/trunk/core/test/pivot/core/test/JSONSerializerTest.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/test/pivot/core/test/JSONSerializerTest.java?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/test/pivot/core/test/JSONSerializerTest.java (original)
+++ incubator/pivot/trunk/core/test/pivot/core/test/JSONSerializerTest.java Wed May 27 13:41:59 2009
@@ -28,9 +28,9 @@
 
 public class JSONSerializerTest {
     public static String[] testStrings = {
-    	"'hey\there'",
-    	"'hey\\there'",
-    	"'hey\\\\there'",
+        "'hey\there'",
+        "'hey\\there'",
+        "'hey\\\\there'",
         "  null",
         "\"Hello\\\" World\"",
         "'Hello\\\' \"World'",
@@ -62,7 +62,7 @@
         // test0();
         // test1();
         // test2();
-    	// test3();
+        // test3();
         // test4();
         test5();
     }
@@ -139,26 +139,26 @@
     }
 
     public static void test3() {
-    	JSONSerializer serializer = new JSONSerializer("ISO-8859-1");
-    	InputStream inputStream = JSONSerializerTest.class.getResourceAsStream("json_serializer_test.json");
+        JSONSerializer serializer = new JSONSerializer("ISO-8859-1");
+        InputStream inputStream = JSONSerializerTest.class.getResourceAsStream("json_serializer_test.json");
 
-    	Object root = null;
-    	try {
-    		root = serializer.readObject(inputStream);
-    	} catch(Exception exception) {
-    		System.out.println(exception);
-    	}
-
-    	if (root != null) {
-	    	System.out.println(JSONSerializer.getString(root, "foo"));
-	    	System.out.println(JSONSerializer.getString(root, "bar"));
-    	}
-
-    	try {
-        	serializer.writeObject(root, System.out);
-    	} catch(Exception exception) {
-    		System.out.println(exception);
-    	}
+        Object root = null;
+        try {
+            root = serializer.readObject(inputStream);
+        } catch(Exception exception) {
+            System.out.println(exception);
+        }
+
+        if (root != null) {
+            System.out.println(JSONSerializer.getString(root, "foo"));
+            System.out.println(JSONSerializer.getString(root, "bar"));
+        }
+
+        try {
+            serializer.writeObject(root, System.out);
+        } catch(Exception exception) {
+            System.out.println(exception);
+        }
     }
 
     private static void testList(String list, String path) {

Modified: incubator/pivot/trunk/core/test/pivot/core/test/ResourcesTest.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/test/pivot/core/test/ResourcesTest.java?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/test/pivot/core/test/ResourcesTest.java (original)
+++ incubator/pivot/trunk/core/test/pivot/core/test/ResourcesTest.java Wed May 27 13:41:59 2009
@@ -27,147 +27,147 @@
 
 public class ResourcesTest extends TestCase {
 
-	private Locale old;
+    private Locale old;
 
-	@Override
-	protected void setUp() throws Exception {
+    @Override
+    protected void setUp() throws Exception {
 
-		old = Locale.getDefault();
-		Locale.setDefault(Locale.UK);
+        old = Locale.getDefault();
+        Locale.setDefault(Locale.UK);
 
-		super.setUp();
-	}
-
-	@Override
-	protected void tearDown() throws Exception {
-		Locale.setDefault(old);
-		super.tearDown();
-	};
-
-	public void testReadDefaultLocale() throws Exception {
-
-		Resources res = new Resources("resources.test1");
-		assertResources(res, "SGML", "Standard Generalized Markup Language");
-	}
-
-	/**
-	 * The resource overrides the term for the country.
-	 *
-	 * @throws Exception
-	 */
-	public void testRead_GB_Locale() throws Exception {
-		Resources res = new Resources("resources.test2");
-		assertResources(res, "SGML",
-				"How Do, Youth, Standard Generalized Markup Language");
-
-	}
-
-	/**
-	 * The resource overrides the term for the country and the acronym for the
-	 * language.
-	 *
-	 * @throws Exception
-	 */
-	public void testRead_GB_en_Locale() throws Exception {
-		assertEquals("Default locale should be en_GB", "en_GB", Locale
-				.getDefault().toString());
-		Resources res = new Resources("resources.test3");
-		assertResources(res, "XSGML",
-				"How Do, Youth, Standard Generalized Markup Language");
-
-	}
-
-	/**
-	 * The resource overrides the term and the acronym for the country.
-	 *
-	 * @throws Exception
-	 */
-	public void testRead_GB_en_LocaleExtraOverride() throws Exception {
-		assertEquals("Default locale should be en_GB", "en_GB", Locale
-				.getDefault().toString());
-		Resources res = new Resources("resources.test6");
-		assertResources(res, "XSGML",
-				"eXtra Standard Generalized Markup Language");
-
-	}
-
-	public void testSerialisationException() throws Exception {
-
-		try {
-			new Resources("resources.test4");
-			fail("Expected SerialisationException");
-		} catch (SerializationException e) {
-		}
-
-	}
-
-	public void testMissingResource() throws Exception {
-
-		// resource doesn't exist...
-		try {
-			new Resources("resources.test5");
-			fail("Expected IllegalArgumentException");
-		} catch (MissingResourceException e) {
-		}
-
-	}
-
-	public void testNullLocale() throws Exception {
-		// resource exists, but locale is null
-		try {
-			new Resources("resources.test1", (Locale) null);
-			fail("Expected IllegalArgumentException");
-		} catch (IllegalArgumentException e) {
-
-		}
-	}
-
-	public void testNullBaseName() throws Exception {
-		try {
-			new Resources(null);
-			fail("Expected NullPointerException");
-		} catch (NullPointerException e) {
-		}
-	}
-
-	@SuppressWarnings("unchecked")
-	private static void assertResources(Resources res, String acronym,
-			String term) {
-		assertTrue(res.containsKey("glossary"));
-
-		Map<String, Object> glossary = (Map<String, Object>) res
-				.get("glossary");
-		assertNotNull(glossary);
-		assertTrue(glossary.containsKey("GlossDiv"));
-
-		Map<String, Object> glossDiv = (Map<String, Object>) glossary
-				.get("GlossDiv");
-		assertNotNull(glossDiv);
-
-		assertEquals("S", glossDiv.get("title"));
-
-		assertTrue(glossDiv.containsKey("GlossList"));
-		Map<String, Object> glossList = (Map<String, Object>) glossDiv
-				.get("GlossList");
-		assertNotNull(glossList);
-
-		assertTrue(glossList.containsKey("GlossEntry"));
-		Map<String, Object> glossEntry = (Map<String, Object>) glossList
-				.get("GlossEntry");
-		assertNotNull(glossEntry);
-
-		assertEquals(acronym, glossEntry.get("Acronym"));
-		assertEquals(term, glossEntry.get("GlossTerm"));
-
-		assertTrue(glossEntry.containsKey("GlossDef"));
-		Map<String, Object> glossDef = (Map<String, Object>) glossEntry
-				.get("GlossDef");
-		assertNotNull(glossDef);
-
-		assertTrue(glossDef.containsKey("GlossSeeAlso"));
-		List<String> list = (List<String>) glossDef.get("GlossSeeAlso");
-		assertNotNull(list);
-		assertEquals(2, list.getLength());
-	}
+        super.setUp();
+    }
+
+    @Override
+    protected void tearDown() throws Exception {
+        Locale.setDefault(old);
+        super.tearDown();
+    };
+
+    public void testReadDefaultLocale() throws Exception {
+
+        Resources res = new Resources("resources.test1");
+        assertResources(res, "SGML", "Standard Generalized Markup Language");
+    }
+
+    /**
+     * The resource overrides the term for the country.
+     *
+     * @throws Exception
+     */
+    public void testRead_GB_Locale() throws Exception {
+        Resources res = new Resources("resources.test2");
+        assertResources(res, "SGML",
+                "How Do, Youth, Standard Generalized Markup Language");
+
+    }
+
+    /**
+     * The resource overrides the term for the country and the acronym for the
+     * language.
+     *
+     * @throws Exception
+     */
+    public void testRead_GB_en_Locale() throws Exception {
+        assertEquals("Default locale should be en_GB", "en_GB", Locale
+                .getDefault().toString());
+        Resources res = new Resources("resources.test3");
+        assertResources(res, "XSGML",
+                "How Do, Youth, Standard Generalized Markup Language");
+
+    }
+
+    /**
+     * The resource overrides the term and the acronym for the country.
+     *
+     * @throws Exception
+     */
+    public void testRead_GB_en_LocaleExtraOverride() throws Exception {
+        assertEquals("Default locale should be en_GB", "en_GB", Locale
+                .getDefault().toString());
+        Resources res = new Resources("resources.test6");
+        assertResources(res, "XSGML",
+                "eXtra Standard Generalized Markup Language");
+
+    }
+
+    public void testSerialisationException() throws Exception {
+
+        try {
+            new Resources("resources.test4");
+            fail("Expected SerialisationException");
+        } catch (SerializationException e) {
+        }
+
+    }
+
+    public void testMissingResource() throws Exception {
+
+        // resource doesn't exist...
+        try {
+            new Resources("resources.test5");
+            fail("Expected IllegalArgumentException");
+        } catch (MissingResourceException e) {
+        }
+
+    }
+
+    public void testNullLocale() throws Exception {
+        // resource exists, but locale is null
+        try {
+            new Resources("resources.test1", (Locale) null);
+            fail("Expected IllegalArgumentException");
+        } catch (IllegalArgumentException e) {
+
+        }
+    }
+
+    public void testNullBaseName() throws Exception {
+        try {
+            new Resources(null);
+            fail("Expected NullPointerException");
+        } catch (NullPointerException e) {
+        }
+    }
+
+    @SuppressWarnings("unchecked")
+    private static void assertResources(Resources res, String acronym,
+            String term) {
+        assertTrue(res.containsKey("glossary"));
+
+        Map<String, Object> glossary = (Map<String, Object>) res
+                .get("glossary");
+        assertNotNull(glossary);
+        assertTrue(glossary.containsKey("GlossDiv"));
+
+        Map<String, Object> glossDiv = (Map<String, Object>) glossary
+                .get("GlossDiv");
+        assertNotNull(glossDiv);
+
+        assertEquals("S", glossDiv.get("title"));
+
+        assertTrue(glossDiv.containsKey("GlossList"));
+        Map<String, Object> glossList = (Map<String, Object>) glossDiv
+                .get("GlossList");
+        assertNotNull(glossList);
+
+        assertTrue(glossList.containsKey("GlossEntry"));
+        Map<String, Object> glossEntry = (Map<String, Object>) glossList
+                .get("GlossEntry");
+        assertNotNull(glossEntry);
+
+        assertEquals(acronym, glossEntry.get("Acronym"));
+        assertEquals(term, glossEntry.get("GlossTerm"));
+
+        assertTrue(glossEntry.containsKey("GlossDef"));
+        Map<String, Object> glossDef = (Map<String, Object>) glossEntry
+                .get("GlossDef");
+        assertNotNull(glossDef);
+
+        assertTrue(glossDef.containsKey("GlossSeeAlso"));
+        List<String> list = (List<String>) glossDef.get("GlossSeeAlso");
+        assertNotNull(list);
+        assertEquals(2, list.getLength());
+    }
 
 }

Modified: incubator/pivot/trunk/core/test/resources/test1.json
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/test/resources/test1.json?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/test/resources/test1.json (original)
+++ incubator/pivot/trunk/core/test/resources/test1.json Wed May 27 13:41:59 2009
@@ -2,20 +2,20 @@
 {
     "glossary": {
         "title": "example glossary",
-		"GlossDiv": {
+        "GlossDiv": {
             "title": "S",
-			"GlossList": {
+            "GlossList": {
                 "GlossEntry": {
                     "ID": "SGML",
-					"SortAs": "SGML",
-					"GlossTerm": "Standard Generalized Markup Language",
-					"Acronym": "SGML",
-					"Abbrev": "ISO 8879:1986",
-					"GlossDef": {
+                    "SortAs": "SGML",
+                    "GlossTerm": "Standard Generalized Markup Language",
+                    "Acronym": "SGML",
+                    "Abbrev": "ISO 8879:1986",
+                    "GlossDef": {
                         "para": "A meta-markup language, used to create markup languages such as DocBook.",
-						"GlossSeeAlso": ["GML", "XML"]
+                        "GlossSeeAlso": ["GML", "XML"]
                     },
-					"GlossSee": "markup"
+                    "GlossSee": "markup"
                 }
             }
         }

Modified: incubator/pivot/trunk/core/test/resources/test2.json
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/test/resources/test2.json?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/test/resources/test2.json (original)
+++ incubator/pivot/trunk/core/test/resources/test2.json Wed May 27 13:41:59 2009
@@ -2,20 +2,20 @@
 {
     "glossary": {
         "title": "example glossary",
-		"GlossDiv": {
+        "GlossDiv": {
             "title": "S",
-			"GlossList": {
+            "GlossList": {
                 "GlossEntry": {
                     "ID": "SGML",
-					"SortAs": "SGML",
-					"GlossTerm": "Standard Generalized Markup Language",
-					"Acronym": "SGML",
-					"Abbrev": "ISO 8879:1986",
-					"GlossDef": {
+                    "SortAs": "SGML",
+                    "GlossTerm": "Standard Generalized Markup Language",
+                    "Acronym": "SGML",
+                    "Abbrev": "ISO 8879:1986",
+                    "GlossDef": {
                         "para": "A meta-markup language, used to create markup languages such as DocBook.",
-						"GlossSeeAlso": ["GML", "XML"]
+                        "GlossSeeAlso": ["GML", "XML"]
                     },
-					"GlossSee": "markup"
+                    "GlossSee": "markup"
                 }
             }
         }

Modified: incubator/pivot/trunk/core/test/resources/test2_en.json
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/test/resources/test2_en.json?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/test/resources/test2_en.json (original)
+++ incubator/pivot/trunk/core/test/resources/test2_en.json Wed May 27 13:41:59 2009
@@ -1,10 +1,10 @@
 
 {
     "glossary": {
-		"GlossDiv": {
-			"GlossList": {
+        "GlossDiv": {
+            "GlossList": {
                 "GlossEntry": {
-					"GlossTerm": "How Do, Youth, Standard Generalized Markup Language",
+                    "GlossTerm": "How Do, Youth, Standard Generalized Markup Language",
                 }
             }
         }

Modified: incubator/pivot/trunk/core/test/resources/test3.json
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/test/resources/test3.json?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/test/resources/test3.json (original)
+++ incubator/pivot/trunk/core/test/resources/test3.json Wed May 27 13:41:59 2009
@@ -2,20 +2,20 @@
 {
     "glossary": {
         "title": "example glossary",
-		"GlossDiv": {
+        "GlossDiv": {
             "title": "S",
-			"GlossList": {
+            "GlossList": {
                 "GlossEntry": {
                     "ID": "SGML",
-					"SortAs": "SGML",
-					"GlossTerm": "Standard Generalized Markup Language",
-					"Acronym": "SGML",
-					"Abbrev": "ISO 8879:1986",
-					"GlossDef": {
+                    "SortAs": "SGML",
+                    "GlossTerm": "Standard Generalized Markup Language",
+                    "Acronym": "SGML",
+                    "Abbrev": "ISO 8879:1986",
+                    "GlossDef": {
                         "para": "A meta-markup language, used to create markup languages such as DocBook.",
-						"GlossSeeAlso": ["GML", "XML"]
+                        "GlossSeeAlso": ["GML", "XML"]
                     },
-					"GlossSee": "markup"
+                    "GlossSee": "markup"
                 }
             }
         }

Modified: incubator/pivot/trunk/core/test/resources/test3_en.json
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/test/resources/test3_en.json?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/test/resources/test3_en.json (original)
+++ incubator/pivot/trunk/core/test/resources/test3_en.json Wed May 27 13:41:59 2009
@@ -1,10 +1,10 @@
 
 {
     "glossary": {
-		"GlossDiv": {
-			"GlossList": {
+        "GlossDiv": {
+            "GlossList": {
                 "GlossEntry": {
-					"GlossTerm": "How Do, Youth, Standard Generalized Markup Language",
+                    "GlossTerm": "How Do, Youth, Standard Generalized Markup Language",
                 }
             }
         }

Modified: incubator/pivot/trunk/core/test/resources/test3_en_GB.json
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/test/resources/test3_en_GB.json?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/test/resources/test3_en_GB.json (original)
+++ incubator/pivot/trunk/core/test/resources/test3_en_GB.json Wed May 27 13:41:59 2009
@@ -1,10 +1,10 @@
 
 {
     "glossary": {
-		"GlossDiv": {
-			"GlossList": {
+        "GlossDiv": {
+            "GlossList": {
                 "GlossEntry": {
-					"Acronym": "XSGML"
+                    "Acronym": "XSGML"
                 }
             }
         }

Modified: incubator/pivot/trunk/core/test/resources/test4.json
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/test/resources/test4.json?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/test/resources/test4.json (original)
+++ incubator/pivot/trunk/core/test/resources/test4.json Wed May 27 13:41:59 2009
@@ -2,20 +2,20 @@
 {
     "glossary"x: {
         "title": "example glossary",
-		"GlossDiv": {
+        "GlossDiv": {
             "title": "S",
-			"GlossList": {
+            "GlossList": {
                 "GlossEntry": {
                     "ID": "SGML",
-					"SortAs": "SGML",
-					"GlossTerm": "Standard Generalized Markup Language",
-					"Acronym": "SGML",
-					"Abbrev": "ISO 8879:1986",
-					"GlossDef": {
+                    "SortAs": "SGML",
+                    "GlossTerm": "Standard Generalized Markup Language",
+                    "Acronym": "SGML",
+                    "Abbrev": "ISO 8879:1986",
+                    "GlossDef": {
                         "para": "A meta-markup language, used to create markup languages such as DocBook.",
-						"GlossSeeAlso": ["GML", "XML"]
+                        "GlossSeeAlso": ["GML", "XML"]
                     },
-					"GlossSee": "markup"
+                    "GlossSee": "markup"
                 }
             }
         }

Modified: incubator/pivot/trunk/core/test/resources/test6.json
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/test/resources/test6.json?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/test/resources/test6.json (original)
+++ incubator/pivot/trunk/core/test/resources/test6.json Wed May 27 13:41:59 2009
@@ -2,20 +2,20 @@
 {
     "glossary": {
         "title": "example glossary",
-		"GlossDiv": {
+        "GlossDiv": {
             "title": "S",
-			"GlossList": {
+            "GlossList": {
                 "GlossEntry": {
                     "ID": "SGML",
-					"SortAs": "SGML",
-					"GlossTerm": "Standard Generalized Markup Language",
-					"Acronym": "SGML",
-					"Abbrev": "ISO 8879:1986",
-					"GlossDef": {
+                    "SortAs": "SGML",
+                    "GlossTerm": "Standard Generalized Markup Language",
+                    "Acronym": "SGML",
+                    "Abbrev": "ISO 8879:1986",
+                    "GlossDef": {
                         "para": "A meta-markup language, used to create markup languages such as DocBook.",
-						"GlossSeeAlso": ["GML", "XML"]
+                        "GlossSeeAlso": ["GML", "XML"]
                     },
-					"GlossSee": "markup"
+                    "GlossSee": "markup"
                 }
             }
         }

Modified: incubator/pivot/trunk/core/test/resources/test6_en.json
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/test/resources/test6_en.json?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/test/resources/test6_en.json (original)
+++ incubator/pivot/trunk/core/test/resources/test6_en.json Wed May 27 13:41:59 2009
@@ -1,10 +1,10 @@
 
 {
     "glossary": {
-		"GlossDiv": {
-			"GlossList": {
+        "GlossDiv": {
+            "GlossList": {
                 "GlossEntry": {
-					"GlossTerm": "How Do, Youth, Standard Generalized Markup Language",
+                    "GlossTerm": "How Do, Youth, Standard Generalized Markup Language",
                 }
             }
         }

Modified: incubator/pivot/trunk/core/test/resources/test6_en_GB.json
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/core/test/resources/test6_en_GB.json?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/core/test/resources/test6_en_GB.json (original)
+++ incubator/pivot/trunk/core/test/resources/test6_en_GB.json Wed May 27 13:41:59 2009
@@ -1,11 +1,11 @@
 
 {
     "glossary": {
-		"GlossDiv": {
-			"GlossList": {
+        "GlossDiv": {
+            "GlossList": {
                 "GlossEntry": {
-					"Acronym": "XSGML",
-					"GlossTerm": "eXtra Standard Generalized Markup Language"
+                    "Acronym": "XSGML",
+                    "GlossTerm": "eXtra Standard Generalized Markup Language"
                 }
             }
         }

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/Demo.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/Demo.java?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/Demo.java (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/Demo.java Wed May 27 13:41:59 2009
@@ -724,7 +724,10 @@
     }
 
     public boolean shutdown(boolean optional) throws Exception {
-        window.close();
+        if (window != null) {
+            window.close();
+        }
+
         return true;
     }
 

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/Address.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/Address.java?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/Address.java (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/Address.java Wed May 27 13:41:59 2009
@@ -17,35 +17,35 @@
 package pivot.tutorials.databinding;
 
 public class Address {
-	private String street;
-	private String city;
-	private String state;
-	private String zip;
-
-	public Address() {
-		this(null, null, null, null);
-	}
-
-	public Address(String street, String city, String state, String zip) {
-		this.street = street;
-		this.city = city;
-		this.state = state;
-		this.zip = zip;
-	}
-
-	public String getStreet() {
-		return street;
-	}
-
-	public String getCity() {
-		return city;
-	}
-
-	public String getState() {
-		return state;
-	}
-
-	public String getZip() {
-		return zip;
-	}
+    private String street;
+    private String city;
+    private String state;
+    private String zip;
+
+    public Address() {
+        this(null, null, null, null);
+    }
+
+    public Address(String street, String city, String state, String zip) {
+        this.street = street;
+        this.city = city;
+        this.state = state;
+        this.zip = zip;
+    }
+
+    public String getStreet() {
+        return street;
+    }
+
+    public String getCity() {
+        return city;
+    }
+
+    public String getState() {
+        return state;
+    }
+
+    public String getZip() {
+        return zip;
+    }
 }

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/Contact.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/Contact.java?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/Contact.java (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/Contact.java Wed May 27 13:41:59 2009
@@ -17,56 +17,56 @@
 package pivot.tutorials.databinding;
 
 public class Contact {
-	private String id;
-	private String name;
-	private Address address;
-	private String phoneNumber;
-	private String emailAddress;
-	private IMAccount imAccount;
-
-	public Contact() {
-		this(null, null, new Address(), null, null, new IMAccount());
-	}
-
-	public Contact(String id, String name, Address address, String phoneNumber,
-		String emailAddress, IMAccount imAccount) {
-		this.id = id;
-		this.name = name;
-		this.address = address;
-		this.phoneNumber = phoneNumber;
-		this.emailAddress = emailAddress;
-		this.imAccount = imAccount;
-	}
-
-	public String getID() {
-		return id;
-	}
-
-	public String getId() {
-		return getID();
-	}
-
-	public String getName() {
-		return name;
-	}
-
-	public Address getAddress() {
-		return address;
-	}
-
-	public String getPhoneNumber() {
-		return phoneNumber;
-	}
-
-	public String getEmailAddress() {
-		return emailAddress;
-	}
-
-	public IMAccount getIMAccount() {
-		return imAccount;
-	}
-
-	public IMAccount getImAccount() {
-		return getIMAccount();
-	}
+    private String id;
+    private String name;
+    private Address address;
+    private String phoneNumber;
+    private String emailAddress;
+    private IMAccount imAccount;
+
+    public Contact() {
+        this(null, null, new Address(), null, null, new IMAccount());
+    }
+
+    public Contact(String id, String name, Address address, String phoneNumber,
+        String emailAddress, IMAccount imAccount) {
+        this.id = id;
+        this.name = name;
+        this.address = address;
+        this.phoneNumber = phoneNumber;
+        this.emailAddress = emailAddress;
+        this.imAccount = imAccount;
+    }
+
+    public String getID() {
+        return id;
+    }
+
+    public String getId() {
+        return getID();
+    }
+
+    public String getName() {
+        return name;
+    }
+
+    public Address getAddress() {
+        return address;
+    }
+
+    public String getPhoneNumber() {
+        return phoneNumber;
+    }
+
+    public String getEmailAddress() {
+        return emailAddress;
+    }
+
+    public IMAccount getIMAccount() {
+        return imAccount;
+    }
+
+    public IMAccount getImAccount() {
+        return getIMAccount();
+    }
 }

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/DataBinding.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/DataBinding.java?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/DataBinding.java (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/DataBinding.java Wed May 27 13:41:59 2009
@@ -33,70 +33,70 @@
 import pivot.wtkx.Bindable;
 
 public class DataBinding extends Bindable implements Application {
-	@Load(resourceName="data_binding.wtkx") private Window window;
-	@Bind(fieldName="window") private Form form;
-	@Bind(fieldName="window") private PushButton loadJavaButton;
-	@Bind(fieldName="window") private PushButton loadJSONButton;
-	@Bind(fieldName="window") private PushButton clearButton;
-	@Bind(fieldName="window") private Label sourceLabel;
-
-	private static final Contact CONTACT = new Contact("101", "Joe Smith",
-		new Address("123 Main St.", "Cambridge", "MA", "02142"),
-		"(617) 555-1234", "joe_smith@foo.com",
-		new IMAccount("jsmith1234", "AIM"));
-
-	public void startup(Display display, Dictionary<String, String> properties)
-		throws Exception {
-	    bind();
+    @Load(resourceName="data_binding.wtkx") private Window window;
+    @Bind(fieldName="window") private Form form;
+    @Bind(fieldName="window") private PushButton loadJavaButton;
+    @Bind(fieldName="window") private PushButton loadJSONButton;
+    @Bind(fieldName="window") private PushButton clearButton;
+    @Bind(fieldName="window") private Label sourceLabel;
+
+    private static final Contact CONTACT = new Contact("101", "Joe Smith",
+        new Address("123 Main St.", "Cambridge", "MA", "02142"),
+        "(617) 555-1234", "joe_smith@foo.com",
+        new IMAccount("jsmith1234", "AIM"));
+
+    public void startup(Display display, Dictionary<String, String> properties)
+        throws Exception {
+        bind();
 
         loadJavaButton.getButtonPressListeners().add(new ButtonPressListener() {
-        	public void buttonPressed(Button button) {
-        		form.load(CONTACT);
-        		sourceLabel.setText("Java");
-        	}
+            public void buttonPressed(Button button) {
+                form.load(CONTACT);
+                sourceLabel.setText("Java");
+            }
         });
 
         loadJSONButton.getButtonPressListeners().add(new ButtonPressListener() {
-        	@SuppressWarnings("unchecked")
-        	public void buttonPressed(Button button) {
-        		JSONSerializer serializer = new JSONSerializer();
-        		InputStream inputStream = getClass().getResourceAsStream("contact.json");
-
-        		try {
-            		form.load((Map<String, Object>)serializer.readObject(inputStream));
-            		sourceLabel.setText("JSON");
-        		} catch(Exception exception) {
-        			System.out.println(exception);
-        		}
+            @SuppressWarnings("unchecked")
+            public void buttonPressed(Button button) {
+                JSONSerializer serializer = new JSONSerializer();
+                InputStream inputStream = getClass().getResourceAsStream("contact.json");
+
+                try {
+                    form.load((Map<String, Object>)serializer.readObject(inputStream));
+                    sourceLabel.setText("JSON");
+                } catch(Exception exception) {
+                    System.out.println(exception);
+                }
 
-        		button.setEnabled(true);
-        	}
+                button.setEnabled(true);
+            }
         });
 
         clearButton.getButtonPressListeners().add(new ButtonPressListener() {
-        	public void buttonPressed(Button button) {
-        		form.load(new Contact());
-        		sourceLabel.setText(null);
-        	}
+            public void buttonPressed(Button button) {
+                form.load(new Contact());
+                sourceLabel.setText(null);
+            }
         });
 
         window.open(display);
-	}
+    }
 
-	public boolean shutdown(boolean optional) {
-	    if (window != null) {
-	        window.close();
-	    }
+    public boolean shutdown(boolean optional) {
+        if (window != null) {
+            window.close();
+        }
 
-		return false;
-	}
+        return false;
+    }
 
 
-	public void suspend() {
-	}
+    public void suspend() {
+    }
 
-	public void resume() {
-	}
+    public void resume() {
+    }
 
     public static void main(String[] args) {
         DesktopApplicationContext.main(DataBinding.class, args);

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/IMAccount.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/IMAccount.java?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/IMAccount.java (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/databinding/IMAccount.java Wed May 27 13:41:59 2009
@@ -17,27 +17,27 @@
 package pivot.tutorials.databinding;
 
 public class IMAccount {
-	private String id;
-	private String type;
+    private String id;
+    private String type;
 
-	public IMAccount() {
-		this(null, null);
-	}
-
-	public IMAccount(String id, String type) {
-		this.id = id;
-		this.type = type;
-	}
-
-	public String getID() {
-		return id;
-	}
-
-	public String getId() {
-		return getID();
-	}
-
-	public String getType() {
-		return type;
-	}
+    public IMAccount() {
+        this(null, null);
+    }
+
+    public IMAccount(String id, String type) {
+        this.id = id;
+        this.type = type;
+    }
+
+    public String getID() {
+        return id;
+    }
+
+    public String getId() {
+        return getID();
+    }
+
+    public String getType() {
+        return type;
+    }
 }

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/lists.wtkx
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/lists.wtkx?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/lists.wtkx (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/lists.wtkx Wed May 27 13:41:59 2009
@@ -120,65 +120,65 @@
                 <Form>
                     <sections>
                         <Form.Section>
-	                        <ListButton Form.name="Basic" selectedIndex="0">
-	                            <listData>
-	                                <collections:ArrayList>
+                            <ListButton Form.name="Basic" selectedIndex="0">
+                                <listData>
+                                    <collections:ArrayList>
                                         <content:ListItem text="Red"/>
                                         <content:ListItem text="Orange"/>
                                         <content:ListItem text="Yellow"/>
                                         <content:ListItem text="Green"/>
                                         <content:ListItem text="Blue"/>
                                         <content:ListItem text="Purple"/>
-	                                </collections:ArrayList>
-	                            </listData>
-	                        </ListButton>
+                                    </collections:ArrayList>
+                                </listData>
+                            </ListButton>
 
-	                        <ListButton Form.name="Image" selectedIndex="2">
-	                            <listData>
-	                                <collections:ArrayList>
+                            <ListButton Form.name="Image" selectedIndex="2">
+                                <listData>
+                                    <collections:ArrayList>
                                         <content:ListItem icon="@anchor.png" text="Anchor"/>
                                         <content:ListItem icon="@bell.png" text="Bell"/>
                                         <content:ListItem icon="@clock.png" text="Clock"/>
                                         <content:ListItem icon="@cup.png" text="Cup"/>
                                         <content:ListItem icon="@house.png" text="House"/>
                                         <content:ListItem icon="@star.png" text="Star"/>
-	                                </collections:ArrayList>
-	                            </listData>
-	                            <itemRenderer>
-	                                <content:ListViewItemRenderer iconWidth="16" iconHeight="16"
-	                                    showIcon="true"/>
-	                            </itemRenderer>
-	                        </ListButton>
+                                    </collections:ArrayList>
+                                </listData>
+                                <itemRenderer>
+                                    <content:ListViewItemRenderer iconWidth="16" iconHeight="16"
+                                        showIcon="true"/>
+                                </itemRenderer>
+                            </ListButton>
 
-						    <ListButton Form.name="Color" selectedIndex="0"
-						        styles="{listSize:6}">
-						        <listData>
-						            <collections:ArrayList>
-						                <content:ColorItem color="#000000" name="Black"/>
-						                <content:ColorItem color="#0000AA" name="Blue"/>
-						                <content:ColorItem color="#00AA00" name="Green"/>
-						                <content:ColorItem color="#00AAAA" name="Cyan"/>
-						                <content:ColorItem color="#AA0000" name="Red"/>
-						                <content:ColorItem color="#AA00AA" name="Magenta"/>
-						                <content:ColorItem color="#AA5500" name="Brown"/>
-						                <content:ColorItem color="#AAAAAA" name="Light Gray"/>
-						                <content:ColorItem color="#555555" name="Dark Gray"/>
-						                <content:ColorItem color="#5555FF" name="Bright Blue"/>
-						                <content:ColorItem color="#55FF55" name="Bright Green"/>
-						                <content:ColorItem color="#55FFFF" name="Bright Cyan"/>
-						                <content:ColorItem color="#FF5555" name="Bright Red"/>
-						                <content:ColorItem color="#FF55FF" name="Bright Magenta"/>
-						                <content:ColorItem color="#FFFF55" name="Bright Yellow"/>
-						                <content:ColorItem color="#FFFFFF" name="White"/>
-						            </collections:ArrayList>
-						        </listData>
-						        <dataRenderer>
-						            <content:ListButtonColorRenderer/>
-						        </dataRenderer>
-						        <itemRenderer>
-						            <content:ListViewColorRenderer/>
-						        </itemRenderer>
-						    </ListButton>
+                            <ListButton Form.name="Color" selectedIndex="0"
+                                styles="{listSize:6}">
+                                <listData>
+                                    <collections:ArrayList>
+                                        <content:ColorItem color="#000000" name="Black"/>
+                                        <content:ColorItem color="#0000AA" name="Blue"/>
+                                        <content:ColorItem color="#00AA00" name="Green"/>
+                                        <content:ColorItem color="#00AAAA" name="Cyan"/>
+                                        <content:ColorItem color="#AA0000" name="Red"/>
+                                        <content:ColorItem color="#AA00AA" name="Magenta"/>
+                                        <content:ColorItem color="#AA5500" name="Brown"/>
+                                        <content:ColorItem color="#AAAAAA" name="Light Gray"/>
+                                        <content:ColorItem color="#555555" name="Dark Gray"/>
+                                        <content:ColorItem color="#5555FF" name="Bright Blue"/>
+                                        <content:ColorItem color="#55FF55" name="Bright Green"/>
+                                        <content:ColorItem color="#55FFFF" name="Bright Cyan"/>
+                                        <content:ColorItem color="#FF5555" name="Bright Red"/>
+                                        <content:ColorItem color="#FF55FF" name="Bright Magenta"/>
+                                        <content:ColorItem color="#FFFF55" name="Bright Yellow"/>
+                                        <content:ColorItem color="#FFFFFF" name="White"/>
+                                    </collections:ArrayList>
+                                </listData>
+                                <dataRenderer>
+                                    <content:ListButtonColorRenderer/>
+                                </dataRenderer>
+                                <itemRenderer>
+                                    <content:ListViewColorRenderer/>
+                                </itemRenderer>
+                            </ListButton>
                         </Form.Section>
                     </sections>
                 </Form>

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/menu_buttons.wtkx
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/menu_buttons.wtkx?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/menu_buttons.wtkx (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/menu_buttons.wtkx Wed May 27 13:41:59 2009
@@ -18,159 +18,159 @@
 
 <Border xmlns:wtkx="http://incubator.apache.org/pivot/wtkx/1.1"
     xmlns:content="pivot.wtk.content" xmlns="pivot.wtk">
-	<content>
-		<FlowPane orientation="vertical"
-			styles="{padding:{top:2, left:4, bottom:4, right:4}, spacing:10}">
-			<FlowPane orientation="vertical">
-				<Label text="Menu Buttons" styles="{fontBold:true}" />
-				<FlowPane orientation="vertical">
-			        <MenuButton buttonData="File">
-			            <menu>
-			                <Menu>
-			                    <sections>
-			                        <Menu.Section>
-			                            <Menu.Item>
-			                                 <buttonData>
-			                                     <content:ButtonData text="New" icon="@document-new.png"/>
-		                                     </buttonData>
-			                            </Menu.Item>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:ButtonData text="Open" icon="@document-open.png"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                        </Menu.Section>
-			                        <Menu.Section>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:ButtonData text="Close"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:ButtonData text="Close All"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                        </Menu.Section>
-			                        <Menu.Section>
-			                            <Menu.Item enabled="false">
-			                                <buttonData>
-			                                    <content:ButtonData text="Save" icon="@document-save.png"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:ButtonData text="Save As" icon="@document-save-as.png"/>
-			                                </buttonData>
-			                                <menu>
-			                                    <Menu>
-			                                        <sections>
-			                                            <Menu.Section>
-			                                                <Menu.Item buttonData="JPEG"/>
-			                                                <Menu.Item buttonData="PNG"/>
-			                                                <Menu.Item buttonData="GIF"/>
-			                                                <Menu.Item buttonData="PDF"/>
-			                                            </Menu.Section>
-			                                        </sections>
-			                                    </Menu>
-			                                </menu>
-			                            </Menu.Item>
-			                        </Menu.Section>
-			                    </sections>
-			                </Menu>
-			            </menu>
-			        </MenuButton>
+    <content>
+        <FlowPane orientation="vertical"
+            styles="{padding:{top:2, left:4, bottom:4, right:4}, spacing:10}">
+            <FlowPane orientation="vertical">
+                <Label text="Menu Buttons" styles="{fontBold:true}" />
+                <FlowPane orientation="vertical">
+                    <MenuButton buttonData="File">
+                        <menu>
+                            <Menu>
+                                <sections>
+                                    <Menu.Section>
+                                        <Menu.Item>
+                                             <buttonData>
+                                                 <content:ButtonData text="New" icon="@document-new.png"/>
+                                             </buttonData>
+                                        </Menu.Item>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:ButtonData text="Open" icon="@document-open.png"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                    </Menu.Section>
+                                    <Menu.Section>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:ButtonData text="Close"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:ButtonData text="Close All"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                    </Menu.Section>
+                                    <Menu.Section>
+                                        <Menu.Item enabled="false">
+                                            <buttonData>
+                                                <content:ButtonData text="Save" icon="@document-save.png"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:ButtonData text="Save As" icon="@document-save-as.png"/>
+                                            </buttonData>
+                                            <menu>
+                                                <Menu>
+                                                    <sections>
+                                                        <Menu.Section>
+                                                            <Menu.Item buttonData="JPEG"/>
+                                                            <Menu.Item buttonData="PNG"/>
+                                                            <Menu.Item buttonData="GIF"/>
+                                                            <Menu.Item buttonData="PDF"/>
+                                                        </Menu.Section>
+                                                    </sections>
+                                                </Menu>
+                                            </menu>
+                                        </Menu.Item>
+                                    </Menu.Section>
+                                </sections>
+                            </Menu>
+                        </menu>
+                    </MenuButton>
 
-			        <MenuButton styles="{spacing:2}">
-			            <buttonData>
-			                <content:ButtonData text="Edit" icon="@page_edit.png"/>
-			            </buttonData>
-			            <menu>
-			                <Menu>
-			                    <sections>
-			                        <Menu.Section>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:MenuItemData text="Undo" icon="@edit-undo.png"
-			                                        keyboardShortcut="CTRL-Z"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:MenuItemData text="Redo" icon="@edit-redo.png"
-			                                        keyboardShortcut="SHIFT-CTRL-Z"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                        </Menu.Section>
-			                        <Menu.Section>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:MenuItemData text="Cut" icon="@edit-cut.png"
-			                                        keyboardShortcut="CTRL-X"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:MenuItemData text="Copy" icon="@edit-copy.png"
-			                                        keyboardShortcut="CTRL-C"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:MenuItemData text="Paste" icon="@edit-paste.png"
-			                                        keyboardShortcut="CTRL-V"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                        </Menu.Section>
-			                        <Menu.Section>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:MenuItemData text="Delete" icon="@edit-delete.png"
-			                                        keyboardShortcut="DELETE"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:MenuItemData text="Select All" icon="@edit-select-all.png"
-			                                        keyboardShortcut="CTRL-A"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                        </Menu.Section>
-			                    </sections>
-			                </Menu>
-			            </menu>
-			        </MenuButton>
+                    <MenuButton styles="{spacing:2}">
+                        <buttonData>
+                            <content:ButtonData text="Edit" icon="@page_edit.png"/>
+                        </buttonData>
+                        <menu>
+                            <Menu>
+                                <sections>
+                                    <Menu.Section>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:MenuItemData text="Undo" icon="@edit-undo.png"
+                                                    keyboardShortcut="CTRL-Z"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:MenuItemData text="Redo" icon="@edit-redo.png"
+                                                    keyboardShortcut="SHIFT-CTRL-Z"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                    </Menu.Section>
+                                    <Menu.Section>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:MenuItemData text="Cut" icon="@edit-cut.png"
+                                                    keyboardShortcut="CTRL-X"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:MenuItemData text="Copy" icon="@edit-copy.png"
+                                                    keyboardShortcut="CTRL-C"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:MenuItemData text="Paste" icon="@edit-paste.png"
+                                                    keyboardShortcut="CTRL-V"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                    </Menu.Section>
+                                    <Menu.Section>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:MenuItemData text="Delete" icon="@edit-delete.png"
+                                                    keyboardShortcut="DELETE"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:MenuItemData text="Select All" icon="@edit-select-all.png"
+                                                    keyboardShortcut="CTRL-A"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                    </Menu.Section>
+                                </sections>
+                            </Menu>
+                        </menu>
+                    </MenuButton>
 
-			        <MenuButton tooltipText="Help" styles="{spacing:2, toolbar:true}">
-			            <buttonData>
-			                <content:ButtonData icon="@help.png"/>
-			            </buttonData>
-			            <menu>
-			                <Menu>
-			                    <sections>
-			                        <Menu.Section>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:ButtonData text="Contents" icon="@book_open.png"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:ButtonData text="Search" icon="@magnifier.png"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                            <Menu.Item>
-			                                <buttonData>
-			                                    <content:ButtonData text="About" icon="@application.png"/>
-			                                </buttonData>
-			                            </Menu.Item>
-			                        </Menu.Section>
-			                    </sections>
-			                </Menu>
-			            </menu>
-			        </MenuButton>
-				</FlowPane>
-			</FlowPane>
-		</FlowPane>
-	</content>
+                    <MenuButton tooltipText="Help" styles="{spacing:2, toolbar:true}">
+                        <buttonData>
+                            <content:ButtonData icon="@help.png"/>
+                        </buttonData>
+                        <menu>
+                            <Menu>
+                                <sections>
+                                    <Menu.Section>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:ButtonData text="Contents" icon="@book_open.png"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:ButtonData text="Search" icon="@magnifier.png"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                        <Menu.Item>
+                                            <buttonData>
+                                                <content:ButtonData text="About" icon="@application.png"/>
+                                            </buttonData>
+                                        </Menu.Item>
+                                    </Menu.Section>
+                                </sections>
+                            </Menu>
+                        </menu>
+                    </MenuButton>
+                </FlowPane>
+            </FlowPane>
+        </FlowPane>
+    </content>
 </Border>

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/menu_popup.wtkx
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/menu_popup.wtkx?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/menu_popup.wtkx (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/menu_popup.wtkx Wed May 27 13:41:59 2009
@@ -18,23 +18,23 @@
 
 <MenuPopup xmlns:wtkx="http://incubator.apache.org/pivot/wtkx/1.1" xmlns="pivot.wtk">
     <menu>
-		<Menu>
-		    <sections>
-		        <Menu.Section>
-		            <Menu.Item buttonData="IMG_0725_2.jpg" toggleButton="true"
-		                group="imageMenuGroup" action="selectImageAction">
+        <Menu>
+            <sections>
+                <Menu.Section>
+                    <Menu.Item buttonData="IMG_0725_2.jpg" toggleButton="true"
+                        group="imageMenuGroup" action="selectImageAction">
                         <userData image="pivot/tutorials/IMG_0725_2.jpg"/>
-		            </Menu.Item>
-		            <Menu.Item buttonData="IMG_0735_2.jpg" toggleButton="true"
-		                group="imageMenuGroup" action="selectImageAction">
+                    </Menu.Item>
+                    <Menu.Item buttonData="IMG_0735_2.jpg" toggleButton="true"
+                        group="imageMenuGroup" action="selectImageAction">
                         <userData image="pivot/tutorials/IMG_0735_2.jpg"/>
                     </Menu.Item>
-		            <Menu.Item buttonData="IMG_0767_2.jpg" toggleButton="true"
-		                group="imageMenuGroup" action="selectImageAction">
+                    <Menu.Item buttonData="IMG_0767_2.jpg" toggleButton="true"
+                        group="imageMenuGroup" action="selectImageAction">
                         <userData image="pivot/tutorials/IMG_0767_2.jpg"/>
                     </Menu.Item>
-		        </Menu.Section>
-		    </sections>
-		</Menu>
-	</menu>
+                </Menu.Section>
+            </sections>
+        </Menu>
+    </menu>
 </MenuPopup>

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/meters.wtkx
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/meters.wtkx?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/meters.wtkx (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/meters.wtkx Wed May 27 13:41:59 2009
@@ -46,12 +46,12 @@
             <FlowPane orientation="vertical" styles="{padding:6, spacing:8}">
                 <Label text="Activity Indicators" styles="{fontBold:true}"/>
                 <FlowPane>
-	                <ActivityIndicator wtkx:id="activityIndicator1"
-	                    preferredWidth="24" preferredHeight="24"/>
-	                <ActivityIndicator wtkx:id="activityIndicator2" styles="{color:'#aa0000'}"
-	                    preferredWidth="48" preferredHeight="48"/>
-					<ActivityIndicator wtkx:id="activityIndicator3" styles="{color:16}"
-					    preferredWidth="96" preferredHeight="96"/>
+                    <ActivityIndicator wtkx:id="activityIndicator1"
+                        preferredWidth="24" preferredHeight="24"/>
+                    <ActivityIndicator wtkx:id="activityIndicator2" styles="{color:'#aa0000'}"
+                        preferredWidth="48" preferredHeight="48"/>
+                    <ActivityIndicator wtkx:id="activityIndicator3" styles="{color:16}"
+                        preferredWidth="96" preferredHeight="96"/>
                 </FlowPane>
             </FlowPane>
         </FlowPane>

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/spinners.wtkx
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/spinners.wtkx?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/spinners.wtkx (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/spinners.wtkx Wed May 27 13:41:59 2009
@@ -22,18 +22,18 @@
         <content>
             <FlowPane orientation="vertical" styles="{padding:{top:2, left:4, bottom:8, right:4}}">
                 <Label text="Spinners" styles="{fontBold:true}"/>
-	            <Form>
-	                <sections>
-	                    <Form.Section>
-	                        <Spinner Form.name="Basic" preferredWidth="60"
-	                            spinnerData="['One', 'Two', 'Three', 'Four', 'Five']"
-	                            circular="true" selectedIndex="0"/>
+                <Form>
+                    <sections>
+                        <Form.Section>
+                            <Spinner Form.name="Basic" preferredWidth="60"
+                                spinnerData="['One', 'Two', 'Three', 'Four', 'Five']"
+                                circular="true" selectedIndex="0"/>
                             <Spinner wtkx:id="numericSpinner" Form.name="Numeric"
                                 preferredWidth="60"/>
                             <Spinner wtkx:id="dateSpinner" Form.name="Date"/>
-	                    </Form.Section>
-	                </sections>
-	            </Form>
+                        </Form.Section>
+                    </sections>
+                </Form>
             </FlowPane>
         </content>
     </Border>

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/StockTracker.json
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/StockTracker.json?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/StockTracker.json (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/StockTracker.json Wed May 27 13:41:59 2009
@@ -14,18 +14,18 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-{	stockTracker: "Pivot Stock Tracker",
-	symbol: "Symbol",
-	companyName: "Company",
-	value: "Value",
-	openingValue: "Open",
-	highValue: "High",
-	lowValue: "Low",
-	change: "Change",
-	volume: "Volume",
-	addSymbol: "Add symbol",
-	removeSymbol: "Remove selected symbols",
-	lastUpdate: "Last Update",
-	dataProvidedBy: "Data provided by",
-	yahooFinance: "Yahoo! Finance"
+{    stockTracker: "Pivot Stock Tracker",
+    symbol: "Symbol",
+    companyName: "Company",
+    value: "Value",
+    openingValue: "Open",
+    highValue: "High",
+    lowValue: "Low",
+    change: "Change",
+    volume: "Volume",
+    addSymbol: "Add symbol",
+    removeSymbol: "Remove selected symbols",
+    lastUpdate: "Last Update",
+    dataProvidedBy: "Data provided by",
+    yahooFinance: "Yahoo! Finance"
 }

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/StockTracker_fr.json
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/StockTracker_fr.json?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/StockTracker_fr.json (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/StockTracker_fr.json Wed May 27 13:41:59 2009
@@ -14,18 +14,18 @@
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
-{	stockTracker: "La Bourse Pivot",
-	symbol: "Code",
-	companyName: "Société",
-	value: "Cours",
-	openingValue: "Ouverture",
-	highValue: "+ Haut",
-	lowValue: "+ Bas",
-	change: "Variation",
-	volume: "Volume",
-	addSymbol: "Ajouter un code",
-	removeSymbol: "Enlever codes sélectionnés",
-	lastUpdate: "Dernier échange",
-	dataProvidedBy: "Données fournies par",
-	yahooFinance: "Yahoo! Finance"
+{    stockTracker: "La Bourse Pivot",
+    symbol: "Code",
+    companyName: "Société",
+    value: "Cours",
+    openingValue: "Ouverture",
+    highValue: "+ Haut",
+    lowValue: "+ Bas",
+    change: "Variation",
+    volume: "Volume",
+    addSymbol: "Ajouter un code",
+    removeSymbol: "Enlever codes sélectionnés",
+    lastUpdate: "Dernier échange",
+    dataProvidedBy: "Données fournies par",
+    yahooFinance: "Yahoo! Finance"
 }

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/stocktracker.detail.wtkx
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/stocktracker.detail.wtkx?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/stocktracker.detail.wtkx (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/stocktracker.detail.wtkx Wed May 27 13:41:59 2009
@@ -24,12 +24,12 @@
     <Form styles="{rightAlignLabels:true, fieldAlignment:'right'}">
         <sections>
             <Form.Section>
-	            <Label Form.name="%value" textKey="value" />
-	            <Label wtkx:id="changeLabel" Form.name="%change" textKey="change" />
-	            <Label Form.name="%openingValue" textKey="openingValue" />
-	            <Label Form.name="%highValue" textKey="highValue" />
-	            <Label Form.name="%lowValue" textKey="lowValue" />
-	            <Label Form.name="%volume" textKey="volume" />
+                <Label Form.name="%value" textKey="value" />
+                <Label wtkx:id="changeLabel" Form.name="%change" textKey="change" />
+                <Label Form.name="%openingValue" textKey="openingValue" />
+                <Label Form.name="%highValue" textKey="highValue" />
+                <Label Form.name="%lowValue" textKey="lowValue" />
+                <Label Form.name="%volume" textKey="volume" />
             </Form.Section>
         </sections>
     </Form>

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/stocktracker.wtkx
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/stocktracker.wtkx?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/stocktracker.wtkx (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/stocktracker/stocktracker.wtkx Wed May 27 13:41:59 2009
@@ -98,8 +98,8 @@
 
                 <TablePane.Row height="-1">
                     <FlowPane>
-	                    <Label text="%lastUpdate"/>
-	                    <Label wtkx:id="lastUpdateLabel"/>
+                        <Label text="%lastUpdate"/>
+                        <Label wtkx:id="lastUpdateLabel"/>
                     </FlowPane>
                     <FlowPane styles="{horizontalAlignment:'right'}">
                         <Label text="%dataProvidedBy" />

Modified: incubator/pivot/trunk/tutorials/src/pivot/tutorials/text.wtkx
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/tutorials/src/pivot/tutorials/text.wtkx?rev=779169&r1=779168&r2=779169&view=diff
==============================================================================
--- incubator/pivot/trunk/tutorials/src/pivot/tutorials/text.wtkx (original)
+++ incubator/pivot/trunk/tutorials/src/pivot/tutorials/text.wtkx Wed May 27 13:41:59 2009
@@ -26,11 +26,11 @@
                 <Form>
                     <sections>
                         <Form.Section>
-	                        <TextInput Form.name="Basic" text="Pivot" textSize="12"/>
-	                        <TextInput Form.name="Prompt" prompt="Name" textSize="12"/>
-	                        <TextInput Form.name="Password"
-	                            Form.flag="{messageType:'info', message:'This field has a maximum length of 12 characters.'}"
-	                            password="true" text="pivot" textSize="12" maximumLength="12" />
+                            <TextInput Form.name="Basic" text="Pivot" textSize="12"/>
+                            <TextInput Form.name="Prompt" prompt="Name" textSize="12"/>
+                            <TextInput Form.name="Password"
+                                Form.flag="{messageType:'info', message:'This field has a maximum length of 12 characters.'}"
+                                password="true" text="pivot" textSize="12" maximumLength="12" />
                             <TextInput Form.name="Validating" Form.flag="{messageType:'info', message:'This field only accepts numeric values from 0 through 9.'}"
                                 text="5" textSize="12" maximumLength="6">
                                 <validator>