[tor-commits] [orbot/master] Wizard UI/UX Refresh

n8fr8 at torproject.org n8fr8 at torproject.org
Fri Oct 28 15:28:27 UTC 2011


commit d937ee3ca96af9d383f1f1f8ab100ac59a9abd9d
Author: Sathyanarayanan Gunasekaran <gsathya.ceg at gmail.com>
Date:   Mon Jun 13 01:11:46 2011 +0530

    Wizard UI/UX Refresh
    
    Added theme.xml, updated all the views. Changed radiobutton logic
---
 res/layout/layout_apps_item.xml                    |    1 +
 res/layout/layout_wizard_permissions.xml           |   24 ++++++------
 res/layout/layout_wizard_root.xml                  |   20 +++++-----
 res/layout/layout_wizard_tips.xml                  |   21 ++++++-----
 res/layout/scrollingtext_buttons_view.xml          |   21 ++++++-----
 res/values/theme.xml                               |    9 +++++
 .../torproject/android/ConfigureTransProxy.java    |   36 +++++++++++--------
 src/org/torproject/android/Permissions.java        |    2 -
 src/org/torproject/android/TipsAndTricks.java      |   35 ++++++++++++++++++-
 9 files changed, 110 insertions(+), 59 deletions(-)

diff --git a/res/layout/layout_apps_item.xml b/res/layout/layout_apps_item.xml
index 8b4fc34..9d16efd 100644
--- a/res/layout/layout_apps_item.xml
+++ b/res/layout/layout_apps_item.xml
@@ -12,5 +12,6 @@
 <CheckBox  android:layout_width="wrap_content" android:layout_height="wrap_content" android:id="@+id/itemcheck" ></CheckBox>
        
     </TableRow>
+    
 </TableLayout>
 
diff --git a/res/layout/layout_wizard_permissions.xml b/res/layout/layout_wizard_permissions.xml
index 7926750..151bb3e 100644
--- a/res/layout/layout_wizard_permissions.xml
+++ b/res/layout/layout_wizard_permissions.xml
@@ -3,49 +3,49 @@
 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:orientation="vertical"
     android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-            android:background="@drawable/background">
+    android:layout_height="fill_parent">
             
 <RelativeLayout 
 	android:layout_width="match_parent" 
 	android:layout_height="wrap_content" 
 	android:id="@+id/relativeLayout1" 
-	android:layout_gravity="center_horizontal">
+	android:layout_gravity="center_horizontal"
+	android:background="#000000">
         
         <TextView android:textSize="10pt" 
-        	
+        	android:textColor="#FFFFFF"
         	android:layout_alignParentTop="true"
        	 	android:layout_height="wrap_content" 
         	android:id="@+id/WizardTextTitle" 
         	android:layout_width="wrap_content" 
         	android:fadingEdge="vertical" 
         	android:text="TITLE" 
-        	android:textColor="#00ff00" 
         	android:singleLine="true" 
           	android:padding="20px" android:layout_centerInParent="true"> 
         </TextView>
     </RelativeLayout>    
 <TableLayout android:id="@+id/TableLayout01" android:stretchColumns="*" android:layout_height="fill_parent" android:layout_width="wrap_content">
 
-<TableRow android:id="@+id/TableRow01" android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="fill_parent">
+<TableRow android:layout_margin="10dip" android:id="@+id/TableRow01" android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="fill_parent">
 
 
 	<ScrollView android:id="@+id/helpscrollview" 
 		android:orientation="vertical"
 		android:layout_width="fill_parent" 
 		android:layout_height="fill_parent"
