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/07 16:39:08 UTC

svn commit: r772666 [2/2] - in /incubator/pivot/trunk/wtk: src/pivot/wtk/ src/pivot/wtk/content/ src/pivot/wtk/media/drawing/ src/pivot/wtk/skin/ src/pivot/wtk/skin/obsidian/ src/pivot/wtk/skin/terra/ test/pivot/wtk/media/drawing/test/

Modified: incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraTreeViewSkin.java
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraTreeViewSkin.java?rev=772666&r1=772665&r2=772666&view=diff
==============================================================================
--- incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraTreeViewSkin.java (original)
+++ incubator/pivot/trunk/wtk/src/pivot/wtk/skin/terra/TerraTreeViewSkin.java Thu May  7 14:39:07 2009
@@ -32,6 +32,7 @@
 import pivot.wtk.Checkbox;
 import pivot.wtk.Component;
 import pivot.wtk.Dimensions;
+import pivot.wtk.GraphicsUtilities;
 import pivot.wtk.Keyboard;
 import pivot.wtk.Mouse;
 import pivot.wtk.Orientation;
@@ -43,7 +44,6 @@
 import pivot.wtk.TreeViewNodeStateListener;
 import pivot.wtk.TreeViewSelectionListener;
 import pivot.wtk.skin.ComponentSkin;
