Improve TOS/privacy wording.

Add a final confirmation screen.
Misc wording tweaks.
This commit is contained in:
burke.davey
2010-07-31 20:34:52 +00:00
parent 573d7e33a3
commit 64b1562c69
4 changed files with 128 additions and 45 deletions

View File

@@ -11,15 +11,6 @@
android:layout_width="fill_parent" android:layout_width="fill_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginTop="5dip"/> android:layout_marginTop="5dip"/>
<TextView
android:id="@+id/connected_text"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/connected_text"
android:textColor="#000000"
android:layout_below="@+id/header"
android:layout_margin="5dip"/>
<TextView <TextView
android:id="@+id/select_link_action_text" android:id="@+id/select_link_action_text"
@@ -27,7 +18,7 @@
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:text="@string/select_link_action_text" android:text="@string/select_link_action_text"
android:textColor="#000000" android:textColor="#000000"
android:layout_below="@+id/connected_text" android:layout_below="@+id/header"
android:layout_margin="5dip"/> android:layout_margin="5dip"/>
<RadioGroup <RadioGroup
@@ -74,7 +65,7 @@
<Button <Button
android:id="@+id/next" android:id="@+id/next"
android:text="@string/finish" android:text="@string/next"
android:layout_marginTop="5px" android:layout_marginTop="5px"
android:layout_weight="1" android:layout_weight="1"
android:layout_width="0dip" android:layout_width="0dip"

View File

@@ -0,0 +1,57 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@drawable/background_gradient">
<ImageView
android:id="@+id/header"
android:background="@drawable/header"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_marginTop="5dip"/>
<ScrollView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_above="@+id/footer"
android:layout_below="@+id/header"
android:layout_margin="5dip">
<TextView
android:id="@+id/setup_complete_text"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:textColor="#000000"/>
</ScrollView>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/footer"
android:orientation="horizontal"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:background="#FF707070">
<Button
android:id="@+id/prev"
android:text="@string/prev"
android:layout_marginTop="5px"
android:layout_weight="1"
android:layout_width="0dip"
android:layout_height="wrap_content"
android:drawableLeft="@drawable/ic_btn_prev"/>
<Button
android:id="@+id/finish"
android:text="@string/finish"
android:layout_marginTop="5px"
android:layout_weight="1"
android:layout_width="0dip"
android:layout_height="wrap_content"/>
</LinearLayout>
</RelativeLayout>

View File

@@ -9,28 +9,34 @@
<string name="click_next_text">Click Next to establish the connection between Chrome and this phone.</string> <string name="click_next_text">Click Next to establish the connection between Chrome and this phone.</string>
<string name="connecting_text">Connecting...</string> <string name="connecting_text">Connecting...</string>
<string name="disconnecting_text">Disconnecting...</string> <string name="disconnecting_text">Disconnecting...</string>
<string name="connected_text">Your phone is now connected to Chrome.</string>
<string name="connect_error_text">Error: Unable to connect.</string> <string name="connect_error_text">Error: Unable to connect.</string>
<string name="auth_error_text">Error: Google Apps accounts not supported.</string> <string name="auth_error_text">Error: Google Apps accounts not supported.</string>
<string name="finish">Finish</string> <string name="finish">Finish</string>
<string name="select_link_action_text">Please set your link action preference:</string> <string name="select_link_action_text">Please set your link action preference:</string>
<string name="auto_launch_text">Automatically launch links</string> <string name="auto_launch_text">Automatically launch links</string>
<string name="manual_launch_text">Let me launch links manually</string> <string name="manual_launch_text">Let me launch links manually</string>
<string name="setup_complete_text">
Congratulations! Your phone is now connected and ready to receive links from Chrome. &lt;br>&lt;br>
If you have not already done so, you now need to install the Chrome Extension by visiting the
Chrome Extension gallery on your desktop at&lt;br>http://chrome.google.com/extensions/
and searching for "Chrome to Phone".
</string>
<string name="connected_with_account_text">Your phone is connected to Chrome using this account:</string> <string name="connected_with_account_text">Your phone is connected to Chrome using this account:</string>
<string name="link_action_pref_text">Link action preference:</string> <string name="link_action_pref_text">Link action preference:</string>
<string name="disconnect">Disconnect phone</string> <string name="disconnect">Disconnect</string>
<string name="disconnect_error_text">Error: Unable to disconnect.</string> <string name="disconnect_error_text">Error: Unable to disconnect.</string>
<string name="help">Help</string> <string name="help">Help</string>
<string name="intro_text"> <string name="intro_text">
Chrome to Phone lets you easily share links, maps, and selected phone numbers and text Chrome to Phone lets you easily share links, maps, and selected phone numbers and text
between your computer and your phone. &lt;br>&lt;br>You need to install the Chrome between your computer and your phone. &lt;br>&lt;br>You need to install the Chrome
browser extension on your computer to send links to your phone. The browser extension browser extension on your computer to send links to your phone. The browser extension
can be downloaded from the Chrome extension gallery at http://chrome.google.com/extensions/ can be downloaded from the Chrome extension gallery at http://chrome.google.com/extensions/.
&lt;br>&lt;br>There are just 3 simple steps to complete the set up on your phone: Simply search for "Chrome to Phone".&lt;br>&lt;br>There are just 3 simple steps to complete
&lt;br>&lt;br>1. Choose the Google Account to use.&lt;br>2. Connect your Chrome and your the set up on your phone: &lt;br>&lt;br>1. Choose the Google Account to use.&lt;br>
phone.&lt;br>3. Set your link action preference.&lt;br>&lt;br> 2. Connect your Chrome and your phone.&lt;br>3. Set your link action preference.&lt;br>&lt;br>
&lt;a href="http://m.google.com/tos">Terms of Service&lt;/a>&lt;br>&lt;br> By using this application, you agree to the &lt;br>
&lt;a href="http://m.google.com/privacy">Privacy&lt;/a> &lt;a href="http://m.google.com/tos">Terms of Service&lt;/a> and
&lt;a href="http://m.google.com/privacy">Privacy Policy&lt;/a>
</string> </string>
<string name="help_text"> <string name="help_text">
Chrome to Phone lets you easily share links, maps, and selected phone numbers and text Chrome to Phone lets you easily share links, maps, and selected phone numbers and text