-		 android:layout_span="3">
-		<LinearLayout android:layout_width="wrap_content" android:id="@+id/linearLayout1" android:layout_height="wrap_content" android:orientation="vertical">
-			<TextView android:layout_width="wrap_content" android:textColor="#ffffff" android:layout_height="wrap_content" android:background="#222222" android:textSize="8pt" android:id="@+id/WizardTextBody1" android:text="this is sample text this is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample text" android:padding="20dip"></TextView>
+		 android:layout_span="3"
+		 >
+		<LinearLayout android:background="#575757" android:layout_width="wrap_content" android:id="@+id/linearLayout1" android:layout_height="wrap_content" android:orientation="vertical">
+			<TextView android:layout_width="wrap_content" android:textColor="#ffffff" android:layout_height="wrap_content"  android:textSize="8pt" android:id="@+id/WizardTextBody1" android:text="this is sample text this is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample text" android:padding="20dip"></TextView>
 			<Button android:layout_width="wrap_content" android:visibility="gone" android:layout_height="wrap_content" android:gravity="center" android:text="Grant Permission" android:id="@+id/grantPermissions" android:layout_gravity="center"></Button>
-			<TextView android:layout_width="wrap_content" android:visibility="gone" android:textColor="#ffffff" android:layout_height="wrap_content" android:background="#222222" android:textSize="8pt" android:id="@+id/WizardTextBody2" android:text="this is sample text this is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample text" android:padding="20dip"></TextView>
-			<CheckBox android:id="@+id/checkBox" android:visibility="gone" android:layout_gravity="center" android:text="@string/wizard_permissions_consent" android:layout_height="wrap_content" android:layout_width="wrap_content"></CheckBox>
+			<TextView android:layout_width="wrap_content" android:visibility="gone" android:textColor="#ffffff" android:layout_height="wrap_content"  android:textSize="8pt" android:id="@+id/WizardTextBody2" android:text="this is sample text this is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample text" android:padding="20dip"></TextView>
+			<CheckBox android:id="@+id/checkBox" android:layout_gravity="center" android:text="@string/wizard_permissions_consent" android:layout_height="wrap_content" android:layout_width="wrap_content" android:gravity="center" android:visibility="visible"></CheckBox>
 		</LinearLayout>
 
 		</ScrollView>
 		
 </TableRow>
-<TableRow android:id="@+id/TableRow01" android:textColor="#00ff00" android:layout_width="fill_parent" android:layout_height="30px">
+<TableRow android:background="#000000" android:layout_marginTop="10dip" android:paddingTop="10dip" android:id="@+id/TableRow01" android:textColor="#00ff00" android:layout_width="fill_parent" android:layout_height="30px">
 	   	<Button android:text="Back" android:id="@+id/btnWizard1" android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="wrap_content"></Button>
     	<Button android:text="Next" android:id="@+id/btnWizard2"  android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="wrap_content"></Button>	    
 </TableRow>			
diff --git a/res/layout/layout_wizard_root.xml b/res/layout/layout_wizard_root.xml
index d038a96..4c64035 100644
--- a/res/layout/layout_wizard_root.xml
+++ b/res/layout/layout_wizard_root.xml
@@ -3,30 +3,29 @@
 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:orientation="vertical"
     android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-            android:background="@drawable/background">
+    android:layout_height="fill_parent">
             
 <RelativeLayout 
 	android:layout_width="match_parent" 
 	android:layout_height="wrap_content" 
 	android:id="@+id/relativeLayout1" 
-	android:layout_gravity="center_horizontal">
+	android:layout_gravity="center_horizontal"
+	android:background="#000000">
          <TextView android:textSize="10pt" 
-        	
+        	android:textColor="#FFFFFF"
         	android:layout_alignParentTop="true"
        	 	android:layout_height="wrap_content" 
         	android:id="@+id/WizardTextTitle" 
         	android:layout_width="wrap_content" 
         	android:fadingEdge="vertical" 
         	android:text="TITLE" 
-        	android:textColor="#00ff00" 
         	android:singleLine="true" 
           	android:padding="20px" android:layout_centerInParent="true"> 
         </TextView>
     </RelativeLayout>    
 <TableLayout android:id="@+id/TableLayout01" android:stretchColumns="*" android:layout_height="fill_parent" android:layout_width="wrap_content">
 
-<TableRow android:id="@+id/TableRow01" android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="fill_parent">
+<TableRow android:layout_margin="10dip" android:id="@+id/TableRow01" android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="fill_parent">
 
 
 	<ScrollView android:id="@+id/helpscrollview" 
