flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bigosma...@apache.org
Subject svn commit: r1432385 - in /flex/utilities/trunk/installer/src: InstallApacheFlex.mxml org/apache/flex/packageflexsdk/resource/RuntimeLocale.as org/apache/flex/packageflexsdk/view/itemrenderers/OptionalInstallItemRenderer.mxml
Date Sat, 12 Jan 2013 06:18:56 GMT
Author: bigosmallm
Date: Sat Jan 12 06:18:56 2013
New Revision: 1432385

URL: http://svn.apache.org/viewvc?rev=1432385&view=rev
Log:
Fix auto update version compare logic.
Fix UI of license screen.  Remove colors on checkbox.  
Add wording (in en_US locale) to point out that users must check the checkbox to accept the
license.

Modified:
    flex/utilities/trunk/installer/src/InstallApacheFlex.mxml
    flex/utilities/trunk/installer/src/org/apache/flex/packageflexsdk/resource/RuntimeLocale.as
    flex/utilities/trunk/installer/src/org/apache/flex/packageflexsdk/view/itemrenderers/OptionalInstallItemRenderer.mxml

Modified: flex/utilities/trunk/installer/src/InstallApacheFlex.mxml
URL: http://svn.apache.org/viewvc/flex/utilities/trunk/installer/src/InstallApacheFlex.mxml?rev=1432385&r1=1432384&r2=1432385&view=diff
==============================================================================
--- flex/utilities/trunk/installer/src/InstallApacheFlex.mxml (original)
+++ flex/utilities/trunk/installer/src/InstallApacheFlex.mxml Sat Jan 12 06:18:56 2013
@@ -544,10 +544,13 @@ variables are not required because the l
 			initiateInstallStepsActivity();
 			initializeInstallerComponentsDataProvider();
 			
-			checkVersion();
+			if(shouldUpdate())
+			{
+				doUpdate();
+			}
 		}
 		
-		protected function checkVersion():void
+		protected function shouldUpdate():Boolean
 		{
 			var shouldUpdate:Boolean = false;
 			//Current version
@@ -560,29 +563,35 @@ variables are not required because the l
 			
 			var availBuildNumbers:Array = _latestVersion.split(".");
 			var currentBuildNumbers:Array = currentVersion.split(".");
-			for (var i:int=0; i < currentBuildNumbers.length; i++)
+			
+			if(parseInt(availBuildNumbers[0]) > parseInt(currentBuildNumbers[0]))
 			{
-				if (parseInt(availBuildNumbers[i]) > parseInt(currentBuildNumbers[i]))
-				{
-					shouldUpdate = true;
-				}
-				else if(parseInt(availBuildNumbers[i]) == parseInt(currentBuildNumbers[i]))
+				return true;
+			}
+			else if(parseInt(availBuildNumbers[0]) == parseInt(currentBuildNumbers[0]))
+			{
+				if(parseInt(availBuildNumbers[1]) > parseInt(currentBuildNumbers[1]))
 				{
-					continue;
+					return true;
 				}
-				else
+				else if(parseInt(availBuildNumbers[1]) == parseInt(currentBuildNumbers[1]))
 				{
-					return;
+					if(parseInt(availBuildNumbers[2]) > parseInt(currentBuildNumbers[2]))
+					{
+						return true;
+					}
 				}
 			}
+			return false;
 			
-			if(shouldUpdate)
-			{
+		}
+		
+		protected function doUpdate():void
+		{
 				var updaterDialog:UpdaterDialog = UpdaterDialog(PopUpManager.createPopUp(this,UpdaterDialog,true));
 				updaterDialog.addEventListener("close",handleUpdaterDialogClose);
 				updaterDialog.latestVersion = _latestVersion;
 				PopUpManager.centerPopUp(updaterDialog);
-			}
 		}
 		
 		protected function handleUpdaterDialogClose(event:Event):void

Modified: flex/utilities/trunk/installer/src/org/apache/flex/packageflexsdk/resource/RuntimeLocale.as
URL: http://svn.apache.org/viewvc/flex/utilities/trunk/installer/src/org/apache/flex/packageflexsdk/resource/RuntimeLocale.as?rev=1432385&r1=1432384&r2=1432385&view=diff
==============================================================================
--- flex/utilities/trunk/installer/src/org/apache/flex/packageflexsdk/resource/RuntimeLocale.as
(original)
+++ flex/utilities/trunk/installer/src/org/apache/flex/packageflexsdk/resource/RuntimeLocale.as
Sat Jan 12 06:18:56 2013
@@ -432,7 +432,7 @@ public class RuntimeLocale
 		content["INFO_INSTALLING_PLAYERGLOBAL_SWC"]="Installing Adobe Flash Player playerglobal.swc
from: ";
 		content["INFO_INVOKED_GUI_MODE"]="invoked in GUI mode";
 		content["INFO_LICENSE_AGREEMENTS"]="License Agreements";
-		content["INFO_NEED_TO_READ_AND_AGREE_TO_LICENSE"]="This installer will download software
from multiple sites with various license agreements. Please click on each item on the left,
read the license and confirm that you agree to the terms of each license.";
+		content["INFO_NEED_TO_READ_AND_AGREE_TO_LICENSE"]="This installer will download software
from multiple sites with various license agreements. Please click on each item on the left,
read the license and confirm that you agree to the terms of each license by checking the checkbox
next to it.";
 		content["INFO_SELECT_DIRECTORY"]="Select the directory where you want to install the Flex
SDK";
 		content["INFO_SELECT_DIRECTORY_INSTALL"]="Select installation directory";
 		content["INFO_UNZIPPING"]="Uncompressing: ";

Modified: flex/utilities/trunk/installer/src/org/apache/flex/packageflexsdk/view/itemrenderers/OptionalInstallItemRenderer.mxml
URL: http://svn.apache.org/viewvc/flex/utilities/trunk/installer/src/org/apache/flex/packageflexsdk/view/itemrenderers/OptionalInstallItemRenderer.mxml?rev=1432385&r1=1432384&r2=1432385&view=diff
==============================================================================
--- flex/utilities/trunk/installer/src/org/apache/flex/packageflexsdk/view/itemrenderers/OptionalInstallItemRenderer.mxml
(original)
+++ flex/utilities/trunk/installer/src/org/apache/flex/packageflexsdk/view/itemrenderers/OptionalInstallItemRenderer.mxml
Sat Jan 12 06:18:56 2013
@@ -22,7 +22,7 @@ limitations under the License.
 				xmlns:mx="library://ns.adobe.com/flex/mx" 
 				autoDrawBackground="true">
 	<s:layout>
-		<s:HorizontalLayout verticalAlign="middle" gap="5" />
+		<s:HorizontalLayout verticalAlign="middle" gap="5" paddingLeft="5" />
 	</s:layout>
 	<fx:Metadata>
 		[Event(name="installItemSelectionChanged", type="org.apache.flex.packageflexsdk.view.events.InstallItemSelectionEvent")]
@@ -42,7 +42,7 @@ limitations under the License.
 		]]>
 	</fx:Script>
 	
-	<s:CheckBox id="checkbox1" selected="{data.selected}" enabled="true" change="checkbox1_changeHandler(event)"
skinClass="ws.tink.spark.skins.controls.ColorCheckBoxSkin" />
+	<s:CheckBox id="checkbox1" selected="{data.selected}" enabled="true" change="checkbox1_changeHandler(event)"
 />
 	<s:Label text="{data.label}" fontSize="12"/>
 	
 </s:ItemRenderer>



Mime
View raw message