View File

@@ -115,22 +115,28 @@ public class MainActivity extends Activity {
mScreenId = screenId; mScreenId = screenId;
setContentView(screenId); setContentView(screenId);
switch (screenId) { switch (screenId) {
case R.layout.intro: { // Screen shown if phone is registered/connected
setIntroScreenContent(); case R.layout.connected: {
break; setConnectedScreenContent();
} break;
case R.layout.select_account: { }
setSelectAccountScreenContent(); // Ordered sequence of screens for setup
break; case R.layout.intro: {
} setIntroScreenContent();
case R.layout.select_launch_mode: { break;
setSelectLaunchModeScreenContent(); }
break; case R.layout.select_account: {
} setSelectAccountScreenContent();
case R.layout.connected: { break;
setConnectedScreenContent(); }
break; case R.layout.select_launch_mode: {
} setSelectLaunchModeScreenContent();
break;
}
case R.layout.setup_complete: {
setSetupCompleteScreenContent();
break;
}
} }
} }
@@ -203,12 +209,30 @@ public class MainActivity extends Activity {
nextButton.setOnClickListener(new OnClickListener() { nextButton.setOnClickListener(new OnClickListener() {
public void onClick(View v) { public void onClick(View v) {
storeLaunchModePreference(); storeLaunchModePreference();
setScreenContent(R.layout.connected); setScreenContent(R.layout.setup_complete);
} }
}); });
RadioButton manualButton = (RadioButton) findViewById(R.id.manual_launch); setLaunchModePreferenceUI();
manualButton.setChecked(true); }
private void setSetupCompleteScreenContent() {
TextView textView = (TextView) findViewById(R.id.setup_complete_text);
textView.setText(Html.fromHtml(getString((R.string.setup_complete_text))));
Button prevButton = (Button) findViewById(R.id.prev);
prevButton.setOnClickListener(new OnClickListener() {
public void onClick(View v) {
setScreenContent(R.layout.select_launch_mode);
}
});
Button finishButton = (Button) findViewById(R.id.finish);
finishButton.setOnClickListener(new OnClickListener() {
public void onClick(View v) {
finish();
}
});
} }
private void setConnectedScreenContent() { private void setConnectedScreenContent() {
@@ -217,13 +241,7 @@ public class MainActivity extends Activity {
statusText.setText(getString(R.string.connected_with_account_text) + " " + statusText.setText(getString(R.string.connected_with_account_text) + " " +
prefs.getString("accountName", "error")); prefs.getString("accountName", "error"));
if (prefs.getBoolean("launchBrowserOrMaps", false)) { setLaunchModePreferenceUI();
RadioButton automaticButton = (RadioButton) findViewById(R.id.auto_launch);
automaticButton.setChecked(true);
} else {
RadioButton manualButton = (RadioButton) findViewById(R.id.manual_launch);
manualButton.setChecked(true);
}
RadioGroup launchMode = (RadioGroup) findViewById(R.id.launch_mode_radio); RadioGroup launchMode = (RadioGroup) findViewById(R.id.launch_mode_radio);
launchMode.setOnCheckedChangeListener(new OnCheckedChangeListener() { launchMode.setOnCheckedChangeListener(new OnCheckedChangeListener() {
@@ -249,6 +267,17 @@ public class MainActivity extends Activity {
editor.commit(); editor.commit();
} }
private void setLaunchModePreferenceUI() {
SharedPreferences prefs = Prefs.get(this);
if (prefs.getBoolean("launchBrowserOrMaps", true)) {
RadioButton automaticButton = (RadioButton) findViewById(R.id.auto_launch);
automaticButton.setChecked(true);
} else {
RadioButton manualButton = (RadioButton) findViewById(R.id.manual_launch);
manualButton.setChecked(true);
}
}
private void register(String account) { private void register(String account) {
ProgressBar progressBar = (ProgressBar) findViewById(R.id.progress_bar); ProgressBar progressBar = (ProgressBar) findViewById(R.id.progress_bar);
progressBar.setVisibility(ProgressBar.VISIBLE); progressBar.setVisibility(ProgressBar.VISIBLE);