@@ -36,18 +35,19 @@
 		 android:layout_span="3">    
 
 <LinearLayout
+			android:background="#575757"
 		    android:orientation="vertical"
 		    android:layout_width="fill_parent"
 		    android:layout_height="fill_parent"
 		    android:padding="3px">
-<TextView android:text="@string/wizard_transproxy_msg" android:layout_width="wrap_content" android:textColor="#ffffff" android:layout_height="wrap_content" android:background="#222222" android:textSize="8pt" android:id="@+id/WizardTextBody1" android:padding="20dip"></TextView>
-<RadioGroup android:id="@+id/radioGroup" android:layout_height="wrap_content" android:layout_width="wrap_content">
+<TextView android:text="@string/wizard_transproxy_msg" android:layout_width="wrap_content" android:textColor="#ffffff" android:layout_height="wrap_content"  android:textSize="8pt" android:id="@+id/WizardTextBody1" android:padding="20dip"></TextView>
+<RadioGroup android:id="@+id/radioGroup" android:layout_height="wrap_content" android:layout_width="wrap_content" android:paddingLeft="15dip">
     <RadioButton android:checked="true" android:text="@string/wizard_configure_all" android:id="@+id/radio0" android:layout_height="wrap_content" android:layout_width="wrap_content"></RadioButton>
 	   <TextView android:layout_height="wrap_content" 
         android:text="@string/wizard_transproxy_hint"
         android:layout_width="wrap_content" 
         android:textSize="15sp"
-        android:paddingBottom="10dip">
+        android:paddingBottom="10dip" android:paddingRight="20dip">
     </TextView>   
     <RadioButton android:text="@string/wizard_configure_select_apps" android:id="@+id/radio1" android:layout_height="wrap_content" android:layout_width="wrap_content"></RadioButton>
     <RadioButton android:text="@string/wizard_transproxy_none" android:id="@+id/radio2" android:layout_height="wrap_content" android:layout_width="wrap_content"></RadioButton>
@@ -58,7 +58,7 @@
 		</ScrollView>
 		
 </TableRow>
-<TableRow android:id="@+id/TableRow01" android:textColor="#00ff00" android:layout_width="fill_parent" android:layout_height="30px">
+<TableRow android:background="#000000" android:layout_marginTop="10dip" android:paddingTop="10dip" android:id="@+id/TableRow01" android:textColor="#00ff00" android:layout_width="fill_parent" android:layout_height="30px">
 	   	<Button android:text="Back" android:id="@+id/btnWizard1" android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="wrap_content"></Button>
     	<Button android:text="Next" android:id="@+id/btnWizard2"  android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="wrap_content"></Button>	    
 </TableRow>			
diff --git a/res/layout/layout_wizard_tips.xml b/res/layout/layout_wizard_tips.xml
index a9c4d0b..1b7b50b 100644
--- a/res/layout/layout_wizard_tips.xml
+++ b/res/layout/layout_wizard_tips.xml
@@ -3,30 +3,29 @@
 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
     android:orientation="vertical"
     android:layout_width="fill_parent"
-    android:layout_height="fill_parent"
-            android:background="@drawable/background">
+    android:layout_height="fill_parent">
             
 <RelativeLayout 
 	android:layout_width="match_parent" 
 	android:layout_height="wrap_content" 
 	android:id="@+id/relativeLayout1" 
-	android:layout_gravity="center_horizontal">
+	android:layout_gravity="center_horizontal"
+	android:background="#000000">
          <TextView android:textSize="10pt" 
-        	
+        	android:textColor="#FFFFFF"
         	android:layout_alignParentTop="true"
        	 	android:layout_height="wrap_content" 
         	android:id="@+id/WizardTextTitle" 
         	android:layout_width="wrap_content" 
         	android:fadingEdge="vertical" 
         	android:text="TITLE" 
-        	android:textColor="#00ff00" 
         	android:singleLine="true" 
           	android:padding="20px" android:layout_centerInParent="true"> 
         </TextView>
     </RelativeLayout>    
