You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@flex.apache.org by bi...@apache.org on 2014/10/03 02:16:59 UTC

[2/2] git commit: [flex-sdk] [refs/heads/iso7skins] - First shot at ios7 Button skin

First shot at ios7 Button skin


Project: http://git-wip-us.apache.org/repos/asf/flex-sdk/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-sdk/commit/8ea85e5f
Tree: http://git-wip-us.apache.org/repos/asf/flex-sdk/tree/8ea85e5f
Diff: http://git-wip-us.apache.org/repos/asf/flex-sdk/diff/8ea85e5f

Branch: refs/heads/iso7skins
Commit: 8ea85e5f5b797ddd6567152fddf4b3f4b27cfbe5
Parents: aab543f
Author: OmPrakash Muppirala <bi...@gmail.com>
Authored: Thu Oct 2 17:14:39 2014 -0700
Committer: OmPrakash Muppirala <bi...@gmail.com>
Committed: Thu Oct 2 17:14:39 2014 -0700

----------------------------------------------------------------------
 .../src/spark/skins/ios7/ButtonSkin.as          |  5 ++-
 .../src/spark/skins/ios7/assets/Button_up.fxg   | 45 +++-----------------
 2 files changed, 11 insertions(+), 39 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/8ea85e5f/frameworks/projects/mobiletheme/src/spark/skins/ios7/ButtonSkin.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/mobiletheme/src/spark/skins/ios7/ButtonSkin.as b/frameworks/projects/mobiletheme/src/spark/skins/ios7/ButtonSkin.as
index 040b70c..91851fe 100644
--- a/frameworks/projects/mobiletheme/src/spark/skins/ios7/ButtonSkin.as
+++ b/frameworks/projects/mobiletheme/src/spark/skins/ios7/ButtonSkin.as
@@ -90,8 +90,11 @@ public class ButtonSkin extends ButtonSkinBase
     public function ButtonSkin()
     {
         super();
+		//In iOS7, buttons look like simple links, without any shape containing the text
+		//We still need to assign an asset to determine the size of the button
+		//Button_up is a simple transparent graphic object
 		upBorderSkin = spark.skins.ios7.assets.Button_up;
-		downBorderSkin = spark.skins.ios7.assets.Button_down;
+		downBorderSkin = spark.skins.ios7.assets.Button_up;
 		layoutCornerEllipseSize = 0;
         
         switch (applicationDPI)

http://git-wip-us.apache.org/repos/asf/flex-sdk/blob/8ea85e5f/frameworks/projects/mobiletheme/src/spark/skins/ios7/assets/Button_up.fxg
----------------------------------------------------------------------
diff --git a/frameworks/projects/mobiletheme/src/spark/skins/ios7/assets/Button_up.fxg b/frameworks/projects/mobiletheme/src/spark/skins/ios7/assets/Button_up.fxg
index af7d033..59854b1 100644
--- a/frameworks/projects/mobiletheme/src/spark/skins/ios7/assets/Button_up.fxg
+++ b/frameworks/projects/mobiletheme/src/spark/skins/ios7/assets/Button_up.fxg
@@ -19,42 +19,11 @@
 -->
 
 <Graphic version="2.0" xmlns="http://ns.adobe.com/fxg/2008">
-  <Group>
-    <Group alpha="0.399994">
-      <Group>
-        <mask>
-          <Group>
-            <Path winding="nonZero" data="M0 1 184 1 184 0 0 0 0 1Z">
-              <fill>
-                <SolidColor color="#FFFFFF"/>
-              </fill>
-            </Path>
-          </Group>
-        </mask>
-        <Path winding="nonZero" data="M184 1 0 1 0 0 184 0 184 1Z">
-          <fill>
-            <SolidColor color="#FFFFFF"/>
-          </fill>
-        </Path>
-      </Group>
-    </Group>
-    <Group alpha="0.100006">
-      <Group>
-        <Path winding="nonZero" data="M183 0 183 38 0 38 0 39 184 39 184 0 183 0Z">
-          <fill>
-            <SolidColor color="#484849"/>
-          </fill>
-        </Path>
-        <Group>
-          <Path winding="nonZero" data="M184 39 0 39 0 0 184 0 184 39Z">
-            <fill>
-              <SolidColor color="#CDCCCC"/>
-            </fill>
-          </Path>
-          <Path winding="nonZero" data="M0 39 184 39 184 0 0 0 0 39Z"/>
-        </Group>
-      </Group>
-    </Group>
-    <Path visible="false" winding="nonZero" data="M0 0 184 0 184 39 0 39 0 0Z"/>
-  </Group>
+	<Group alpha="0">
+		<Path winding="nonZero" data="M183 0 183 38 0 38 0 39 184 39 184 0 183 0Z">
+		  <fill>
+			<SolidColor color="#484849"/>
+		  </fill>
+		</Path>
+	</Group>
 </Graphic>
\ No newline at end of file