-import pivot.wtk.skin.GraphicsUtilities;
 
 /**
  * Tree view skin.
@@ -590,7 +590,7 @@
             throw new IllegalArgumentException("color is null.");
         }
 
-        setColor(decodeColor(color));
+        setColor(GraphicsUtilities.decodeColor(color));
     }
 
     public final void setColor(int color) {
@@ -616,7 +616,7 @@
             throw new IllegalArgumentException("disabledColor is null.");
         }
 
-        setDisabledColor(decodeColor(disabledColor));
+        setDisabledColor(GraphicsUtilities.decodeColor(disabledColor));
     }
 
     public final void setDisabledColor(int disabledColor) {
@@ -642,7 +642,7 @@
             throw new IllegalArgumentException("backgroundColor is null.");
         }
 
-        setBackgroundColor(decodeColor(backgroundColor));
+        setBackgroundColor(GraphicsUtilities.decodeColor(backgroundColor));
     }
 
     public final void setBackgroundColor(int backgroundColor) {
@@ -668,7 +668,7 @@
             throw new IllegalArgumentException("selectionColor is null.");
         }
 
-        setSelectionColor(decodeColor(selectionColor));
+        setSelectionColor(GraphicsUtilities.decodeColor(selectionColor));
     }
 
     public final void setSelectionColor(int selectionColor) {
@@ -694,7 +694,7 @@
             throw new IllegalArgumentException("selectionBackgroundColor is null.");
         }
 
-        setSelectionBackgroundColor(decodeColor(selectionBackgroundColor));
+        setSelectionBackgroundColor(GraphicsUtilities.decodeColor(selectionBackgroundColor));
     }
 
     public final void setSelectionBackgroundColor(int selectionBackgroundColor) {
@@ -720,7 +720,7 @@
             throw new IllegalArgumentException("inactiveSelectionColor is null.");
         }
 
-        setInactiveSelectionColor(decodeColor(inactiveSelectionColor));
+        setInactiveSelectionColor(GraphicsUtilities.decodeColor(inactiveSelectionColor));
     }
 
     public final void setInactiveSelectionColor(int inactiveSelectionColor) {
@@ -746,7 +746,7 @@
             throw new IllegalArgumentException("inactiveSelectionBackgroundColor is null.");
         }
 
-        setInactiveSelectionBackgroundColor(decodeColor(inactiveSelectionBackgroundColor));
+        setInactiveSelectionBackgroundColor(GraphicsUtilities.decodeColor(inactiveSelectionBackgroundColor));
     }
 
     public final void setInactiveSelectionBackgroundColor(int inactiveSelectionBackgroundColor) {
@@ -772,7 +772,7 @@
             throw new IllegalArgumentException("highlightColor is null.");
         }
 
-        setHighlightColor(decodeColor(highlightColor));
+        setHighlightColor(GraphicsUtilities.decodeColor(highlightColor));
     }
 
     public final void setHighlightColor(int highlightColor) {
@@ -798,7 +798,7 @@
             throw new IllegalArgumentException("highlightBackgroundColor is null.");
         }
 
-        setHighlightBackgroundColor(decodeColor(highlightBackgroundColor));
+        setHighlightBackgroundColor(GraphicsUtilities.decodeColor(highlightBackgroundColor));
     }
 
     public final void setHighlightBackgroundColor(int highlightBackgroundColor) {
@@ -876,7 +876,7 @@
             throw new IllegalArgumentException("branchControlColor is null.");
         }
 
-        setBranchControlColor(decodeColor(branchControlColor));
+        setBranchControlColor(GraphicsUtilities.decodeColor(branchControlColor));
     }
 
     public final void setBranchControlColor(int branchControlColor) {
@@ -902,7 +902,7 @@
             throw new IllegalArgumentException("branchControlDisabledColor is null.");
         }
 
-        setBranchControlDisabledColor(decodeColor(branchControlDisabledColor));
+        setBranchControlDisabledColor(GraphicsUtilities.decodeColor(branchControlDisabledColor));
     }
 
     public final void setBranchControlDisabledColor(int branchControlDisabledColor) {
@@ -928,7 +928,7 @@
             throw new IllegalArgumentException("branchControlSelectionColor is null.");
         }
 
-        setBranchControlSelectionColor(decodeColor(branchControlSelectionColor));
+        setBranchControlSelectionColor(GraphicsUtilities.decodeColor(branchControlSelectionColor));
     }
 
     public final void setBranchControlSelectionColor(int branchControlSelectionColor) {
@@ -954,7 +954,7 @@
             throw new IllegalArgumentException("branchControlInactiveSelectionColor is null.");
         }
 
-        setBranchControlInactiveSelectionColor(decodeColor(branchControlInactiveSelectionColor));
+        setBranchControlInactiveSelectionColor(GraphicsUtilities.decodeColor(branchControlInactiveSelectionColor));
     }
 
     public final void setBranchControlInactiveSelectionColor(int branchControlInactiveSelectionColor) {
@@ -980,7 +980,7 @@
             throw new IllegalArgumentException("gridColor is null.");
         }
 
-        setGridColor(decodeColor(gridColor));
+        setGridColor(GraphicsUtilities.decodeColor(gridColor));
     }
 
     public final void setGridColor(int gridColor) {

Added: incubator/pivot/trunk/wtk/test/pivot/wtk/media/drawing/test/activity.wtkd
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/wtk/test/pivot/wtk/media/drawing/test/activity.wtkd?rev=772666&view=auto
==============================================================================
--- incubator/pivot/trunk/wtk/test/pivot/wtk/media/drawing/test/activity.wtkd (added)
+++ incubator/pivot/trunk/wtk/test/pivot/wtk/media/drawing/test/activity.wtkd Thu May  7 14:39:07 2009
@@ -0,0 +1,115 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to you under the Apache License,
+Version 2.0 (the "License"); you may not use this file except in
+compliance with the License.  You may obtain a copy of the License at
+
+    http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+-->
+
+<Drawing width="256" height="256" background="#ffffff"
+    xmlns="pivot.wtk.media"
+    xmlns:wtkx="http://incubator.apache.org/pivot/wtkx/1.1">
+    <canvas>
+        <Canvas xmlns="pivot.wtk.media.drawing">
+            <Group>
+                <transforms>
+                    <Shape.Translate x="128" y="128"/>
+                </transforms>
+                
+                <Rectangle x="0" y="-4" width="64" height="8" fill="0xaaaaaadd" stroke="#aaaaaa">
+                    <transforms>
+                        <Shape.Rotate angle="0"/>
+                        <Shape.Translate x="64"/>
+                    </transforms>
+                </Rectangle>
+
+                <Rectangle x="0" y="-4" width="64" height="8" fill="0xaaaaaacc" stroke="#aaaaaa">
+                    <transforms>
+                        <Shape.Rotate angle="30"/>
+                        <Shape.Translate x="64"/>
+                    </transforms>
+                </Rectangle>
+
+                <Rectangle x="0" y="-4" width="64" height="8" fill="0xaaaaaabb" stroke="#aaaaaa">
+                    <transforms>
+                        <Shape.Rotate angle="60"/>
+                        <Shape.Translate x="64"/>
+                    </transforms>
+                </Rectangle>
+
+                <Rectangle x="0" y="-4" width="64" height="8" fill="0xaaaaaaaa" stroke="#aaaaaa">
+                    <transforms>
+                        <Shape.Rotate angle="90"/>
+                        <Shape.Translate x="64"/>
+                    </transforms>
+                </Rectangle>
+
+                <Rectangle x="0" y="-4" width="64" height="8" fill="0xaaaaaa99" stroke="#aaaaaa">
+                    <transforms>
+                        <Shape.Rotate angle="120"/>
+                        <Shape.Translate x="64"/>
+                    </transforms>
+                </Rectangle>
+
+                <Rectangle x="0" y="-4" width="64" height="8" fill="0xaaaaaa88" stroke="#aaaaaa">
+                    <transforms>
+                        <Shape.Rotate angle="150"/>
+                        <Shape.Translate x="64"/>
+                    </transforms>
+                </Rectangle>
+
+                <Rectangle x="0" y="-4" width="64" height="8" fill="0xaaaaaa77" stroke="#aaaaaa">
+                    <transforms>
+                        <Shape.Rotate angle="180"/>
+                        <Shape.Translate x="64"/>
+                    </transforms>
+                </Rectangle>
+
+                <Rectangle x="0" y="-4" width="64" height="8" fill="0xaaaaaa66" stroke="#aaaaaa">
+                    <transforms>
+                        <Shape.Rotate angle="210"/>
+                        <Shape.Translate x="64"/>
+                    </transforms>
+                </Rectangle>
+
+                <Rectangle x="0" y="-4" width="64" height="8" fill="0xaaaaaa55" stroke="#aaaaaa">
+                    <transforms>
+                        <Shape.Rotate angle="240"/>
+                        <Shape.Translate x="64"/>
+                    </transforms>
+                </Rectangle>
+
+                <Rectangle x="0" y="-4" width="64" height="8" fill="0xaaaaaa44" stroke="#aaaaaa">
+                    <transforms>
+                        <Shape.Rotate angle="270"/>
+                        <Shape.Translate x="64"/>
+                    </transforms>
+                </Rectangle>
+
+                <Rectangle x="0" y="-4" width="64" height="8" fill="0xaaaaaa33" stroke="#aaaaaa">
+                    <transforms>
+                        <Shape.Rotate angle="300"/>
+                        <Shape.Translate x="64"/>
+                    </transforms>
+                </Rectangle>
+
+                <Rectangle x="0" y="-4" width="64" height="8" fill="0xaaaaaa22" stroke="#aaaaaa">
+                    <transforms>
+                        <Shape.Rotate angle="330"/>
+                        <Shape.Translate x="64"/>
+                    </transforms>
+                </Rectangle>
+            </Group>
+        </Canvas>
+    </canvas>
+</Drawing>

Copied: incubator/pivot/trunk/wtk/test/pivot/wtk/media/drawing/test/drawing_test.wtkx (from r772477, incubator/pivot/trunk/wtk/test/pivot/wtk/media/drawing/test/simple_drawing_test.wtkx)
URL: http://svn.apache.org/viewvc/incubator/pivot/trunk/wtk/test/pivot/wtk/media/drawing/test/drawing_test.wtkx?p2=incubator/pivot/trunk/wtk/test/pivot/wtk/media/drawing/test/drawing_test.wtkx&p1=incubator/pivot/trunk/wtk/test/pivot/wtk/media/drawing/test/simple_drawing_test.wtkx&r1=772477&r2=772666&rev=772666&view=diff
==============================================================================
--- incubator/pivot/trunk/wtk/test/pivot/wtk/media/drawing/test/simple_drawing_test.wtkx (original)
+++ incubator/pivot/trunk/wtk/test/pivot/wtk/media/drawing/test/drawing_test.wtkx Thu May  7 14:39:07 2009
@@ -19,6 +19,6 @@
 <ScrollPane xmlns:wtkx="http://incubator.apache.org/pivot/wtkx/1.1"
     xmlns="pivot.wtk">
     <view>
-        <ImageView styles="{backgroundColor:'#999999'}" image="@sample.wtkd"/>
+        <ImageView styles="{backgroundColor:'#999999'}" image="@activity.wtkd"/>
     </view>
 </ScrollPane>