-<TableLayout android:id="@+id/TableLayout01" android:stretchColumns="*" android:layout_height="fill_parent" android:layout_width="wrap_content">
+<TableLayout  android:id="@+id/TableLayout01" android:stretchColumns="*" android:layout_height="fill_parent" android:layout_width="wrap_content">
 
-<TableRow android:id="@+id/TableRow01" android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="fill_parent">
+<TableRow android:layout_margin="10dip"   android:id="@+id/TableRow01" android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="fill_parent">
 
 
 	<ScrollView android:id="@+id/helpscrollview" 
@@ -36,12 +35,14 @@
 		 android:layout_span="3">    
 
 <LinearLayout
+			android:background="#575757"
 		    android:orientation="vertical"
 		    android:layout_width="fill_parent"
 		    android:layout_height="fill_parent"
-		    android:padding="3px">
+		    android:paddingRight="20dip"
+		    >
 		    
-<TextView android:text="@string/wizard_tips_msg" android:layout_width="wrap_content" android:textColor="#ffffff" android:layout_height="wrap_content" android:background="#222222" android:textSize="8pt" android:id="@+id/WizardTextBody1" android:padding="20dip"></TextView>
+<TextView android:text="@string/wizard_tips_msg" android:layout_width="wrap_content" android:textColor="#ffffff" android:layout_height="wrap_content"  android:textSize="8pt" android:id="@+id/WizardTextBody1" android:padding="20dip"></TextView>
 <Button android:text="@string/wizard_tips_gibberbot"  android:layout_gravity="left" android:drawableLeft="@drawable/ic_launcher_gibberbot"  android:layout_marginTop="10px" android:id="@+id/WizardRootButtonInstallGibberbot" android:layout_width="wrap_content" android:layout_height="wrap_content"/>
 
 <Button android:text="@string/wizard_tips_firefox"  android:layout_gravity="left" android:drawableLeft="@drawable/icon_firefox" android:layout_marginTop="10px" android:id="@+id/WizardRootButtonInstallFirefox" android:layout_width="wrap_content" android:layout_height="wrap_content"/>
@@ -52,7 +53,7 @@
 		</ScrollView>
 		
 </TableRow>
-<TableRow android:id="@+id/TableRow01" android:textColor="#00ff00" android:layout_width="fill_parent" android:layout_height="30px">
+<TableRow android:background="#000000" android:layout_marginTop="10dip" android:paddingTop="10dip" android:id="@+id/TableRow01" android:textColor="#00ff00" android:layout_width="fill_parent" android:layout_height="30px">
 	   	<Button android:text="Back" android:id="@+id/btnWizard1" android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="wrap_content"></Button>
     	<Button android:text="Next" android:id="@+id/btnWizard2"  android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="wrap_content"></Button>	    
 </TableRow>			
diff --git a/res/layout/scrollingtext_buttons_view.xml b/res/layout/scrollingtext_buttons_view.xml
index 04023ff..930bf72 100644
--- a/res/layout/scrollingtext_buttons_view.xml
+++ b/res/layout/scrollingtext_buttons_view.xml
@@ -4,13 +4,15 @@
     android:orientation="vertical"
     android:layout_width="fill_parent"
     android:layout_height="fill_parent"
-            android:background="@drawable/background">
+   >
             
 <RelativeLayout 
 	android:layout_width="match_parent" 
 	android:layout_height="wrap_content" 
 	android:id="@+id/relativeLayout1" 
-	android:layout_gravity="center_horizontal">
+	android:layout_gravity="center_horizontal"
+	android:background="#000000"
+	>
         <ImageView 
         	android:src="@drawable/tor" 
         	android:id="@+id/orbot_image" 
@@ -19,7 +21,9 @@
         	android:layout_alignParentLeft="true"
         	android:paddingLeft="20px" android:paddingRight="20px" >
         </ImageView>
-        <TextView android:textSize="10pt" 
+        <TextView 
+        	android:textColor="#FFFFFF"
+        	android:textSize="10pt" 
         	android:layout_toRightOf="@id/orbot_image" 
         	android:layout_alignParentTop="true"
         	android:gravity="center_vertical"
@@ -27,8 +31,7 @@
         	android:id="@+id/WizardTextTitle" 
         	android:layout_width="wrap_content" 
         	android:fadingEdge="vertical" 
