Modify the sharing flow to first show a list of applications.

Store preferred account as a sharing setting.
Remove share url only option. Apply share url only if twitter is selected.
This commit is contained in:
Jimmy Shih
2012-05-15 12:21:14 -07:00
parent af11dac5e0
commit afa2c9875e
25 changed files with 593 additions and 442 deletions
@@ -0,0 +1,51 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
Copyright 2012 Google Inc.
Licensed 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.
-->
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:gravity="center_vertical"
android:layout_height="wrap_content"
android:layout_width="fill_parent"
android:minHeight="?android:attr/listPreferredItemHeight"
android:orientation="horizontal"
android:paddingLeft="16dp"
android:paddingRight="16dp" >
<ImageView
android:contentDescription="@string/icon_application"
android:id="@+id/choose_activity_list_item_icon"
android:layout_height="@android:dimen/app_icon_size"
android:layout_width="@android:dimen/app_icon_size"
android:scaleType="fitCenter" />
<LinearLayout
android:gravity="center_vertical"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:orientation="vertical" >
<TextView
android:id="@+id/choose_activity_list_item_text1"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:maxLines="2"
android:paddingLeft="16dp"
android:textAppearance="?android:attr/textAppearanceListItemSmall" />
<TextView
android:id="@+id/choose_activity_list_item_text2"
android:layout_height="wrap_content"
android:layout_width="wrap_content"
android:maxLines="2"
android:paddingLeft="16dp"
android:textAppearance="?android:attr/textAppearanceSmall" />
</LinearLayout>
</LinearLayout>
@@ -21,7 +21,7 @@ limitations under the License.
android:layout_width="fill_parent"
android:padding="8dp"
android:stretchColumns="1" >
<TableRow android:id="@+id/send_google_maps_row" >
<TableRow>
<ImageView
android:contentDescription="@string/send_google_maps"
android:src="@drawable/google_maps_icon"
@@ -47,7 +47,7 @@ limitations under the License.
style="@style/TextMedium" />
</RadioGroup>
</TableRow>
<TableRow android:id="@+id/send_google_fusion_tables_row" >
<TableRow>
<ImageView
android:contentDescription="@string/send_google_fusion_tables"
android:src="@drawable/google_fusion_tables_icon"
@@ -57,7 +57,7 @@ limitations under the License.
android:text="@string/send_google_fusion_tables"
style="@style/UploadServiceChooserCheckBox" />
</TableRow>
<TableRow android:id="@+id/send_google_docs_row" >
<TableRow>
<ImageView
android:contentDescription="@string/send_google_docs"
android:src="@drawable/google_docs_icon"
-12
View File
@@ -39,18 +39,6 @@ limitations under the License.
android:orderInCategory="4"
android:showAsAction="ifRoom"
android:title="@string/menu_share">
<menu>
<item
android:id="@+id/track_detail_share_map_url"
android:title="@string/menu_share_map_url"/>
<item
android:id="@+id/track_detail_share_fusion_table_url"
android:title="@string/menu_share_fusion_table_url"/>
<item android:id="@+id/track_detail_share_gpx"/>
<item android:id="@+id/track_detail_share_kml"/>
<item android:id="@+id/track_detail_share_csv"/>
<item android:id="@+id/track_detail_share_tcx"/>
</menu>
</item>
<item
android:icon="@drawable/menu_markers"
+1 -2
View File
@@ -39,7 +39,6 @@ limitations under the License.
<string name="min_recording_interval_key">minRecordingInterval</string>
<string name="min_required_accuracy_key">minRequiredAccuracy</string>
<string name="pick_existing_map_key">pickExistingMap</string>
<string name="preferred_account_key">preferredAccount</string>
<string name="recording_track_id_key">recordingTrackId</string>
<string name="report_speed_key">reportSpeed</string>
<string name="selected_track_id_key">selectedTrackId</string>
@@ -47,7 +46,7 @@ limitations under the License.
<string name="send_to_fusion_tables_key">sendToFusionTables</string>
<string name="send_to_maps_key">sendToMaps</string>
<string name="sensor_type_key">sensorType</string>
<string name="share_url_only_key">shareUrlOnly</string>
<string name="sharing_account_key">sharingAccount</string>
<string name="show_check_units_dialog_key">showCheckUnitsDialog</string>
<string name="show_welcome_dialog_key">showWelcomeDialog</string>
<string name="split_frequency_key">splitFrequency</string>
+21 -44
View File
@@ -821,6 +821,12 @@ limitations under the License.
</string>
<!-- Icon -->
<string name="icon_application"
translation_description="When sharing a track, we display a list of Android applications on the
phone that can be used. In the list, we display an application icon for each application. This
is the accessibility description for the icon.">
Application
</string>
<string name="icon_marker"
translation_description="The accessibility description for the 'Marker' icon.">
Marker
@@ -1096,24 +1102,6 @@ limitations under the License.
translation_description="In the menu, to share a track.">
Share
</string>
<string name="menu_share_file"
translation_description="Under the 'Share' menu option, the option to share a track as a
certain file format.
%1$s: file format. 'GPX', 'KML', 'CSV', or 'TCX'.">
%1$s file
</string>
<string name="menu_share_fusion_table_url"
translation_description="Under the 'Share' menu option, the option to save a track to Google
Fusion Tables and share the Fusion Table URL with friends. 'Fusion Table URL' in this context
means a Google Fusion Table URL.">
Fusion Table URL
</string>
<string name="menu_share_map_url"
translation_description="Under the 'Share' menu option, the option to save a track to Google
Maps and share the Map URL with friends. 'Map URL' in this context means a Google Map URL.">
Map URL
</string>
<string name="menu_show_on_map"
translation_description="In the menu, to show a track or a marker on the map.">
Show on map
@@ -1342,11 +1330,6 @@ limitations under the License.
%1$s: service name. 'Google Maps', 'Google Fusion Tables', or 'Google Docs'.">
Sending to %1$s...
</string>
<string name="send_google_result_share_url"
translation_description="When sending a track to Google, in the result dialog, the button on
the bottom to share with friends the URL of the uploaded track.">
Share track URL
</string>
<string name="send_google_send_now"
translation_description="When sending a track to Google, under the 'Send to...' dialog, the
button on the bottom to send the track to the selected Google services.">
@@ -1861,6 +1844,14 @@ limitations under the License.
Character limit: ~26 (1 line)">
Sharing
</string>
<string name="settings_sharing_account"
translation_description="In the 'Sharing' settings, the option to switch account.">
Switch account
</string>
<string name="settings_sharing_account_summary"
translation_description="In the 'Sharing' settings, the summary for 'Switch account'.">
Switch account used when sending a track to Google.
</string>
<string name="settings_sharing_allow_access"
translation_description="In the 'Sharing' settings, the checkbox option to allow third party
apps access to the My Tracks data.
@@ -1907,25 +1898,6 @@ limitations under the License.
be public, as opposed to unlisted.">
Make new maps created in Google Maps public.
</string>
<string name="settings_sharing_url_only"
translation_description="In the 'Sharing' settings, the checkbox option to share only the URL,
without any descriptive text, when sharing a URL with friends.
Character limit: ~23 (1 line)">
Share only URL
</string>
<string name="settings_sharing_url_only_summary_off"
translation_description="In the 'Sharing' settings, the summary for the 'Share only URL'
checkbox option when it is unchecked explaining that it will include descriptive text when
sharing a URL with friends.">
Include descriptive text when sharing a URL with friends.
</string>
<string name="settings_sharing_url_only_summary_on"
translation_description="In the 'Sharing' settings, the summary for the 'Share only URL'
checkbox option when it is checked explaining that it will remove any descriptive text when
sharing a URL with friends.">
Remove any descriptive text when sharing a URL with friends.
</string>
<!-- Settings Split -->
<string name="settings_split_frequency_title"
@@ -2003,8 +1975,13 @@ limitations under the License.
</string>
<string name="share_track_picker_title"
translation_description="When sharing a track URL with friends, the title on the picker to ask
the user which application he wants to use.">
Share track using:
the user to select an application.">
Select an application
</string>
<string name="share_track_share_url"
translation_description="After sending a track to Google, the button on the result dialog to
share the uploaded track URL with friends.">
Share track URL
</string>
<string name="share_track_subject"
translation_description="When sharing a track with friends, the subject line.">
+5 -6
View File
@@ -16,18 +16,17 @@ limitations under the License.
-->
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android"
android:title="@string/settings_sharing" >
<ListPreference
android:defaultValue=""
android:key="@string/sharing_account_key"
android:summary="@string/settings_sharing_account_summary"
android:title="@string/settings_sharing_account" />
<CheckBoxPreference
android:defaultValue="true"
android:key="@string/default_map_public_key"
android:summaryOff="@string/settings_sharing_map_public_summary_off"
android:summaryOn="@string/settings_sharing_map_public_summary_on"
android:title="@string/settings_sharing_map_public" />
<CheckBoxPreference
android:defaultValue="false"
android:key="@string/share_url_only_key"
android:summaryOff="@string/settings_sharing_url_only_summary_off"
android:summaryOn="@string/settings_sharing_url_only_summary_on"
android:title="@string/settings_sharing_url_only" />
<CheckBoxPreference
android:defaultValue="false"
android:key="@string/allow_access_key"