-        	android:text="TITLE" 
-        	android:textColor="#00ff00" 
+        	android:text="TITLE"     
         	android:singleLine="true" 
         	
         	
@@ -37,9 +40,9 @@
         	android:padding="20px"> 
         </TextView>
     </RelativeLayout>    
-<TableLayout android:id="@+id/TableLayout01" android:stretchColumns="*" android:layout_height="fill_parent" android:layout_width="wrap_content">
+<TableLayout  android:id="@+id/TableLayout01" android:stretchColumns="*" android:layout_height="fill_parent" android:layout_width="wrap_content" >
 
-<TableRow android:id="@+id/TableRow01" android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="fill_parent">
+<TableRow android:id="@+id/TableRow01"  android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="fill_parent" android:layout_margin="10dip">
 
 
 	<ScrollView android:id="@+id/helpscrollview" 
@@ -48,12 +51,12 @@
 		android:layout_height="fill_parent"
 		 android:layout_span="3">    
 
-			<TextView android:text="this is sample text this is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample text" android:background="#222222" android:textColor="#ffffff"  android:id="@+id/WizardTextBody" android:textSize="8pt" android:layout_width="wrap_content" android:layout_height="wrap_content" android:padding="20dip"></TextView>
+			<TextView  android:background="#575757" android:text="this is sample text this is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample textthis is sample text"  android:textColor="#ffffff"  android:id="@+id/WizardTextBody" android:textSize="8pt" android:layout_width="wrap_content" android:layout_height="wrap_content" android:padding="20dip"></TextView>
 
 		</ScrollView>
 		
 </TableRow>
-<TableRow android:id="@+id/TableRow01" android:textColor="#00ff00" android:layout_width="fill_parent" android:layout_height="30px">
+<TableRow  android:background="#000000" android:id="@+id/TableRow01" android:textColor="#00ff00" android:layout_width="fill_parent" android:layout_height="30px" android:layout_marginTop="10dip" android:paddingTop="10dip">
 	   	<Button android:text="Back" android:id="@+id/btnWizard1" android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="wrap_content"></Button>
     	<Button android:text="Next" android:id="@+id/btnWizard2"  android:layout_weight="1" android:layout_width="fill_parent" android:layout_height="wrap_content"></Button>	    
 </TableRow>			
diff --git a/res/values/theme.xml b/res/values/theme.xml
new file mode 100644
index 0000000..efc15c4
--- /dev/null
+++ b/res/values/theme.xml
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="utf-8"?>
+
+<resources>
+	<color name="custom_theme_color">#333</color>
+    <style name="DefaultTheme" parent="@android:style/Theme.Black.NoTitleBar">
+        <item name="android:windowBackground">@drawable/bgtitanium</item>
+        <item name="android:windowNoTitle">true</item>
+    </style>
+</resources>
diff --git a/src/org/torproject/android/ConfigureTransProxy.java b/src/org/torproject/android/ConfigureTransProxy.java
index 3f0f31c..4e9405b 100644
--- a/src/org/torproject/android/ConfigureTransProxy.java
+++ b/src/org/torproject/android/ConfigureTransProxy.java
@@ -81,22 +81,24 @@ public class ConfigureTransProxy extends Activity implements TorConstants {
 	        		SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context);
 
 					Editor pEdit = prefs.edit();
-						
 					pEdit.putBoolean(PREF_TRANSPARENT, rb0.isChecked());
 					pEdit.putBoolean(PREF_TRANSPARENT_ALL, rb0.isChecked());
-						
 					pEdit.commit();
+
+					if(rb0.isChecked())
+					{ 	
+						pEdit.putString("radiobutton","rb0");
+						pEdit.commit();
+					}
 	        		
-	        		
-	        		if(rb1.isChecked())
+					else if(rb1.isChecked())
 	        		{	
 	        			flag = 1;
-	        			SharedPreferences prefs1 = PreferenceManager.getDefaultSharedPreferences(context);
-
-						Editor pEdit1 = prefs1.edit();
-						pEdit1.putBoolean(PREF_TRANSPARENT, true);
-						pEdit1.putBoolean(PREF_TRANSPARENT_ALL, false);
-						pEdit1.commit();
+	        			
+	        			pEdit.putBoolean(PREF_TRANSPARENT, true);
+						pEdit.putBoolean(PREF_TRANSPARENT_ALL, false);
+						pEdit.putString("radiobutton","rb1");
+						pEdit.commit();
 						
 						next.setOnClickListener(new View.OnClickListener() {
 		    				
@@ -109,7 +111,11 @@ public class ConfigureTransProxy extends Activity implements TorConstants {
 		    				}
 		    			});
 	        		}
-	        		
+					else if(rb2.isChecked())
+					{
+						pEdit.putString("radiobutton", "rb2");
+						pEdit.commit();
+					}
 	        		
 	        }
 	        });
@@ -127,7 +133,8 @@ public class ConfigureTransProxy extends Activity implements TorConstants {
 			});
 	    	
 	    	next.setOnClickListener(new View.OnClickListener() {
-				
+			
+	    		//Dirty flag variable - improve logic
 				@Override
 				public void onClick(View v) {
 					if( flag == 1 )
@@ -152,8 +159,8 @@ public class ConfigureTransProxy extends Activity implements TorConstants {
 			
 			@Override
 			public void onClick(DialogInterface dialog, int which) {
-				//close wizard - return to orbot
-				
+				context.startActivity(new Intent(context, Orbot.class));
+
 			}
 		};
 	
@@ -164,7 +171,6 @@ public class ConfigureTransProxy extends Activity implements TorConstants {
         .setPositiveButton(R.string.button_close, ocListener)
         .setMessage(msg)
         .show();
-		
 	
 	
 				
diff --git a/src/org/torproject/android/Permissions.java b/src/org/torproject/android/Permissions.java
index 4b74c55..1c5b10c 100644
--- a/src/org/torproject/android/Permissions.java
+++ b/src/org/torproject/android/Permissions.java
@@ -80,12 +80,10 @@ public class Permissions extends Activity implements TorConstants {
 		
 		if (hasRoot)
 		{
-			Toast.makeText(context, "Has Root", Toast.LENGTH_SHORT).show();
 			stepFourRoot();
 		}
 		else
 		{
-			Toast.makeText(context, "Unable to get root access", Toast.LENGTH_LONG).show();
 			stepFour();
 		}
 		
diff --git a/src/org/torproject/android/TipsAndTricks.java b/src/org/torproject/android/TipsAndTricks.java
index a3aa1ef..ebb5ad3 100644
--- a/src/org/torproject/android/TipsAndTricks.java
+++ b/src/org/torproject/android/TipsAndTricks.java
@@ -1,7 +1,9 @@
 package org.torproject.android;
 
 import android.app.Activity;
+import android.app.AlertDialog;
 import android.content.Context;
+import android.content.DialogInterface;
 import android.content.Intent;
 import android.net.Uri;
 import android.os.Bundle;
@@ -98,9 +100,40 @@ public class TipsAndTricks extends Activity implements TorConstants {
 			
 			@Override
 			public void onClick(View v) {
-				//Finsh Screen
+				showWizardFinal();
 			}
 		});
         
 	}
+	
+	private void showWizardFinal ()
+	{
+		String title = null;
+		String msg = null;
+		
+		
+		title = context.getString(R.string.wizard_final);
+		msg = context.getString(R.string.wizard_final_msg);
+		
+		DialogInterface.OnClickListener ocListener = new DialogInterface.OnClickListener() {
+			
+			@Override
+			public void onClick(DialogInterface dialog, int which) {
+				context.startActivity(new Intent(context, Orbot.class));
+
+			}
+		};
+	
+		
+		 new AlertDialog.Builder(context)
+		.setIcon(R.drawable.icon)
+        .setTitle(title)
+        .setPositiveButton(R.string.button_close, ocListener)
+        .setMessage(msg)
+        .show();
+	
+	
+				
+		
+	}
 }
\ No newline at end of file





More information about the tor-commits mailing list