am 94fbf0d8: (-s ours) Import revised translations.  DO NOT MERGE

Merge commit '94fbf0d8089025c1132b25944c98a5491c84ee15' into eclair

* commit '94fbf0d8089025c1132b25944c98a5491c84ee15':
  Import revised translations.  DO NOT MERGE
diff --git a/Android.mk b/Android.mk
index 510f50c..2142def 100644
--- a/Android.mk
+++ b/Android.mk
@@ -8,7 +8,7 @@
 source_files += $(base_packages)/SubscribedFeedsProvider/src/com/android/providers/subscribedfeeds/SubscribedFeedsIntentService.java
 source_files += $(base_packages)/SubscribedFeedsProvider/src/com/android/providers/subscribedfeeds/SubscribedFeedsBroadcastReceiver.java
 
-LOCAL_SRC_FILES := $(call all-subdir-java-files) $(source_files)
+LOCAL_SRC_FILES := $(call all-java-files-under, src) $(source_files)
 
 # We depend on googlelogin-client also, but that is already being included by google-framework
 LOCAL_STATIC_JAVA_LIBRARIES := google-framework
diff --git a/AndroidManifest.xml b/AndroidManifest.xml
index aa768b1..fa99d85 100644
--- a/AndroidManifest.xml
+++ b/AndroidManifest.xml
@@ -3,15 +3,19 @@
         android:sharedUserId="android.uid.system">
 
     <uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
+    <uses-permission android:name="android.permission.USE_CREDENTIALS" />
     <uses-permission android:name="com.google.android.googleapps.permission.GOOGLE_AUTH" />
     <uses-permission android:name="com.google.android.googleapps.permission.GOOGLE_AUTH.cp" />
     <uses-permission android:name="com.google.android.googleapps.permission.GOOGLE_AUTH.cl" />
     <uses-permission android:name="com.google.android.googleapps.permission.GOOGLE_AUTH.mail" />
+    <uses-permission android:name="android.permission.BACKUP" />
     <uses-permission android:name="android.permission.READ_SYNC_SETTINGS" />
     <uses-permission android:name="android.permission.WRITE_SYNC_SETTINGS" />
     <uses-permission android:name="android.permission.READ_SYNC_STATS" />
     <uses-permission android:name="android.permission.SUBSCRIBED_FEEDS_READ" />
     <uses-permission android:name="android.permission.SUBSCRIBED_FEEDS_WRITE" />
+    <uses-permission android:name="android.permission.READ_SYNC_SETTINGS" />
+    <uses-permission android:name="android.permission.WRITE_SYNC_SETTINGS" />
 
     <application android:process="system"
                  android:allowClearUserData="false"
@@ -20,7 +24,16 @@
 
         <uses-library android:name="com.google.android.gtalkservice" />
 
-        <activity android:name="com.android.settings.SyncSettings" android:label="@string/sync_settings">
+        <service android:name="SubscribedFeedsSyncAdapterService" android:exported="true">
+            <intent-filter>
+                <action android:name="android.content.SyncAdapter" />
+            </intent-filter>
+            <meta-data android:name="android.content.SyncAdapter"
+                       android:resource="@xml/syncadapter" />
+        </service>
+
+        <activity android:name="com.android.settings.ManageAccountsSettings"
+            android:label="@string/sync_settings">
             <intent-filter>
                 <action android:name="android.intent.action.MAIN" />
                 <action android:name="android.settings.SYNC_SETTINGS" />
@@ -28,6 +41,35 @@
             </intent-filter>
         </activity>
 
+        <activity android:name="com.android.settings.AccountSyncSettings"
+            android:label="@string/sync_settings"
+            android:theme="@android:style/Theme.NoTitleBar">
+            <intent-filter>
+                <action android:name="android.intent.action.MAIN" />
+                <action android:name="android.settings.ACCOUNT_SYNC_SETTINGS" />
+                <category android:name="android.intent.category.DEFAULT" />
+            </intent-filter>
+        </activity>
+        
+        <activity android:name="com.android.settings.AccountSyncSettingsInAddAccount"
+            android:label="@string/sync_settings"
+            android:theme="@android:style/Theme.NoTitleBar">
+            <intent-filter>
+                <action android:name="android.intent.action.MAIN" />
+                <action android:name="android.settings.ACCOUNT_SYNC_SETTINGS_ADD_ACCOUNT" />
+                <category android:name="android.intent.category.DEFAULT" />
+            </intent-filter>
+        </activity>
+
+        <activity android:name="com.android.settings.AddAccountSettings"
+            android:label="@string/header_add_an_account">
+            <intent-filter>
+                <action android:name="android.intent.action.MAIN" />
+                <action android:name="android.settings.ADD_ACCOUNT_SETTINGS" />
+                <category android:name="android.intent.category.DEFAULT" />
+            </intent-filter>
+        </activity>
+
         <activity android:name="com.android.settings.SyncActivityTooManyDeletes"
                   android:theme="@android:style/Theme.Dialog"
                   android:label="@string/sync_too_many_deletes">
@@ -38,14 +80,15 @@
         </activity>
 
         <provider android:name="GoogleSubscribedFeedsProvider"
-                android:authorities="subscribedfeeds" android:syncable="true"
+                android:authorities="subscribedfeeds"
+                android:label="@string/provider_label"
                 android:multiprocess="false"
                 android:readPermission="android.permission.SUBSCRIBED_FEEDS_READ"
                 android:writePermission="android.permission.SUBSCRIBED_FEEDS_WRITE" />
 
         <receiver android:name="SubscribedFeedsBroadcastReceiver">
             <intent-filter>
-                <action android:name="android.intent.action.GTALK_DATA_MESSAGE_RECEIVED" />
+                <action android:name="android.intent.action.REMOTE_INTENT" />
                 <category android:name="GSYNC_TICKLE"/>
             </intent-filter>
             <intent-filter>
diff --git a/res/drawable-hdpi/app_icon.png b/res/drawable-hdpi/app_icon.png
new file mode 100755
index 0000000..f274432
--- /dev/null
+++ b/res/drawable-hdpi/app_icon.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_btn_next.png b/res/drawable-hdpi/ic_btn_next.png
new file mode 100755
index 0000000..ad00a95
--- /dev/null
+++ b/res/drawable-hdpi/ic_btn_next.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_list_sync_anim0.png b/res/drawable-hdpi/ic_list_sync_anim0.png
new file mode 100755
index 0000000..dc78905
--- /dev/null
+++ b/res/drawable-hdpi/ic_list_sync_anim0.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_list_sync_anim1.png b/res/drawable-hdpi/ic_list_sync_anim1.png
new file mode 100755
index 0000000..5fe6b4f
--- /dev/null
+++ b/res/drawable-hdpi/ic_list_sync_anim1.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_list_sync_anim2.png b/res/drawable-hdpi/ic_list_sync_anim2.png
new file mode 100755
index 0000000..d9d68ed
--- /dev/null
+++ b/res/drawable-hdpi/ic_list_sync_anim2.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_list_sync_anim3.png b/res/drawable-hdpi/ic_list_sync_anim3.png
new file mode 100755
index 0000000..7275c29
--- /dev/null
+++ b/res/drawable-hdpi/ic_list_sync_anim3.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_list_sync_error.png b/res/drawable-hdpi/ic_list_sync_error.png
new file mode 100755
index 0000000..d05146a
--- /dev/null
+++ b/res/drawable-hdpi/ic_list_sync_error.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_sync_green.png b/res/drawable-hdpi/ic_sync_green.png
new file mode 100644
index 0000000..6956088
--- /dev/null
+++ b/res/drawable-hdpi/ic_sync_green.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_sync_grey.png b/res/drawable-hdpi/ic_sync_grey.png
new file mode 100644
index 0000000..3e9995a
--- /dev/null
+++ b/res/drawable-hdpi/ic_sync_grey.png
Binary files differ
diff --git a/res/drawable-hdpi/ic_sync_red.png b/res/drawable-hdpi/ic_sync_red.png
new file mode 100644
index 0000000..5abb707
--- /dev/null
+++ b/res/drawable-hdpi/ic_sync_red.png
Binary files differ
diff --git a/res/drawable-hdpi/title_bar.9.png b/res/drawable-hdpi/title_bar.9.png
new file mode 100755
index 0000000..e8ff1f8
--- /dev/null
+++ b/res/drawable-hdpi/title_bar.9.png
Binary files differ
diff --git a/res/drawable/app_icon.png b/res/drawable-mdpi/app_icon.png
similarity index 100%
rename from res/drawable/app_icon.png
rename to res/drawable-mdpi/app_icon.png
Binary files differ
diff --git a/res/drawable-mdpi/ic_btn_next.png b/res/drawable-mdpi/ic_btn_next.png
new file mode 100755
index 0000000..c6cf436
--- /dev/null
+++ b/res/drawable-mdpi/ic_btn_next.png
Binary files differ
diff --git a/res/drawable/ic_list_sync_anim0.png b/res/drawable-mdpi/ic_list_sync_anim0.png
similarity index 100%
rename from res/drawable/ic_list_sync_anim0.png
rename to res/drawable-mdpi/ic_list_sync_anim0.png
Binary files differ
diff --git a/res/drawable/ic_list_sync_anim1.png b/res/drawable-mdpi/ic_list_sync_anim1.png
similarity index 100%
rename from res/drawable/ic_list_sync_anim1.png
rename to res/drawable-mdpi/ic_list_sync_anim1.png
Binary files differ
diff --git a/res/drawable/ic_list_sync_anim2.png b/res/drawable-mdpi/ic_list_sync_anim2.png
similarity index 100%
rename from res/drawable/ic_list_sync_anim2.png
rename to res/drawable-mdpi/ic_list_sync_anim2.png
Binary files differ
diff --git a/res/drawable/ic_list_sync_anim3.png b/res/drawable-mdpi/ic_list_sync_anim3.png
similarity index 100%
rename from res/drawable/ic_list_sync_anim3.png
rename to res/drawable-mdpi/ic_list_sync_anim3.png
Binary files differ
diff --git a/res/drawable-mdpi/ic_sync_green.png b/res/drawable-mdpi/ic_sync_green.png
new file mode 100644
index 0000000..177a024
--- /dev/null
+++ b/res/drawable-mdpi/ic_sync_green.png
Binary files differ
diff --git a/res/drawable-mdpi/ic_sync_grey.png b/res/drawable-mdpi/ic_sync_grey.png
new file mode 100644
index 0000000..8f168d4
--- /dev/null
+++ b/res/drawable-mdpi/ic_sync_grey.png
Binary files differ
diff --git a/res/drawable-mdpi/ic_sync_red.png b/res/drawable-mdpi/ic_sync_red.png
new file mode 100644
index 0000000..5e38136
--- /dev/null
+++ b/res/drawable-mdpi/ic_sync_red.png
Binary files differ
diff --git a/res/drawable-mdpi/title_bar.9.png b/res/drawable-mdpi/title_bar.9.png
new file mode 100644
index 0000000..4c78d2d
--- /dev/null
+++ b/res/drawable-mdpi/title_bar.9.png
Binary files differ
diff --git a/res/layout/account_preference.xml b/res/layout/account_preference.xml
new file mode 100644
index 0000000..a3a9d43
--- /dev/null
+++ b/res/layout/account_preference.xml
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2009 The Android Open Source Project
+
+     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:layout_width="fill_parent"
+    android:layout_height="wrap_content"
+    android:minHeight="?android:attr/listPreferredItemHeight"
+    android:gravity="center_vertical"
+    android:paddingLeft="16dip"
+    android:paddingRight="?android:attr/scrollbarSize">
+
+    <ImageView
+        android:id="@+id/providerIcon"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginRight="5dip"
+        android:layout_gravity="center" />
+
+    <RelativeLayout
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginRight="6dip"
+        android:layout_marginTop="6dip"
+        android:layout_marginBottom="6dip"
+        android:layout_weight="1">
+
+        <TextView android:id="@+android:id/title"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:singleLine="true"
+            android:textAppearance="?android:attr/textAppearanceMedium" />
+
+        <TextView android:id="@+android:id/summary"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_below="@android:id/title"
+            android:layout_alignLeft="@android:id/title"
+            android:textAppearance="?android:attr/textAppearanceSmall"
+            android:maxLines="2" />
+
+    </RelativeLayout>
+
+    <ImageView
+        android:id="@+id/syncStatusIcon"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginLeft="5dip"
+        android:layout_marginRight="7dip"
+        android:layout_gravity="center" />
+
+</LinearLayout>
diff --git a/res/layout/account_sync_screen.xml b/res/layout/account_sync_screen.xml
new file mode 100644
index 0000000..4409acb
--- /dev/null
+++ b/res/layout/account_sync_screen.xml
@@ -0,0 +1,84 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/* //device/apps/common/assets/res/layout/list_content.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** 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:layout_width="fill_parent"
+    android:layout_height="fill_parent"
+    android:orientation="vertical">
+
+    <include layout="@layout/title"
+        android:layout_width="fill_parent"
+        android:layout_height="wrap_content" />
+
+    <ListView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@android:id/list"
+        android:layout_width="fill_parent"
+        android:layout_height="0dip"
+        android:layout_weight="1"
+        android:drawSelectorOnTop="false"
+        android:scrollbarAlwaysDrawVerticalTrack="true"
+    />
+
+    <TextView android:id="@+id/sync_settings_error_info"
+        android:layout_width="fill_parent"
+        android:layout_height="wrap_content"
+        android:text="@string/sync_is_failing" />
+
+    <LinearLayout android:id="@+id/remove_account_area"
+        android:layout_width="fill_parent"
+        android:layout_height="wrap_content"
+        android:orientation="horizontal"
+        android:background="@android:drawable/bottom_bar">
+
+        <View
+            android:layout_width="0dip"
+            android:layout_height="fill_parent"
+            android:layout_weight="1"/>
+
+        <Button android:id="@+id/remove_account_button"
+            android:layout_width="0dip"
+            android:layout_height="wrap_content"
+            android:layout_weight="2"
+            android:layout_marginTop="5dip"
+            android:text="@string/remove_account_label" />
+
+        <View
+            android:layout_width="0dip"
+            android:layout_height="fill_parent"
+            android:layout_weight="1"/>
+    </LinearLayout>
+    
+    <RelativeLayout android:id="@+id/finish_button_area"
+        android:layout_height="wrap_content"
+        android:layout_width="fill_parent"
+        android:background="@android:drawable/bottom_bar"
+        android:visibility="gone">
+        
+        <Button android:id="@+id/finish_button"
+            android:layout_width="150dip"
+            android:layout_height="wrap_content"
+            android:layout_margin="5dip"
+            android:layout_alignParentRight="true"
+            android:drawableRight="@drawable/ic_btn_next"
+            android:drawablePadding="3dip"
+            android:text="@string/finish_button_label"
+        />
+        
+    </RelativeLayout>
+
+</LinearLayout>
diff --git a/res/layout/sync_settings_list_content.xml b/res/layout/add_account_screen.xml
similarity index 61%
rename from res/layout/sync_settings_list_content.xml
rename to res/layout/add_account_screen.xml
index 9573d36..8d4be3d 100644
--- a/res/layout/sync_settings_list_content.xml
+++ b/res/layout/add_account_screen.xml
@@ -18,18 +18,16 @@
 */
 -->
 <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
-  android:layout_width="fill_parent"
-  android:layout_height="fill_parent"
-  android:orientation="vertical">
-  <ListView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@android:id/list"
     android:layout_width="fill_parent"
-    android:layout_height="0dip"
-    android:layout_weight="1"
-    android:drawSelectorOnTop="false"
-    android:scrollbarAlwaysDrawVerticalTrack="true"
+    android:layout_height="fill_parent"
+    android:orientation="vertical">
+
+    <ListView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@android:id/list"
+        android:layout_width="fill_parent"
+        android:layout_height="0dip"
+        android:layout_weight="1"
+        android:drawSelectorOnTop="false"
+        android:scrollbarAlwaysDrawVerticalTrack="true"
     />
-  <TextView android:id="@+id/sync_settings_error_info"
-    android:layout_width="fill_parent"
-    android:layout_height="wrap_content"
-    android:text="@string/sync_is_failing" />
+
 </LinearLayout>
diff --git a/res/layout/manage_accounts_screen.xml b/res/layout/manage_accounts_screen.xml
new file mode 100644
index 0000000..55e8d22
--- /dev/null
+++ b/res/layout/manage_accounts_screen.xml
@@ -0,0 +1,62 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/* //device/apps/common/assets/res/layout/list_content.xml
+**
+** Copyright 2006, The Android Open Source Project
+**
+** 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:layout_width="fill_parent"
+    android:layout_height="fill_parent"
+    android:orientation="vertical">
+
+    <ListView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@android:id/list"
+        android:layout_width="fill_parent"
+        android:layout_height="0dip"
+        android:layout_weight="1"
+        android:drawSelectorOnTop="false"
+        android:scrollbarAlwaysDrawVerticalTrack="true"
+    />
+
+    <TextView android:id="@+id/sync_settings_error_info"
+        android:layout_width="fill_parent"
+        android:layout_height="wrap_content"
+        android:text="@string/sync_is_failing" />
+
+    <LinearLayout
+        android:layout_width="fill_parent"
+        android:layout_height="wrap_content"
+        android:orientation="horizontal"
+        android:background="@android:drawable/bottom_bar">
+
+        <View
+            android:layout_width="0dip"
+            android:layout_height="fill_parent"
+            android:layout_weight="1"/>
+
+        <Button android:id="@+id/add_account_button"
+            android:layout_width="0dip"
+            android:layout_height="wrap_content"
+            android:layout_weight="2"
+            android:layout_marginTop="5dip"
+            android:text="@string/add_account_label" />
+
+        <View
+            android:layout_width="0dip"
+            android:layout_height="fill_parent"
+            android:layout_weight="1"/>
+    </LinearLayout>
+
+</LinearLayout>
diff --git a/res/layout/provider_preference.xml b/res/layout/provider_preference.xml
new file mode 100644
index 0000000..3daaf30
--- /dev/null
+++ b/res/layout/provider_preference.xml
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2009 The Android Open Source Project
+
+     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:layout_width="fill_parent"
+    android:layout_height="wrap_content"
+    android:minHeight="?android:attr/listPreferredItemHeight"
+    android:gravity="center_vertical"
+    android:paddingLeft="16dip"
+    android:paddingRight="?android:attr/scrollbarSize">
+
+    <ImageView
+        android:id="@+id/providerIcon"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginRight="5dip"
+        android:layout_gravity="center" />
+
+    <RelativeLayout
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginRight="6dip"
+        android:layout_marginTop="6dip"
+        android:layout_marginBottom="6dip"
+        android:layout_weight="1">
+
+        <TextView android:id="@+android:id/title"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:singleLine="true"
+            android:textAppearance="?android:attr/textAppearanceMedium" />
+
+        <TextView android:id="@+android:id/summary"
+            android:layout_width="wrap_content"
+            android:layout_height="wrap_content"
+            android:layout_below="@android:id/title"
+            android:layout_alignLeft="@android:id/title"
+            android:textAppearance="?android:attr/textAppearanceSmall"
+            android:maxLines="2" />
+
+    </RelativeLayout>
+
+    <ImageView
+        android:id="@+id/syncStatusIcon"
+        android:layout_width="wrap_content"
+        android:layout_height="wrap_content"
+        android:layout_marginLeft="5dip"
+        android:layout_gravity="center" />
+
+</LinearLayout>
diff --git a/res/layout/title.xml b/res/layout/title.xml
new file mode 100644
index 0000000..85efdd3
--- /dev/null
+++ b/res/layout/title.xml
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/**
+ * Copyright (C) 2009 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.
+ */
+-->
+
+<!-- The title area at the top of the screen -->
+
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
+    android:id="@+id/title_area"
+    android:orientation="horizontal"
+    android:background="@drawable/title_bar">
+
+    <ImageView android:id="@+id/provider_icon"
+        android:layout_width="48dip"
+        android:layout_height="48dip"
+        android:layout_margin="5dip"
+        android:layout_gravity="center_vertical" />
+
+    <LinearLayout
+        android:layout_width="0dip"
+        android:layout_weight="1"
+        android:layout_height="wrap_content"
+        android:orientation="vertical"
+        android:background="@drawable/title_bar">
+
+        <TextView
+            android:id="@+id/user_id"
+            android:layout_width="fill_parent"
+            android:layout_height="wrap_content"
+            android:textAppearance="?android:attr/textAppearanceMedium"
+            android:textStyle="bold"
+            android:singleLine="true"
+            android:ellipsize="end"
+            android:gravity="center_vertical"
+            android:layout_marginTop="5dip"/>
+
+        <TextView
+            android:id="@+id/provider_id"
+            android:layout_width="fill_parent"
+            android:layout_height="wrap_content"
+            android:textAppearance="?android:attr/textAppearanceSmall"
+            android:singleLine="true"
+            android:ellipsize="end"
+            android:layout_gravity="bottom"
+            android:layout_marginBottom="5dip"/>
+
+    </LinearLayout>
+
+</LinearLayout>
diff --git a/res/values-cs/strings.xml b/res/values-cs/strings.xml
index 7fc9970..52927b2 100644
--- a/res/values-cs/strings.xml
+++ b/res/values-cs/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Synchronizace zdrojů"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Synchronizace dat"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Byl překročen limit mazání."</string>
     <string name="background_data" msgid="1103557117473896066">"Data na pozadí"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Povolit používání dat na pozadí"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"Zakázání dat na pozadí šetří baterii a snižuje objem použitých dat. Některé aplikace mohou přesto datové připojení na pozadí používat."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Automatická synchronizace"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Data jsou synchronizována automaticky"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Zálohovat nastavení"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Aktivovat zálohování nastavení"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Synchronizovat nyní"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Zrušit synchronizaci"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Synchronizovat nyní<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"Nastaly potíže se synchronizací. Služba bude brzy obnovena."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Vítá vás aplikace Google Sync"</font>" "\n"Nový pohled na synchronizaci dat v režii Google. Poskytuje vám přístup ke kontaktům, schůzkám a dalším náležitostem, ať jste kdekoli."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Nastavení synchronizace aplikací"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Obecná nastavení synchronizace"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Přidat účet"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Data a synchronizace"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Změnit heslo"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Nastavení účtu"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Odebrat účet"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Přidat účet"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Dokončit"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Odebrat účet"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Chcete tento účet skutečně odebrat? Spolu s účtem budou odebrána také všechna k němu přidružená data. "\n"Pokračovat?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Tento účet nelze odebrat."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Zobrazit odběry"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Synchronizace služby <xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-da/strings.xml b/res/values-da/strings.xml
index ba5dd18..684f988 100644
--- a/res/values-da/strings.xml
+++ b/res/values-da/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Synkroniser feeds"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Datasynkronisering"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Grænsen for sletning er overskredet"</string>
     <string name="background_data" msgid="1103557117473896066">"Baggrundsdata"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Aktiver baggrundsdatabrug"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"Deaktivering af baggrundsdata sparer på batteriet og mindsker databrug. Nogle programmer kan muligvis stadig bruge baggrundsdataforbindelsen."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Autom. synkronisering"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Synkroniser automatisk data"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Sikkerhedskopiér indstillinger"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Aktiver sikkerhedskopiering af indstillinger"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Synkroniser nu"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Annuller synkronisering"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Vælg at synkronisere nu<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"Der er problemer med synkronisering i øjeblikket. Det vender snart tilbage."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Velkommen til Google Sync!"</font>" "\n"En tilgang til synkronisering af data fra Google, hvilket lader dig få adgang til dine kontakter, aftaler og mere, uanset hvor du er."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Indstillinger for programsynkronisering"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Generelle synkroniseringsindstillinger"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Tilføj konto"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Data og synkronisering"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Skift adgangskode"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Kontoindstillinger"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Fjern konto"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Tilføj en konto"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Afslut"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Fjern konto"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Er du sikker på, at du vil fjerne denne konto? Hvis du fjerner den, fjernes alle data, der er knyttet til kontoen. "\n"Vil du fortsætte?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Denne konto kunne ikke fjernes."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Push-abonnementer"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Synkroniser<xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-de/strings.xml b/res/values-de/strings.xml
index a89b482..8866d55 100644
--- a/res/values-de/strings.xml
+++ b/res/values-de/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Feedsynchronisierung"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Datensynchronisierung"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Löschbegrenzung überschritten"</string>
     <string name="background_data" msgid="1103557117473896066">"Hintergrunddaten"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Verwendung von Hintergrunddaten aktivieren"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"Durch die Deaktivierung von Hintergrunddaten kann Strom gespart und die Verwendung von Daten verringert werden. Einige Anwendungen nutzen die Hintergrunddatenverbindung möglicherweise weiterhin."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Autom. synchronisieren"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Daten automatisch synchronisieren"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Einstellungen sichern"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Sicherung der Einstellungen aktivieren"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Jetzt synchronisieren"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Synchronisierung abbrechen"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Jetzt synchronisieren: <xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"Bei der Synchronisierung treten derzeit Probleme auf. Sie wird in Kürze fortgesetzt."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Willkommen bei Google Sync!"</font>\n"Mit dieser Funktion von Google können Sie Ihre Daten synchronisieren, um auf Ihre Kontakte, Termine und vieles mehr zuzugreifen - wo immer Sie auch sind!"</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Anwendungssynchronisierung"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Allgemeine Synchronisierungseinstellungen"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Konto hinzufügen"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Daten und Synchronisierung"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Passwort ändern"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Kontoeinstellungen"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Konto entfernen"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Konto hinzufügen"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Fertigstellen"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Konto entfernen"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Möchten Sie dieses Konto wirklich entfernen? Hierdurch werden alle mit dem Konto verknüpften Daten gelöscht. "\n"Vorgang fortsetzen?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Dieses Konto konnte nicht entfernt werden."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Push-Abos"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"<xliff:g id="AUTHORITY">%s</xliff:g> synchronisieren"</string>
 </resources>
diff --git a/res/values-el/strings.xml b/res/values-el/strings.xml
index c5a1795..ef3da66 100644
--- a/res/values-el/strings.xml
+++ b/res/values-el/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Συγχρονισμός ροών δεδομένων"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Συγχρονισμός δεδομένων"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Έγινε υπέρβαση του ορίου διαγραφής."</string>
     <string name="background_data" msgid="1103557117473896066">"Δεδομένα φόντου"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Ενεργοποίηση χρήσης δεδομένων φόντου"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"Η απενεργοποίηση δεδομένων φόντου εξοικονομεί ενέργεια μπαταρίας και μειώνει τη χρήση δεδομένων. Ορισμένες εφαρμογές ενδέχεται να συνεχίσουν να χρησιμοποιούν τη σύνδεση δεδομένων φόντου."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Αυτόματος συγχρονισμός"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Αυτόματος συγχρονισμός δεδομένων"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Δημιουργία αντιγράφων ασφαλείας για τις ρυθμίσεις"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Ενεργοποίηση της δημιουργίας αντιγράφων ασφαλείας των ρυθμίσεων"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Να γίνει συγχρονισμός τώρα"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Ακύρωση συγχρονισμού"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Επιλέξτε για συγχρονισμό τώρα<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"Το Sync αντιμετωπίζει προβλήματα αυτή τη στιγμή. Θα είναι διαθέσιμο ξανά σε λίγο."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Καλώς ορίσατε στο Google Sync!"</font>" "\n"Μια προσέγγιση της Google στον συγχρονισμό δεδομένων ώστε να αποκτήσετε πρόσβαση στις επαφές σας, στις συναντήσεις σας και σε άλλα, οπουδήποτε κι αν είστε."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Ρυθμίσεις συγχρονισμού εφαρμογής"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Γενικές ρυθμίσεις συγχρονισμού"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Προσθήκη λογαριασμού"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Δεδομένα και συγχρονισμός"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Αλλαγή κωδικού πρόσβασης"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Ρυθμίσεις λογαριασμού"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Κατάργηση λογαριασμού"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Προσθήκη λογαριασμού"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Τέλος"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Κατάργηση λογαριασμού"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Θέλετε σίγουρα να καταργήσετε αυτόν τον λογαριασμό; Η κατάργησή του θα καταργήσει και όλα τα δεδομένα που σχετίζονται με τον λογαριασμό. "\n"Συνέχεια;"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Δεν ήταν δυνατή η κατάργηση αυτού του λογαριασμού."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Προώθηση συνδρομών"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Συγχρονισμός εφαρμογής <xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-es-rUS/strings.xml b/res/values-es-rUS/strings.xml
index 6300c8d..bccc68c 100644
--- a/res/values-es-rUS/strings.xml
+++ b/res/values-es-rUS/strings.xml
@@ -15,18 +15,20 @@
 -->
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
-    <string name="app_label" msgid="2800463760279909883">"Canales de sincronización"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Sincronización de datos"</string>
+    <string name="app_label" msgid="569000083919693222">"Canales de sincronización"</string>
+    <string name="sync_settings" msgid="8707056705985552604">"Configuración de cuentas y sincronización"</string>
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Eliminar el límite excedido"</string>
     <string name="background_data" msgid="1103557117473896066">"Datos de fondo"</string>
-    <string name="background_data_summary" msgid="4689952168187153486">"Activar el uso de datos de fondo"</string>
+    <string name="background_data_summary" msgid="9048259510387973822">"Las aplicaciones se pueden sincronizar, enviar y pueden recibir datos en cualquier momento"</string>
     <string name="background_data_dialog_title" msgid="6303755495467986079">"Atención"</string>
-    <string name="background_data_dialog_message" msgid="2817489591533703840">"Al desactivar los datos de fondo, se ahorra batería y se reduce el uso de los datos. Algunas aplicaciones incluso pueden utilizar una conexión de datos de fondo."</string>
+    <string name="background_data_dialog_message" msgid="8417297954700022363">"Al desactivar los datos de fondo, se prolonga la vida útil de la batería y se reduce el uso de los datos. Algunas aplicaciones incluso pueden utilizar una conexión de datos de fondo."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Sincroniz. automática"</string>
-    <string name="sync_automatically_summary" msgid="6210073947698673774">"Datos sincronizados automáticamente"</string>
+    <string name="sync_automatically_summary" msgid="4598895616781542745">"Las aplicaciones sincronizan los datos automáticamente."</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Hacer una copia de seguridad de configuraciones"</string>
+    <string name="settings_backup_summary" msgid="1787552172618610178">"Hacer una copia de seguridad de mi configuración"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Sincronizar ahora"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Cancelar sincronización"</string>
-    <string name="sync_one_time_sync" msgid="3474532720071919514">"Selecciona sincronización ahora<xliff:g id="LAST_SYNC_TIME">
+    <string name="sync_one_time_sync" msgid="3274364877518422827">"Tocar para sincronizar ahora<xliff:g id="LAST_SYNC_TIME">
 %1$s</xliff:g>"</string>
     <string name="sync_gmail" msgid="5806053858668452000">"Gmail"</string>
     <string name="sync_calendar" msgid="1796292773734071897">"Calendario"</string>
@@ -36,7 +38,25 @@
     <string name="sync_undo_deletes" msgid="8695514459839593307">"Deshacer eliminaciones."</string>
     <string name="sync_do_nothing" msgid="5798755982392201673">"No hagas nada por el momento."</string>
     <string name="sync_is_failing" msgid="5230237058552433773">"En este momento la sincronización experimenta problemas. Volverá en breve."</string>
-    <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"¡Bienvenido a\nGoogle Sync!"</font>" "\n"Un método de Google que sincroniza datos para permitir el acceso a tus contactos, citas y mucho más desde cualquier lugar en donde estés."</string>
+    <string name="sync_plug" msgid="7020432439004167162"><font fgcolor="#ffffffff">"¡Bienvenido a\nGoogle sync!"</font>" "\n"Un método de Google que sincroniza datos para permitir el acceso a tus contactos, citas y mucho más desde cualquier lugar en donde estés."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Config. de sincroniz. de la aplic."</string>
+    <string name="header_manage_accounts" msgid="381956296995298770">"Administrar cuentas"</string>
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Configuración de sincronización general"</string>
+    <string name="sync_enabled" msgid="913018877443997502">"Sincronización activada"</string>
+    <string name="sync_disabled" msgid="185731301298967302">"Sincronización desactivada"</string>
+    <string name="sync_error" msgid="681431702824599812">"Error de sincronización"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Agregar cuenta"</string>
+    <string name="header_data_and_synchronization" msgid="6286257845276834071">"Sincronización y datos"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Cambiar contraseña"</string>
+    <string name="header_account_settings" msgid="4950809499418403792">"Configuración de la cuenta"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Eliminar cuenta"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Agregar una cuenta"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Finalizar"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Eliminar cuenta"</string>
+    <string name="really_remove_account_message" msgid="3293445755620109578">"¿Realmente deseas eliminar·esta cuenta? Si lo haces, también suprimirás todos sus mensajes, contactos y otros datos del teléfono. "\n"¿Deseas continuar?"</string>
+    <string name="remove_account_failed" msgid="8178924513521241001">"Algunas aplicaciones requieren esta cuenta. Sólo puedes suprimirla si restableces la configuración predeterminada de fábrica en el teléfono (la cual suprime todos tus datos personales). Puedes hacerlo en la aplicación Configuración, dentro de Privacidad."</string>
+    <string name="provider_label" msgid="6191617139291321517">"Suscripciones de inserción"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Sincronización<xliff:g id="AUTHORITY">%s</xliff:g>"</string>
+    <string name="cant_sync_dialog_title" msgid="3016197392261471761">"No se puede realizar la sincronización manual"</string>
+    <string name="cant_sync_dialog_message" msgid="7200115394296632300">"La sincronización de este elemento actualmente está desactivada. Para cambiar tus preferencias, activa momentáneamente los datos de fondo y la sincronización automática."</string>
 </resources>
diff --git a/res/values-es/strings.xml b/res/values-es/strings.xml
index eecb893..80a2f4b 100644
--- a/res/values-es/strings.xml
+++ b/res/values-es/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Sincronización de feeds"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Sincronización de datos"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Límite de eliminaciones superado"</string>
     <string name="background_data" msgid="1103557117473896066">"Datos de referencia"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Habilitar el uso de datos de referencia"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"Si inhabilitas los datos de referencia, ahorrarás batería y reducirás el uso de datos. Es posible que algunas aplicaciones sigan utilizando la conexión de datos de referencia."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Sincronización automática"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Sincronizar datos de forma automática"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Realizar copia de seguridad de configuración"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Habilitar copia de seguridad de configuración"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Sincronizar ahora"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Cancelar sincronización"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Seleccionar para realizar la sincronización ahora<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"En este momento hay problemas con la sincronización. Se restablecerá en breve."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Te damos la bienvenida a Google Sync."</font>" "\n"Un servicio de Google para sincronizar datos y permitir así el acceso a tus contactos, citas, etc. desde cualquier ubicación."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Configuración de sincronización de aplicación"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Configuración de sincronización general"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Añadir cuenta"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Datos y sincronización"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Cambiar contraseña"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Configuración de la cuenta"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Eliminar cuenta"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Añadir una cuenta"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Finalizar"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Eliminar cuenta"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"¿Realmente quieres eliminar esta cuenta? Si la eliminas, se eliminarán todos los datos asociados a ella. "\n"¿Quieres continuar?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Esta cuenta no se ha podido eliminar."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Enviar suscripciones"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Sincronizar <xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-fr/strings.xml b/res/values-fr/strings.xml
index 5d6fd8c..36ae922 100644
--- a/res/values-fr/strings.xml
+++ b/res/values-fr/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Synchronisation des flux"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Synchronisation"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Le nombre maximum de suppressions a été atteint."</string>
     <string name="background_data" msgid="1103557117473896066">"Données en arrière-plan"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Activer l\'utilisation des données en arrière-plan"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"La désactivation des données en arrière-plan permet d\'économiser la batterie et de réduire l\'utilisation des données. Certaines applications peuvent utiliser la connexion des données en arrière-plan."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Synchronisation auto"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Synchronisation automatique des données"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Sauvegarder les paramètres"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Activer la sauvegarde des paramètres"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Synchroniser maintenant"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Annuler la synchronisation"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Synchroniser maintenant <xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"La synchronisation rencontre actuellement des problèmes. Elle sera rétablie sous peu."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Bienvenue sur Google Sync !"</font>" "\n"Une approche Google pour synchroniser vos données afin de vous permettre l\'accès à vos contacts, rendez-vous et plus encore, où que vous vous trouviez."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Paramètres des applications"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Paramètres généraux"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Ajouter un compte"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Données et synchronisation"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Modifier le mot de passe"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Paramètres de compte"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Supprimer le compte"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Ajouter un compte"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Terminer"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Supprimer le compte"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Souhaitez-vous vraiment supprimer ce compte ? Sa suppression entraînera également la suppression de toutes les données associées au compte. "\n"Continuer ?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Impossible de supprimer ce compte."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Abonnements Push"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Synchroniser <xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-it/strings.xml b/res/values-it/strings.xml
index 43ece11..0aaf801 100644
--- a/res/values-it/strings.xml
+++ b/res/values-it/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Sincronizzazione feed"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Sincronizzazione dati"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Limite di eliminazioni superato"</string>
     <string name="background_data" msgid="1103557117473896066">"Dati in background"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Attiva utilizzo dei dati in background"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"La disattivazione dei dati in background consente di ridurre il consumo delle batterie e l\'utilizzo dei dati. Alcune applicazioni potrebbero utilizzare comunque la connessione dati in background."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Sincronizz. automatica"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Sincronizza i dati automaticamente"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Backup impostazioni"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Attiva il backup delle impostazioni"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Sincronizza ora"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Annulla sincronizzazione"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Seleziona per sincronizzare ora<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"La sincronizzazione presenta dei problemi. L\'operazione verrà ripristinata a breve."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Benvenuto in Google Sync."</font>" "\n"L\'approccio di Google alla sincronizzazione di dati per consentirti l\'accesso ai tuoi contatti, appuntamenti e altro ancora, dovunque tu sia."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Impostazioni sincronizzazione applicazioni"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Impostazioni generali di sincronizzazione"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Aggiungi account"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Dati e sincronizzazione"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Cambia password"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Impostazioni account"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Rimuovi account"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Aggiungi un account"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Fine"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Rimuovi account"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Vuoi davvero rimuovere questo account? Se lo rimuovi verranno rimossi anche tutti i dati associati. "\n"Continuare?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Impossibile rimuovere questo account."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Sottoscrizioni push"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Sincronizza <xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-ja/strings.xml b/res/values-ja/strings.xml
index be494cc..3c0d294 100644
--- a/res/values-ja/strings.xml
+++ b/res/values-ja/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"フィードの同期"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"データの同期"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"削除の制限を超えました"</string>
     <string name="background_data" msgid="1103557117473896066">"バックグラウンドデータ"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"バックグラウンドデータの使用を有効にする"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"バックグラウンドデータを無効にすると、データの使用が減るため電池を節約できます。一部のアプリケーションでは引き続きバックグラウンドデータの接続を使用します。"</string>
     <string name="sync_automatically" msgid="4694735102757960100">"自動同期"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"自動的にデータを同期する"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"設定をバックアップ"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"設定のバックアップを有効にする"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"今すぐ同期"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"同期をキャンセル"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"今すぐ同期を選択<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"現在同期で問題が発生しています。しばらくお待ちください。"</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Google Syncへようこそ"</font>" "\n"このサービスを使用すると、データを同期してどこからでも連絡先や予定などにアクセスできます。"</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"アプリケーションの同期設定"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"同期の基本設定"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"アカウントを追加"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"データと同期"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"パスワードを変更"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"アカウントの設定"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"アカウントを削除"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"アカウントを追加"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"完了"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"アカウントを削除"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"このアカウントを削除してよろしいですか?削除すると、アカウントに関連するすべてのデータが削除されます。"\n"続けますか?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"このアカウントを削除できませんでした。"</string>
+    <string name="provider_label" msgid="4860292144158484350">"プッシュ型登録"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"<xliff:g id="AUTHORITY">%s</xliff:g>を同期"</string>
 </resources>
diff --git a/res/values-ko/strings.xml b/res/values-ko/strings.xml
index d598ecc..720e9cc 100644
--- a/res/values-ko/strings.xml
+++ b/res/values-ko/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"피드 동기화"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"데이터 동기화"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"삭제 한도를 초과했습니다."</string>
     <string name="background_data" msgid="1103557117473896066">"배경 데이터"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"배경 데이터 사용 설정"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"배경 데이터를 사용하지 않도록 설정하면 배터리가 절약되고 데이터 사용률이 낮아집니다. 일부 응용프로그램은 여전히 배경 데이터 연결을 사용할 수 있습니다."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"자동 동기화"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"자동으로 데이터 동기화"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"설정 백업"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"설정 백업 사용"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"지금 동기화"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"동기화 취소"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"지금 동기화하도록 선택(마지막 동기화: <xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"동기화에 현재 문제가 발생했습니다. 곧 다시 동기화됩니다."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Google 동기화를 시작합니다."</font>" "\n"사용자가 어디에서든지 주소록, 일정 등에 액세스할 수 있도록 데이터를 동기화하는 방법입니다."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"응용프로그램 동기화 설정"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"기본 동기화 설정"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"계정 추가"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"데이터 및 동기화"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"비밀번호 변경"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"계정 설정"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"계정 삭제"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"계정 추가"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"마침"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"계정 삭제"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"계정을 삭제하시겠습니까? 계정을 삭제하면 계정과 연결된 모든 데이터가 삭제됩니다. "\n"계속하시겠습니까?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"이 계정을 삭제할 수 없습니다."</string>
+    <string name="provider_label" msgid="4860292144158484350">"구독정보 푸시"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"<xliff:g id="AUTHORITY">%s</xliff:g> 동기화"</string>
 </resources>
diff --git a/res/values-nb/strings.xml b/res/values-nb/strings.xml
index 82c890d..4e993a8 100644
--- a/res/values-nb/strings.xml
+++ b/res/values-nb/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Strømsynkronisering"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Datasynkronisering"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Grensen for sletting nådd"</string>
     <string name="background_data" msgid="1103557117473896066">"Bakgrunnsdata"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Slå på bruk av bakgrunnsdata"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"Det å slå av bakgrunnsdata sparer batteri og reduserer datatrafikken. Noen applikasjoner kan fortsatt bruke tilkoblingen for bakgrunnsdata."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Autosynk"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Synkroniser data automatisk"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Sikkerhetskopier innstillinger"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Aktiver sikkerhetskopiering av innstillinger"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Synkroniser nå"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Avbryt synkronisering"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Velg for å synkronisere nå<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"Det er midlertidige problemer med synkroniseringen. Vent litt."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Velkommen til Google-synkronisering!"</font>" "\n"En Google-løsning for å synkronisere data så du får tilgang til kontakter, avtaler og mer uansett hvor du er."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Synkronisering av applikasjoner"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Generelle synkroniseringsinnstillinger"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Legg til konto"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Data og synkronisering"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Endre passord"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Kontoinnstillinger"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Fjern konto"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Legg til en konto"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Fullfør"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Fjern konto"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Er du sikker på at du vil fjerne denne kontoen? Hvis du fjerner den, fjernes samtidig alle data som er tilknyttet kontoen. "\n"Vil du fortsette?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Kunne ikke fjerne denne kontoen."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Push-abonnementer"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Synkroniser <xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-nl/strings.xml b/res/values-nl/strings.xml
index ac215e9..f798709 100644
--- a/res/values-nl/strings.xml
+++ b/res/values-nl/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Feeds synchroniseren"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Gegevenssynchronisatie"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Verwijderingslimiet overschreden"</string>
     <string name="background_data" msgid="1103557117473896066">"Achtergrondgegevens"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Gebruik van achtergrondgegevens inschakelen"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"Als u achtergrondgegevens uitschakelt, bespaart u batterijlading en wordt het gegevensverbruik verlaagd. Sommige toepassingen maken mogelijk nog steeds gebruik van de achtergrondgegevensverbinding."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Automatische synchronisatie"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Gegevens automatisch synchroniseren"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Back-up van instellingen maken"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Back-up maken van instellingen inschakelen"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Nu synchroniseren"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Synchronisatie annuleren"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Selecteren om nu te synchroniseren<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"Er zijn momenteel problemen met de synchronisatie. Synchronisatie wordt snel opnieuw uitgevoerd."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Welkom bij Google Sync!"</font>" "\n"Een benadering van Google voor de synchronisatie van gegevens, zodat u altijd en overal toegang heeft tot uw contacten, afspraken en nog veel meer."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Synchronisatie-instellingen toepassing"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Algemene instellingen voor synchronisatie"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Account toevoegen"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Gegevens en synchronisatie"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Wachtwoord wijzigen"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Accountinstellingen"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Account verwijderen"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Een account toevoegen"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Voltooien"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Account verwijderen"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Weet u zeker dat u dit account wilt verwijderen? Als u het verwijdert, worden alle gegevens die aan dit account zijn gekoppeld, ook verwijderd. "\n"Wilt u doorgaan?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Kan dit account niet verwijderen."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Abonnementen doorvoeren"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"<xliff:g id="AUTHORITY">%s</xliff:g> synchroniseren"</string>
 </resources>
diff --git a/res/values-pl/strings.xml b/res/values-pl/strings.xml
index c8ccede..a42f9cb 100644
--- a/res/values-pl/strings.xml
+++ b/res/values-pl/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Synchronizowanie kanałów"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Synchronizacja danych"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Przekroczono limit usuwania"</string>
     <string name="background_data" msgid="1103557117473896066">"Dane w tle"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Włącz używanie danych w tle"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"Wyłączenie danych w tle umożliwia oszczędzanie baterii i zmniejsza wykorzystanie danych. Mimo to niektóre aplikacje mogą nadal korzystać z połączenia transmisji danych w tle."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Autosynchronizacja"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Automatycznie synchronizuj dane"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Ustawienia tworzenia kopii zapasowej"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Włącz funkcję tworzenia kopii zapasowej ustawień"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Synchronizuj teraz"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Anuluj synchronizację"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Wybierz, aby zsynchronizować teraz<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"Podczas synchronizacji wystąpiły problemy. Synchronizacja zostanie wkrótce wznowiona."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Witamy w Google Sync!"</font>" "\n"Firma Google umożliwia synchronizację danych i dostęp do kontaktów, terminów oraz innych informacji z dowolnego miejsca."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Ustawienia synchronizacji aplikacji"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Ogólne ustawienia synchronizacji"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Dodaj konto"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Dane i synchronizacja"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Zmień hasło"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Ustawienia konta"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Usuń konto"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Dodaj konto"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Zakończ"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Usuń konto"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Czy na pewno chcesz usunąć to konto? Operacja spowoduje usunięcie wszystkich danych powiązanych z kontem. "\n"Kontynuować?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Nie można usunąć tego konta."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Subskrypcje w trybie push"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Synchronizuj aplikację <xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-pt-rPT/strings.xml b/res/values-pt-rPT/strings.xml
index e670248..abec0c4 100644
--- a/res/values-pt-rPT/strings.xml
+++ b/res/values-pt-rPT/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Sincronizar feeds"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Sincronização de dados"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Limite de eliminações excedido"</string>
     <string name="background_data" msgid="1103557117473896066">"Dados em segundo plano"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Activar utilização de dados em segundo plano"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"A desactivação de dados em segundo plano economiza a bateria e reduz a utilização de dados. Algumas aplicações podem continuar a utilizar a ligação de dados em segundo plano."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Sincronização automática"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Sincronizar dados automaticamente"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Efectuar uma cópia de segurança das definições"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Activar cópia de segurança das definições"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Sincronizar agora"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Cancelar sincronização"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Optar por sincronizar agora<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"A sincronização está actualmente com problemas e será retomada em breve."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Bem vindo ao Google Sync!"</font>" "\n"Uma abordagem do Google à sincronização de dados que permite aceder aos contactos, compromissos e outros itens, onde quer que esteja."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Definições de sincronização da aplicação"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Definições gerais de sincronização"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Adicionar conta"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Dados e sincronização"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Alterar palavra-passe"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Definições da conta"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Remover conta"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Adicionar uma conta"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Terminar"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Remover conta"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Deseja mesmo remover esta conta? Ao efectuar a remoção, todos os dados associados à conta serão removidos. "\n"Continuar?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Não foi possível remover esta conta."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Subscrições de Emissão"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Sincronizar <xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-pt/strings.xml b/res/values-pt/strings.xml
index 232491e..5cb78d4 100644
--- a/res/values-pt/strings.xml
+++ b/res/values-pt/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Sincronizar feeds"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Sincronização de dados"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Limite de exclusão excedido"</string>
     <string name="background_data" msgid="1103557117473896066">"Dados de segundo plano"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Ativar o uso de dados de segundo plano"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"A desativação dos dados de segundo plano economiza a bateria e diminui o uso dos dados. Alguns aplicativos ainda podem usar a conexão de dados de segundo plano."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Sincronização automática"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Sincronizar dados automaticamente"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Fazer backup das configurações"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Ativar backup das configurações"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Sincronizar agora"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Cancelar a sincronização"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Selecione para sincronizar agora<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"O Google Sync está enfrentando problemas no momento. Ele retornará em breve."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Bem-vindo ao Google Sync!"</font>" "\n"Um método do Google para sincronizar dados de modo a permitir o acesso aos seus contatos, compromissos e muito mais, onde quer que você esteja."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Configurações de sincronização do aplicativo"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Configurações de sincronização geral"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Adicionar conta"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Dados e sincronização"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Alterar senha"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Configurações da conta"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Remover conta"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Adicionar uma conta"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Concluir"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Remover conta"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Deseja realmente remover esta conta? A remoção da conta também removerá todos os dados associados a ela. "\n"Deseja continuar?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Não foi possível remover esta conta."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Enviar inscrições"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Sincronizar <xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-ru/strings.xml b/res/values-ru/strings.xml
index 2a908f3..3c7a020 100644
--- a/res/values-ru/strings.xml
+++ b/res/values-ru/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Фиды синхронизации"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Синхронизация данных"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Превышен предел удаления"</string>
     <string name="background_data" msgid="1103557117473896066">"Использовать фоновые данные"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Разрешить использовать фоновую передачу данных"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"Отключение фоновых данных экономит энергию батареи и уменьшает использование данных. Некоторые приложения могут, тем не менее, использовать фоновую передачу данных."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Автосинхронизация"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Автоматическая синхронизация данных"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Создать резервную копию настроек"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Включить резервное копирование настроек"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Синхронизировать сейчас"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Отменить синхронизацию"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Выберите для синхронизации прямо сейчас<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"Проблемы с синхронизацией. Скоро все снова будет работать."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Добро пожаловать в Google Sync!"</font>" "\n"Подход Google к синхронизации данных, помогает получить информацию о контактах, встречах и многом другом, где бы вы ни были."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Настройки синхронизации приложения"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Общие настройки синхронизации"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Добавить аккаунт"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Данные и синхронизация"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Изменить пароль"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Настройки аккаунта"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Удалить аккаунт"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Добавить аккаунт"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Готово"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Удалить аккаунт"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Удалить этот аккаунт? Это действие приведет к удалению всех данных, связанных с аккаунтом. "\n"Продолжить?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Невозможно удалить этот аккаунт."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Подписки Push"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Синхр. <xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-sv/strings.xml b/res/values-sv/strings.xml
index 4f20418..ec1d7e7 100644
--- a/res/values-sv/strings.xml
+++ b/res/values-sv/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Synkroniseringsflöden"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Datasynkronisering"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Gränsen för borttagning har överskridits"</string>
     <string name="background_data" msgid="1103557117473896066">"Bakgrundsdata"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Aktivera användning av bakgrundsdata"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"Om du inaktiverar bakgrundsdata sparar du batteri och minskar dataanvändning. Vissa program kanske fortfarande använder anslutningen för bakgrundsdata."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Automatisk synkron."</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Synkronisera data automatiskt"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Säkerhetskopiera inställningar"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Aktivera säkerhetskopiering av inställningar"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Synkronisera nu"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Avbryt synkronisering"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Välj om du vill synkronisera nu<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"Det är för närvarande problem med synkronisering. Det fungerar igen om en stund."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Välkommen till Google Sync!"</font>" "\n"En funktion i Google som du kan använda om du vill synkronisera data så att du kommer åt dina kontakter, din kalender osv. var du än befinner dig."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Programmets synkroniseringsinställningar"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Allmänna synkroniseringsinställningar"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Lägg till konto"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Data  och synkronisering"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Byt lösenord"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Kontoinställningar"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Ta bort konto"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Lägg till ett konto"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Avsluta"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Ta bort konto"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Vill du ta bort kontot? Om du tar bort det försvinner alla data som tillhör det. "\n"Vill du fortsätta?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Det gick inte att ta bort kontot."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Push-prenumerationer"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"Synkronisera <xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-tr/strings.xml b/res/values-tr/strings.xml
index ea4d4c9..09476f6 100644
--- a/res/values-tr/strings.xml
+++ b/res/values-tr/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"Senkronizasyon Yayınları"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"Veri senkronizasyonu"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"Silme sınırı aşıldı"</string>
     <string name="background_data" msgid="1103557117473896066">"Arka plan veri"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"Arka plan veri kullanımını etkinleştir"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"Arka plan verilerini devre dışı bırakmak pilden tasarruf sağlar ve veri kullanımını düşürür. Bazı uygulamalar yine de arka plan veri bağlantısını kullanabilir."</string>
     <string name="sync_automatically" msgid="4694735102757960100">"Otomatik senk."</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"Verileri otomatik olarak senkronize et"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"Ayarları yedekle"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"Ayarları yedeklemeyi etkinleştir"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"Şimdi senk. et"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"Senkronizasyonu iptal et"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"Şimdi senkronize etmek için seçin<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"Senk. şu anda sorun yaşıyor. Kısa bir süre sonra yeniden devreye girecek."</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"Google Sync\'e Hoş Geldiniz!"</font>" "\n"Kişilerinize, randevularınıza ve diğer bilgilerinize istediğiniz yerden erişebilmenize olanak tanımak için veri senkronizasyonuna bir Google yaklaşımı."</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"Uygulama senk. ayarları"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"Genel senk. ayarları"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"Hesap ekle"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"Veri ve Senkronizasyon"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"Şifreyi değiştir"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"Hesap Ayarları"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"Hesabı kaldır"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"Bir hesap ekleyin"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"Son"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"Hesabı kaldır"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"Bu hesabı gerçekten kaldırmak istiyor musunuz? Bunu kaldırmak, hesapla ilişkilendirilmiş tüm verileri de kaldırır. "\n"Devam etmek istiyor musunuz?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"Bu hesap kaldırılamadı."</string>
+    <string name="provider_label" msgid="4860292144158484350">"Abonelik Şart Koş"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"<xliff:g id="AUTHORITY">%s</xliff:g> senkronize et"</string>
 </resources>
diff --git a/res/values-zh-rCN/strings.xml b/res/values-zh-rCN/strings.xml
index 966f7ec..274158e 100644
--- a/res/values-zh-rCN/strings.xml
+++ b/res/values-zh-rCN/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"同步供稿"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"数据同步"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"超出删除限制"</string>
     <string name="background_data" msgid="1103557117473896066">"背景数据"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"启用背景数据"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"禁用背景数据可节省电量并可降低数据使用量。有些应用程序可能仍会使用背景数据连接。"</string>
     <string name="sync_automatically" msgid="4694735102757960100">"自动同步"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"自动同步数据"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"备份设置"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"启用设置备份功能"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"立即同步"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"取消同步"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"选择此程序立即开始同步<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"同步现在遇到问题。很快将返回此操作。"</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"欢迎使用 Google Sync!"</font>\n"Google 同步数据的方法可以让您从任何地方访问您的联系人、约会以及更多信息。"</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"应用程序同步设置"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"常规同步设置"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"添加帐户"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"数据与同步"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"更改密码"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"帐户设置"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"删除帐户"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"添加帐户"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"完成"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"删除帐户"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"确实要删除此帐户吗?删除该帐户将删除与之关联的所有数据。"\n"是否继续?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"无法删除此帐户。"</string>
+    <string name="provider_label" msgid="4860292144158484350">"推送订阅"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"同步<xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values-zh-rTW/strings.xml b/res/values-zh-rTW/strings.xml
index 5818795..3de1ef6 100644
--- a/res/values-zh-rTW/strings.xml
+++ b/res/values-zh-rTW/strings.xml
@@ -16,7 +16,8 @@
 <resources xmlns:android="http://schemas.android.com/apk/res/android"
     xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <string name="app_label" msgid="2800463760279909883">"同步資訊提供"</string>
-    <string name="sync_settings" msgid="4549768061467147584">"資料同步處理"</string>
+    <!-- no translation found for sync_settings (8707056705985552604) -->
+    <skip />
     <string name="sync_too_many_deletes" msgid="1621369057980827097">"達到刪除上限"</string>
     <string name="background_data" msgid="1103557117473896066">"背景資料"</string>
     <string name="background_data_summary" msgid="4689952168187153486">"啟用背景資料"</string>
@@ -24,6 +25,8 @@
     <string name="background_data_dialog_message" msgid="2817489591533703840">"停用背景資料可節省電源並減少資料的使用。但某些應用程式可能仍會使用背景資料連線。"</string>
     <string name="sync_automatically" msgid="4694735102757960100">"自動同步處理"</string>
     <string name="sync_automatically_summary" msgid="6210073947698673774">"自動同步處理資料"</string>
+    <string name="settings_backup" msgid="6114299464740014762">"備份設定"</string>
+    <string name="settings_backup_summary" msgid="5308702862293201877">"啟用設定備份功能"</string>
     <string name="sync_menu_sync_now" msgid="5796024841315572404">"立即同步處理"</string>
     <string name="sync_menu_sync_cancel" msgid="1005480041232010062">"取消同步處理"</string>
     <string name="sync_one_time_sync" msgid="3474532720071919514">"選取此處立即開始同步處理<xliff:g id="LAST_SYNC_TIME">
@@ -38,5 +41,19 @@
     <string name="sync_is_failing" msgid="5230237058552433773">"同步處理目前發生問題。將於短時間內恢復。"</string>
     <string name="sync_plug" msgid="4526246957714417280"><font fgcolor="#ffffffff">"歡迎使用 Google Sync!"</font>\n"這是 Google 所提供用於同步處理資料的程式,可讓您隨時隨地存取聯絡人、約會等資料。"</string>
     <string name="header_application_sync_settings" msgid="5263025067167527890">"應用程式同步處理設定"</string>
+    <!-- no translation found for header_manage_accounts (381956296995298770) -->
+    <skip />
     <string name="header_general_sync_settings" msgid="1598537524696692308">"一般同步處理設定"</string>
+    <string name="add_account_label" msgid="2035321485672826779">"新增帳戶"</string>
+    <string name="header_data_and_synchronization" msgid="7274711697016911550">"資料與資料同步"</string>
+    <string name="preference_change_password_title" msgid="6468827554159468315">"變更密碼"</string>
+    <string name="header_account_settings" msgid="8795624691307728708">"帳戶設定"</string>
+    <string name="remove_account_label" msgid="5624712684599197863">"移除帳戶"</string>
+    <string name="header_add_an_account" msgid="2198078922829535425">"新增帳戶"</string>
+    <string name="finish_button_label" msgid="6121560986057356757">"完成"</string>
+    <string name="really_remove_account_title" msgid="8808121039511188784">"移除帳戶"</string>
+    <string name="really_remove_account_message" msgid="9058660516139501549">"確定要移除這個帳戶嗎?移除帳戶將會一併移除所有與其關聯的資料。"\n"要繼續嗎?"</string>
+    <string name="remove_account_failed" msgid="1834355229721070397">"無法移除這個帳戶。"</string>
+    <string name="provider_label" msgid="4860292144158484350">"預先載入訂閱項目"</string>
+    <string name="sync_item_title" msgid="7984962124867021854">"同步處理<xliff:g id="AUTHORITY">%s</xliff:g>"</string>
 </resources>
diff --git a/res/values/strings.xml b/res/values/strings.xml
index a606565..4e93cde 100644
--- a/res/values/strings.xml
+++ b/res/values/strings.xml
@@ -19,30 +19,34 @@
 
 <resources xmlns:xliff="urn:oasis:names:tc:xliff:document:1.2">
     <!-- Title of the feed synchronization activity. -->
-    <string name="app_label">Sync Feeds</string>
+    <string name="app_label">Sync feeds</string>
     <!-- Sync settings -->
     <!-- Main Settings screen setting option name to go into the screen for data sync settings-->
-    <string name="sync_settings">Data synchronization</string>
+    <string name="sync_settings">Accounts &amp; sync settings</string>
     <!-- Error message when the sync tried to delete too many things -->
     <string name="sync_too_many_deletes">Delete limit exceeded</string>
     <!-- Data synchronization settings screen, title of setting that controls whether background data should be used -->
     <string name="background_data">Background data</string>
     <!-- Data synchronization settings screen, summary of setting that controls whether background data should be used -->
-    <string name="background_data_summary">Enable background data usage</string>
+    <string name="background_data_summary">Applications can sync, send, and receive data at any time</string>
     <!-- Data synchronization settings screen, title of dialog that confirms the user's unchecking of background data -->
     <string name="background_data_dialog_title">Attention</string>
     <!-- Data synchronization settings screen, message of dialog that confirms the user's unchecking of background data -->
-    <string name="background_data_dialog_message">Disabling background data saves battery and lowers data usage. Some applications may still use the background data connection.</string>
+    <string name="background_data_dialog_message">Disabling background data extends battery life and lowers data use. Some applications may still use the background data connection.</string>
     <!-- Data synchronization settings screen, setting option name -->
     <string name="sync_automatically">Auto-sync</string>
     <!-- Data synchronization settings screen, setting option summary text when check box is selected -->
-    <string name="sync_automatically_summary">Automatically sync data</string>
+    <string name="sync_automatically_summary">Applications sync data automatically</string>
+    <!-- Data synchronization settings screen, setting option name -->
+    <string name="settings_backup">Back up settings</string>
+    <!-- Data synchronization settings screen, setting option summary text when check box is selected -->
+    <string name="settings_backup_summary">Back up my settings</string>
     <!-- Data synchronization settings screen, menu option -->
     <string name="sync_menu_sync_now">Sync now</string>
     <!-- Data synchronization settings screen, menu option -->
     <string name="sync_menu_sync_cancel">Cancel sync</string>
     <!-- Data synchronization settings screen, summary of a sync provider (for example, Gmail) when autosync is off and the user wants to do a one-time sync. -->
-    <string name="sync_one_time_sync">Select to sync now<xliff:g id="last_sync_time">\n%1$s</xliff:g></string>
+    <string name="sync_one_time_sync">Touch to sync now<xliff:g id="last_sync_time">\n%1$s</xliff:g></string>
     <!-- Data synchronization settings screen, checkbox setting option name. Controls whether Gmail should be synced.  Should use "Gmail" to refer to this app.-->
     <string name="sync_gmail">Gmail</string>
     <!-- Data synchronization settings screen, checkbox setting option name. Controls whether Calendar shoudl be synced. -->
@@ -60,11 +64,56 @@
     <!-- Message when sync is currently failing -->
     <string name="sync_is_failing">Sync is currently experiencing problems. It will be back shortly.</string>
     <!-- Message introducing the user to Google Sync. -->
-    <string name="sync_plug"><font fgcolor="#ffffffff">Welcome to Google Sync!</font>
-    \nA Google approach to synchronizing data to allow access to your contacts, appointments and more from wherever you are.
+    <string name="sync_plug"><font fgcolor="#ffffffff">Welcome to Google sync!</font>
+    \nA Google approach to synchronizing data to allow access to your contacts, appointments, and more from wherever you are.
     </string>
+
+    <!-- TODO: Remove -->
     <!-- Header title for those settings relating to application syncing. -->
     <string name="header_application_sync_settings">Application sync settings</string>
+    <!-- TODO: end -->
+
+    <!-- Accounts & Synchronization settings --><skip/>
+    <!-- Header title for list of accounts on Accounts & Synchronization settings -->
+    <string name="header_manage_accounts">Manage accounts</string>
     <!-- Header title for those settings relating to general syncing. -->
     <string name="header_general_sync_settings">General sync settings</string>
+
+    <!-- Sync status messages on Accounts & Synchronization settings --><skip/>
+    <!-- Sync status shown when sync is enabled -->
+    <string name="sync_enabled">Sync is ON</string>
+    <!-- Sync status shown when sync is disabled -->
+    <string name="sync_disabled">Sync is OFF</string>
+    <!-- Sync status shown when last sync resulted in an error -->
+    <string name="sync_error">Sync error</string>
+
+    <!-- Button label to add an account -->
+    <string name="add_account_label">Add account</string>
+    <!-- Header for data and synchronization -->
+    <string name="header_data_and_synchronization">Data &amp; synchronization</string>
+    <!-- Preference item that lets the user change password -->
+    <string name="preference_change_password_title">Change password</string>
+    <!-- Header that appears at the top of Account Settings screen -->
+    <string name="header_account_settings">Account settings</string>
+    <!-- Button label to remove current account -->
+    <string name="remove_account_label">Remove account</string>
+    <!-- Title shown in AddAccount -->
+    <string name="header_add_an_account">Add an account</string>
+    <!-- Button shown when this activity is run from SetupWizard -->
+    <string name="finish_button_label">Finish</string>
+    <!-- Title of remove message for remove account dialog -->
+    <string name="really_remove_account_title">Remove account</string>
+    <!-- Remove account message in dialog -->
+    <string name="really_remove_account_message">Do you really want to remove this account? Removing it will also delete all of its messages, contacts, and other data from the phone.
+    \nProceed?</string>
+    <!-- This is shown if the autheticator for a given account fails to remove it. -->
+    <string name="remove_account_failed">This account is required by some applications. You can only remove it by resetting the phone to factory defaults (which deletes all your personal data). You do that in the Settings application, under Privacy.</string>
+    <!-- What to show in messaging that refers to this provider, e.g. AccountSyncSettings -->
+    <string name="provider_label">Push subscriptions</string>
+    <!-- Formatter in AccountSyncSettings for each application we wish to synchronize, e.g. "Sync Calendar" -->
+    <string name="sync_item_title">Sync <xliff:g id="authority" example="Calendar">%s</xliff:g></string>
+    <!-- Title of dialog shown when you can't manually sync an item because it's disabled -->
+    <string name="cant_sync_dialog_title">Cannot manually sync</string>
+    <!-- Messaage shown in dialog when you can't manually sync -->
+    <string name="cant_sync_dialog_message">Sync for this item is currently disabled. To change your preference, temporarily turn on background data and automatic sync.</string>
 </resources>
diff --git a/res/xml/account_sync_settings.xml b/res/xml/account_sync_settings.xml
new file mode 100644
index 0000000..ff49c9c
--- /dev/null
+++ b/res/xml/account_sync_settings.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2008 The Android Open Source Project
+
+     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.
+-->
+
+<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
+
+    <PreferenceCategory android:key="dataAndSynchronization"
+            android:title="@string/header_data_and_synchronization" />
+
+</PreferenceScreen>
diff --git a/res/xml/add_account_settings.xml b/res/xml/add_account_settings.xml
new file mode 100644
index 0000000..0ec46b7
--- /dev/null
+++ b/res/xml/add_account_settings.xml
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2008 The Android Open Source Project
+
+     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.
+-->
+
+<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
+
+</PreferenceScreen>
diff --git a/res/xml/manage_accounts_settings.xml b/res/xml/manage_accounts_settings.xml
new file mode 100644
index 0000000..8ddd7e7
--- /dev/null
+++ b/res/xml/manage_accounts_settings.xml
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!-- Copyright (C) 2008 The Android Open Source Project
+
+     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.
+-->
+
+<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
+
+    <PreferenceCategory
+            android:title="@string/header_general_sync_settings" />
+
+    <CheckBoxPreference android:key="backgroundDataCheckBox"
+        android:persistent="false"
+        android:title="@string/background_data"
+        android:summary="@string/background_data_summary"/>
+
+    <CheckBoxPreference android:key="syncAutomaticallyCheckBox"
+        android:persistent="false"
+        android:dependency="backgroundDataCheckBox"
+        android:title="@string/sync_automatically"
+        android:summary="@string/sync_automatically_summary"/>
+
+    <PreferenceCategory android:key="manageAccountsCategory"
+            android:title="@string/header_manage_accounts" />
+
+</PreferenceScreen>
diff --git a/res/xml/sync_settings.xml b/res/xml/sync_settings.xml
deleted file mode 100644
index 988363f..0000000
--- a/res/xml/sync_settings.xml
+++ /dev/null
@@ -1,55 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!-- Copyright (C) 2008 The Android Open Source Project
-
-     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.
--->
-
-<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
-
-    <PreferenceCategory
-            android:title="@string/header_general_sync_settings" />
-
-    <CheckBoxPreference android:key="backgroundDataCheckBox"
-        android:persistent="false"
-        android:title="@string/background_data"
-        android:summary="@string/background_data_summary"/>
-    <CheckBoxPreference android:key="autoSyncCheckBox"
-        android:persistent="false"
-        android:title="@string/sync_automatically"
-        android:summary="@string/sync_automatically_summary"
-        android:dependency="backgroundDataCheckBox"/>
-
-    <PreferenceCategory
-            android:title="@string/header_application_sync_settings" />
-
-    <!-- The following keys are special. They correspond to
-         content providers sans the "sync_" prefix. This is
-         because very specific content providers are being
-         enabled for sync in this release.
-        -->
-    <com.android.settings.SyncStateCheckBoxPreference android:key="sync_gmail-ls"
-        android:persistent="false"
-        android:title="@string/sync_gmail"
-        android:summary=""
-        android:dependency="backgroundDataCheckBox"/>
-    <com.android.settings.SyncStateCheckBoxPreference android:key="sync_calendar"
-        android:persistent="false"
-        android:title="@string/sync_calendar"
-        android:summary=""
-        android:dependency="backgroundDataCheckBox"/>
-    <com.android.settings.SyncStateCheckBoxPreference android:key="sync_contacts"
-        android:persistent="false"
-        android:title="@string/sync_contacts"
-        android:summary=""
-        android:dependency="backgroundDataCheckBox"/>
-</PreferenceScreen>
diff --git a/res/xml/syncadapter.xml b/res/xml/syncadapter.xml
new file mode 100644
index 0000000..28ee675
--- /dev/null
+++ b/res/xml/syncadapter.xml
@@ -0,0 +1,27 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/**
+ * Copyright (c) 2009, The Android Open Source Project
+ *
+ * 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.
+ */
+-->
+
+<!-- The attributes in this XML file provide configuration information -->
+<!-- for the SyncAdapter. -->
+
+<sync-adapter xmlns:android="http://schemas.android.com/apk/res/android"
+    android:contentAuthority="subscribedfeeds"
+    android:accountType="com.google"
+    android:userVisible="false"
+/>
diff --git a/src/com/android/providers/subscribedfeeds/GoogleSubscribedFeedsProvider.java b/src/com/android/providers/subscribedfeeds/GoogleSubscribedFeedsProvider.java
index 87e6364..5e6da41 100644
--- a/src/com/android/providers/subscribedfeeds/GoogleSubscribedFeedsProvider.java
+++ b/src/com/android/providers/subscribedfeeds/GoogleSubscribedFeedsProvider.java
@@ -16,16 +16,10 @@
 
 package com.android.providers.subscribedfeeds;
 
-import android.content.SyncAdapter;
-
 public class GoogleSubscribedFeedsProvider extends SubscribedFeedsProvider {
-    private SubscribedFeedsSyncAdapter mSyncAdapter;
-
     @Override
-    public synchronized SyncAdapter getSyncAdapter() {
-        if (mSyncAdapter == null) {
-            mSyncAdapter = new SubscribedFeedsSyncAdapter(getContext(), this);
-        }
-        return mSyncAdapter;
+    public boolean onCreate() {
+        setTempProviderSyncAdapter(new SubscribedFeedsSyncAdapter(getContext(), this));
+        return super.onCreate();
     }
 }
\ No newline at end of file
diff --git a/src/com/android/providers/subscribedfeeds/SubscribedFeedsSyncAdapter.java b/src/com/android/providers/subscribedfeeds/SubscribedFeedsSyncAdapter.java
index 6094ed3..693d4f3 100644
--- a/src/com/android/providers/subscribedfeeds/SubscribedFeedsSyncAdapter.java
+++ b/src/com/android/providers/subscribedfeeds/SubscribedFeedsSyncAdapter.java
@@ -19,6 +19,7 @@
 import com.google.android.gdata.client.AndroidGDataClient;
 import com.google.android.gdata.client.AndroidXmlParserFactory;
 import com.google.android.googlelogin.GoogleLoginServiceBlockingHelper;
+import com.google.android.googlelogin.GoogleLoginServiceConstants;
 import com.google.android.googlelogin.GoogleLoginServiceNotFoundException;
 import com.google.android.providers.AbstractGDataSyncAdapter;
 import com.google.wireless.gdata.client.GDataServiceClient;
@@ -31,7 +32,12 @@
 import com.google.wireless.gdata.subscribedfeeds.data.SubscribedFeedsEntry;
 import com.google.wireless.gdata.subscribedfeeds.parser.xml.XmlSubscribedFeedsGDataParserFactory;
 
+import android.accounts.Account;
+import android.accounts.AccountManager;
+import android.accounts.AuthenticatorException;
+import android.accounts.OperationCanceledException;
 import android.content.ContentProvider;
+import android.content.ContentResolver;
 import android.content.ContentValues;
 import android.content.Context;
 import android.content.SyncContext;
@@ -43,19 +49,31 @@
 import android.os.Bundle;
 import android.provider.Settings;
 import android.provider.SubscribedFeeds;
+import android.provider.SyncConstValue;
 import android.util.Log;
 import android.text.TextUtils;
 
+import java.io.IOException;
+
 /**
  * Implements a SyncAdapter for SubscribedFeeds
  */
 public class SubscribedFeedsSyncAdapter extends AbstractGDataSyncAdapter {
     private final SubscribedFeedsClient mSubscribedFeedsClient;
+    public static final String ACCOUNT_TYPE = "com.google";
+    public static final String FEATURE_SERVICE_PREFIX = "service_";
 
     private final static String FEED_URL = "https://android.clients.google.com/gsync/sub";
 
     private static final String ROUTINGINFO_PARAMETER = "routinginfo";
-
+    
+    /** 
+     * If an account has no subscriptions there is no need to connect to the server.
+     * Server will expire and delete unused feeds automatically.
+     * This also skips subscription feeds for foreign/youtube accounts. 
+     */
+    private boolean mAccountHasEntries = true;
+    
     protected SubscribedFeedsSyncAdapter(Context context, SyncableContentProvider provider) {
         super(context, provider);
         mSubscribedFeedsClient =
@@ -65,6 +83,40 @@
                             new AndroidXmlParserFactory()));
     }
 
+    private boolean hasEntries(Account account) {
+        Cursor cursor = null;
+        try {
+            cursor = getContext().getContentResolver().query(SubscribedFeeds.Feeds.CONTENT_URI, 
+                null /* columns */,
+                SyncConstValue._SYNC_ACCOUNT + "=? AND " +
+                		SyncConstValue._SYNC_ACCOUNT_TYPE + "=?",
+                new String[]{account.name, account.type},
+                null/* orderBy */);
+            if (cursor == null || cursor.getCount() == 0) {
+                return false;
+            } else {
+                return true;
+            }
+        } finally {
+            if (cursor != null) {
+                cursor.close();
+            }
+        }
+    }
+    
+    public void onSyncStarting(SyncContext context, Account account, boolean manualSync,
+            SyncResult result) {
+        mAccountHasEntries = hasEntries(account);
+        if (mAccountHasEntries) {
+            // will get the auth token
+            super.onSyncStarting(context, account, manualSync, result);
+        } else {
+            // Will be needed later - super would also try to get the token, which 
+            // may fail ( and does a HTTP request we want to avoid ).
+            mAccount = account;
+        }
+    }
+    
     @Override
     protected GDataServiceClient getGDataServiceClient() {
         return mSubscribedFeedsClient;
@@ -82,10 +134,13 @@
      * appropriate actions on the ContentProvider to represent the entry.
      */
     protected void updateProvider(Feed feed, Long syncLocalId,
-            Entry baseEntry, ContentProvider provider, Object syncInfo)
+            Entry baseEntry, ContentProvider provider, Object syncInfo,
+            GDataSyncData.FeedData feedSyncData)
             throws ParseException {
         ContentValues values = new ContentValues();
-        values.put(SubscribedFeeds.Feeds._SYNC_ACCOUNT, getAccount());
+        final Account account = getAccount();
+        values.put(SubscribedFeeds.Feeds._SYNC_ACCOUNT, account.name);
+        values.put(SubscribedFeeds.Feeds._SYNC_ACCOUNT_TYPE, account.type);
         values.put(SubscribedFeeds.Feeds._SYNC_LOCAL_ID, syncLocalId);
         final SubscribedFeedsEntry entry = (SubscribedFeedsEntry) baseEntry;
         final String id = entry.getId();
@@ -110,7 +165,7 @@
     }
 
     @Override
-    protected String getFeedUrl(String account) {
+    protected String getFeedUrl(Account account) {
         return FEED_URL;
     }
 
@@ -119,7 +174,7 @@
     }
 
     @Override
-    protected void updateQueryParameters(QueryParams params) {
+    protected void updateQueryParameters(QueryParams params, GDataSyncData.FeedData feedSyncData) {
         params.setParamValue(ROUTINGINFO_PARAMETER, getRoutingInfoForAccount(getAccount()));
     }
 
@@ -135,11 +190,17 @@
     public void getServerDiffs(SyncContext context, SyncData syncData,
             SyncableContentProvider tempProvider,
             Bundle extras, Object syncInfo, SyncResult syncResult) {
+        if (!mAccountHasEntries) {
+            // foreign accounts or accounts with no subscriptions
+            // Server will expire the subscriptions automatically.
+            return;
+        }
+        
         tempProvider.setContainsDiffs(false /* the server returns all records, not just diffs */);
         super.getServerDiffs(context, syncData, tempProvider, extras, syncInfo, syncResult);
     }
 
-    public void onAccountsChanged(String[] accounts) {
+    public void onAccountsChanged(Account[] accounts) {
         // no need to do anything
     }
 
@@ -162,21 +223,30 @@
     @Override
     protected String cursorToEntry(SyncContext context,
             Cursor c, Entry baseEntry, Object syncInfo) throws ParseException {
-        final String account = c.getString(c.getColumnIndex(SubscribedFeeds.Feeds._SYNC_ACCOUNT));
+        final String accountName =
+                c.getString(c.getColumnIndex(SubscribedFeeds.Feeds._SYNC_ACCOUNT));
+        final String accountType =
+                c.getString(c.getColumnIndex(SubscribedFeeds.Feeds._SYNC_ACCOUNT_TYPE));
+        final Account account = new Account(accountName, accountType);
         final String service = c.getString(c.getColumnIndex(SubscribedFeeds.Feeds.SERVICE));
         final String id = c.getString(c.getColumnIndex(SubscribedFeeds.Feeds._SYNC_ID));
         final String feed = c.getString(c.getColumnIndex(SubscribedFeeds.Feeds.FEED));
 
         String authToken;
         try {
-            authToken =
-                    GoogleLoginServiceBlockingHelper.getAuthToken(getContext(), account, service);
-        } catch (GoogleLoginServiceBlockingHelper.AuthenticationException e) {
+            authToken = AccountManager.get(getContext()).blockingGetAuthToken(
+                    new Account(accountName, "com.google"), service, true);
+        } catch (IOException e) {
             Log.e("Sync", "caught exception while attempting to get an " +
                     "authtoken for account " + account +
                     ", service " + service + ": " + e.toString());
             throw new ParseException(e.getMessage(), e);
-        } catch (GoogleLoginServiceNotFoundException e) {
+        } catch (AuthenticatorException e) {
+            Log.e("Sync", "caught exception while attempting to get an " +
+                    "authtoken for account " + account +
+                    ", service " + service + ": " + e.toString());
+            throw new ParseException(e.getMessage(), e);
+        } catch (OperationCanceledException e) {
             Log.e("Sync", "caught exception while attempting to get an " +
                     "authtoken for account " + account +
                     ", service " + service + ": " + e.toString());
@@ -195,7 +265,7 @@
 
         String createUrl = null;
         if (id == null) {
-            createUrl = getFeedUrl(account);    
+            createUrl = getFeedUrl(account);
         }
         return createUrl;
     }
@@ -214,18 +284,46 @@
      * can use it.
      *
      * @param account the account whose routing info we want
-     * @return the GSyncSubscriptionServer routing string for this account
+     * @return the routing info for this account
      */
-    public String getRoutingInfoForAccount(String account) {
+    public String getRoutingInfoForAccount(Account account) {
+        Context context = getContext();
         long androidId;
         try {
-            androidId = GoogleLoginServiceBlockingHelper.getAndroidId(getContext());
+            androidId = GoogleLoginServiceBlockingHelper.getAndroidId(context);
         } catch (GoogleLoginServiceNotFoundException e) {
             Log.e(TAG, "Could not get routing info for account", e);
             return null;
         }
-        return Uri.parse("gtalk://" + account
-                + "#" + Settings.getGTalkDeviceId(androidId)).toString();
+
+	ContentResolver cr = context.getContentResolver();
+	boolean useRmq2RoutingInfo = "true".equals(
+	    Settings.Gservices.getString(cr, Settings.Gservices.GSYNC_USE_RMQ2_ROUTING_INFO));
+        if (useRmq2RoutingInfo) {
+	    return Uri.parse("android://" + Long.toHexString(androidId)).toString();
+	} else {
+            // We have to send the routing info for the primary (legacy) account.
+            final AccountManager accountManager = AccountManager.get(getContext());
+            try {
+                String[] features =
+                        new String[]{GoogleLoginServiceConstants.FEATURE_LEGACY_HOSTED_OR_GOOGLE};
+                Account[] accounts = accountManager.getAccountsByTypeAndFeatures(
+                        GoogleLoginServiceConstants.ACCOUNT_TYPE, features, null, null).getResult();
+                if (accounts.length == 0) {
+                    Log.e(TAG, "No matching accounts.");
+                    return null;
+                }
+                return Uri.parse("gtalk://" + accounts[0].name
+                        + "#" + Settings.getGTalkDeviceId(androidId)).toString();
+            } catch (IOException e) {
+                Log.e(TAG, "Could not get account", e);
+            } catch (AuthenticatorException e) {
+                Log.e(TAG, "Could not get account", e);
+            } catch (OperationCanceledException e) {
+                Log.e(TAG, "Could not get account", e);
+            }
+        }
+        return null;
     }
 
     @Override
@@ -235,4 +333,5 @@
         // should exist.
         return false;
     }
+        
 }
diff --git a/src/com/android/providers/subscribedfeeds/SubscribedFeedsSyncAdapterService.java b/src/com/android/providers/subscribedfeeds/SubscribedFeedsSyncAdapterService.java
new file mode 100644
index 0000000..facced9
--- /dev/null
+++ b/src/com/android/providers/subscribedfeeds/SubscribedFeedsSyncAdapterService.java
@@ -0,0 +1,29 @@
+package com.android.providers.subscribedfeeds;
+
+import android.app.Service;
+import android.os.IBinder;
+import android.content.Intent;
+import android.content.ContentProviderClient;
+import android.content.ContentProvider;
+import android.content.SyncableContentProvider;
+import android.provider.SubscribedFeeds;
+
+public class SubscribedFeedsSyncAdapterService extends Service {
+    private ContentProviderClient mContentProviderClient = null;
+
+    public void onCreate() {
+        mContentProviderClient = getContentResolver().acquireContentProviderClient(
+                SubscribedFeeds.Feeds.CONTENT_URI);
+    }
+
+    public void onDestroy() {
+        mContentProviderClient.release();
+    }
+
+    public IBinder onBind(Intent intent) {
+        ContentProvider contentProvider = mContentProviderClient.getLocalContentProvider();
+        if (contentProvider == null) throw new IllegalStateException();
+        SyncableContentProvider syncableContentProvider = (SyncableContentProvider)contentProvider;
+        return syncableContentProvider.getTempProviderSyncAdapter().getISyncAdapter().asBinder();
+    }
+}
diff --git a/src/com/android/settings/AccountPreference.java b/src/com/android/settings/AccountPreference.java
new file mode 100644
index 0000000..cba267e
--- /dev/null
+++ b/src/com/android/settings/AccountPreference.java
@@ -0,0 +1,144 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ *
+ * 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.
+ */
+
+package com.android.settings;
+
+import java.util.ArrayList;
+
+import com.android.providers.subscribedfeeds.R;
+
+import android.accounts.Account;
+import android.content.Context;
+import android.content.Intent;
+import android.graphics.drawable.Drawable;
+import android.preference.Preference;
+import android.util.Log;
+import android.view.View;
+import android.widget.ImageView;
+
+/**
+ * AccountPreference is used to display a username, status and provider icon for an account on
+ * the device.
+ */
+public class AccountPreference extends Preference {
+    private static final String TAG = "AccountPreference";
+    public static final int SYNC_ENABLED = 0; // all know sync adapters are enabled and OK
+    public static final int SYNC_DISABLED = 1; // no sync adapters are enabled
+    public static final int SYNC_ERROR = 2; // one or more sync adapters have a problem
+    private int mStatus;
+    private Account mAccount;
+    private ArrayList<String> mAuthorities;
+    private Drawable mProviderIcon;
+    private ImageView mSyncStatusIcon;
+    private ImageView mProviderIconView;
+
+    public AccountPreference(Context context, Account account, Drawable icon,
+            ArrayList<String> authorities) {
+        super(context);
+        mAccount = account;
+        mAuthorities = authorities;
+        mProviderIcon = icon;
+        setLayoutResource(R.layout.account_preference);
+        setTitle(mAccount.name);
+        setSummary("");
+        // Add account info to the intent for AccountSyncSettings
+        Intent intent = new Intent("android.settings.ACCOUNT_SYNC_SETTINGS");
+        intent.putExtra("account", mAccount);
+        setIntent(intent);
+        setPersistent(false);
+        setSyncStatus(SYNC_DISABLED);
+    }
+
+    public Account getAccount() {
+        return mAccount;
+    }
+
+    public ArrayList<String> getAuthorities() {
+        return mAuthorities;
+    }
+
+    @Override
+    protected void onBindView(View view) {
+        super.onBindView(view);
+        setSummary(getSyncStatusMessage(mStatus));
+        mProviderIconView = (ImageView) view.findViewById(R.id.providerIcon);
+        mProviderIconView.setImageDrawable(mProviderIcon);
+        mSyncStatusIcon = (ImageView) view.findViewById(R.id.syncStatusIcon);
+        mSyncStatusIcon.setImageResource(getSyncStatusIcon(mStatus));
+    }
+
+    public void setProviderIcon(Drawable icon) {
+        mProviderIcon = icon;
+        if (mProviderIconView != null) {
+            mProviderIconView.setImageDrawable(icon);
+        }
+    }
+
+    public void setSyncStatus(int status) {
+        mStatus = status;
+        if (mSyncStatusIcon != null) {
+            mSyncStatusIcon.setImageResource(getSyncStatusIcon(status));
+        }
+        setSummary(getSyncStatusMessage(status));
+    }
+
+    private int getSyncStatusMessage(int status) {
+        int res;
+        switch (status) {
+            case SYNC_ENABLED:
+                res = R.string.sync_enabled;
+                break;
+            case SYNC_DISABLED:
+                res = R.string.sync_disabled;
+                break;
+            case SYNC_ERROR:
+                res = R.string.sync_error;
+                break;
+            default:
+                res = R.string.sync_error;
+                Log.e(TAG, "Unknown sync status: " + status);
+        }
+        return res;
+    }
+
+    private int getSyncStatusIcon(int status) {
+        int res;
+        switch (status) {
+            case SYNC_ENABLED:
+                res = R.drawable.ic_sync_green;
+                break;
+            case SYNC_DISABLED:
+                res = R.drawable.ic_sync_grey;
+                break;
+            case SYNC_ERROR:
+                res = R.drawable.ic_sync_red;
+                break;
+            default:
+                res = R.drawable.ic_sync_red;
+                Log.e(TAG, "Unknown sync status: " + status);
+        }
+        return res;
+    }
+
+    @Override
+    public int compareTo(Preference other) {
+        if (!(other instanceof AccountPreference)) {
+            // Put other preference types above us
+            return 1;
+        }
+        return mAccount.name.compareTo(((AccountPreference) other).mAccount.name);
+    }
+}
diff --git a/src/com/android/settings/AccountPreferenceBase.java b/src/com/android/settings/AccountPreferenceBase.java
new file mode 100644
index 0000000..9b5ab8d
--- /dev/null
+++ b/src/com/android/settings/AccountPreferenceBase.java
@@ -0,0 +1,198 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ *
+ * 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.
+ */
+
+package com.android.settings;
+
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Map;
+
+import com.google.android.collect.Maps;
+
+import android.accounts.Account;
+import android.accounts.AccountManager;
+import android.accounts.AuthenticatorDescription;
+import android.accounts.OnAccountsUpdateListener;
+import android.content.ContentResolver;
+import android.content.Context;
+import android.content.SyncAdapterType;
+import android.content.SyncStatusObserver;
+import android.content.pm.PackageManager;
+import android.graphics.drawable.Drawable;
+import android.os.Bundle;
+import android.os.Handler;
+import android.preference.PreferenceActivity;
+import android.preference.PreferenceScreen;
+import android.util.Log;
+
+class AccountPreferenceBase extends PreferenceActivity implements OnAccountsUpdateListener {
+    protected static final String TAG = "AccountSettings";
+    public static final String AUTHORITIES_FILTER_KEY = "authorities";
+    private Map<String, AuthenticatorDescription> mTypeToAuthDescription
+            = new HashMap<String, AuthenticatorDescription>();
+    protected AuthenticatorDescription[] mAuthDescs;
+    private final Handler mHandler = new Handler();
+    private Object mStatusChangeListenerHandle;
+    private HashMap<String, ArrayList<String>> mAccountTypeToAuthorities = null;
+
+    @Override
+    public void onCreate(Bundle icicle) {
+        super.onCreate(icicle);
+    }
+
+    /**
+     * Overload to handle account updates.
+     */
+    public void onAccountsUpdated(Account[] accounts) {
+
+    }
+
+    /**
+     * Overload to handle authenticator description updates
+     */
+    protected void onAuthDescriptionsUpdated() {
+
+    }
+
+    /**
+     * Overload to handle sync state updates.
+     */
+    protected void onSyncStateUpdated() {
+
+    }
+
+    @Override
+    protected void onResume() {
+        super.onResume();
+        mStatusChangeListenerHandle = ContentResolver.addStatusChangeListener(
+                ContentResolver.SYNC_OBSERVER_TYPE_ACTIVE
+                | ContentResolver.SYNC_OBSERVER_TYPE_STATUS
+                | ContentResolver.SYNC_OBSERVER_TYPE_SETTINGS,
+                mSyncStatusObserver);
+        onSyncStateUpdated();
+    }
+
+    @Override
+    protected void onPause() {
+        super.onPause();
+        ContentResolver.removeStatusChangeListener(mStatusChangeListenerHandle);
+    }
+
+
+    private SyncStatusObserver mSyncStatusObserver = new SyncStatusObserver() {
+        public void onStatusChanged(int which) {
+            mHandler.post(new Runnable() {
+                public void run() {
+                    onSyncStateUpdated();
+                }
+            });
+        }
+    };
+
+    public ArrayList<String> getAuthoritiesForAccountType(String type) {
+        if (mAccountTypeToAuthorities == null) {
+            mAccountTypeToAuthorities = Maps.newHashMap();
+            SyncAdapterType[] syncAdapters = ContentResolver.getSyncAdapterTypes();
+            for (int i = 0, n = syncAdapters.length; i < n; i++) {
+                final SyncAdapterType sa = syncAdapters[i];
+                ArrayList<String> authorities = mAccountTypeToAuthorities.get(sa.accountType);
+                if (authorities == null) {
+                    authorities = new ArrayList<String>();
+                    mAccountTypeToAuthorities.put(sa.accountType, authorities);
+                }
+                Log.d(TAG, "added authority " + sa.authority + " to accountType " + sa.accountType);
+                authorities.add(sa.authority);
+            }
+        }
+        return mAccountTypeToAuthorities.get(type);
+    }
+
+    /**
+     * Gets an icon associated with a particular account type. If none found, return null.
+     * @param accountType the type of account
+     * @return a drawable for the icon or null if one cannot be found.
+     */
+    protected Drawable getDrawableForType(final String accountType) {
+        Drawable icon = null;
+        if (mTypeToAuthDescription.containsKey(accountType)) {
+            try {
+                AuthenticatorDescription desc = (AuthenticatorDescription)
+                        mTypeToAuthDescription.get(accountType);
+                Context authContext = createPackageContext(desc.packageName, 0);
+                icon = authContext.getResources().getDrawable(desc.iconId);
+            } catch (PackageManager.NameNotFoundException e) {
+                // TODO: place holder icon for missing account icons?
+                Log.w(TAG, "No icon for account type " + accountType);
+            }
+        }
+        return icon;
+    }
+
+    /**
+     * Gets the label associated with a particular account type. If none found, return null.
+     * @param accountType the type of account
+     * @return a CharSequence for the label or null if one cannot be found.
+     */
+    protected CharSequence getLabelForType(final String accountType) {
+        CharSequence label = null;
+        if (mTypeToAuthDescription.containsKey(accountType)) {
+             try {
+                 AuthenticatorDescription desc = (AuthenticatorDescription)
+                         mTypeToAuthDescription.get(accountType);
+                 Context authContext = createPackageContext(desc.packageName, 0);
+                 label = authContext.getResources().getText(desc.labelId);
+             } catch (PackageManager.NameNotFoundException e) {
+                 Log.w(TAG, "No label for account type " + ", type " + accountType);
+             }
+        }
+        return label;
+    }
+
+    /**
+     * Gets the preferences.xml file associated with a particular account type.
+     * @param accountType the type of account
+     * @return a PreferenceScreen inflated from accountPreferenceId.
+     */
+    protected PreferenceScreen addPreferencesForType(final String accountType) {
+        PreferenceScreen prefs = null;
+        if (mTypeToAuthDescription.containsKey(accountType)) {
+            AuthenticatorDescription desc = null;
+            try {
+                desc = (AuthenticatorDescription) mTypeToAuthDescription.get(accountType);
+                if (desc != null && desc.accountPreferencesId != 0) {
+                    Context authContext = createPackageContext(desc.packageName, 0);
+                    prefs = getPreferenceManager().inflateFromResource(authContext,
+                            desc.accountPreferencesId, getPreferenceScreen());
+                }
+            } catch (PackageManager.NameNotFoundException e) {
+                Log.w(TAG, "Couldn't load preferences.xml file from " + desc.packageName);
+            }
+        }
+        return prefs;
+    }
+
+    /**
+     * Updates provider icons. Subclasses should call this in onCreate()
+     * and update any UI that depends on AuthenticatorDescriptions in onAuthDescriptionsUpdated().
+     */
+    protected void updateAuthDescriptions() {
+        mAuthDescs = AccountManager.get(this).getAuthenticatorTypes();
+        for (int i = 0; i < mAuthDescs.length; i++) {
+            mTypeToAuthDescription.put(mAuthDescs[i].type, mAuthDescs[i]);
+        }
+        onAuthDescriptionsUpdated();
+    }
+}
diff --git a/src/com/android/settings/AccountSyncSettings.java b/src/com/android/settings/AccountSyncSettings.java
new file mode 100644
index 0000000..e28b9ab
--- /dev/null
+++ b/src/com/android/settings/AccountSyncSettings.java
@@ -0,0 +1,462 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ *
+ * 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.
+ */
+
+package com.android.settings;
+
+import com.android.providers.subscribedfeeds.R;
+import com.google.android.collect.Maps;
+import com.google.android.collect.Lists;
+
+import android.accounts.AccountManager;
+import android.accounts.Account;
+import android.accounts.AccountManagerCallback;
+import android.accounts.AccountManagerFuture;
+import android.accounts.AuthenticatorException;
+import android.accounts.OperationCanceledException;
+import android.app.AlertDialog;
+import android.app.Dialog;
+import android.content.ActiveSyncInfo;
+import android.content.ContentResolver;
+import android.content.Context;
+import android.content.DialogInterface;
+import android.content.Intent;
+import android.content.SyncStatusInfo;
+import android.content.SyncAdapterType;
+import android.content.pm.ProviderInfo;
+import android.net.ConnectivityManager;
+import android.os.Bundle;
+import android.text.TextUtils;
+import android.text.format.DateFormat;
+import android.preference.Preference;
+import android.preference.PreferenceScreen;
+import android.view.Menu;
+import android.view.MenuItem;
+import android.view.View;
+import android.view.View.OnClickListener;
+import android.widget.Button;
+import android.widget.ImageView;
+import android.widget.TextView;
+import android.util.Log;
+
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.HashMap;
+
+public class AccountSyncSettings extends AccountPreferenceBase implements OnClickListener {
+    private static final String ACCOUNT_KEY = "account";
+    private static final String TAG = "SyncSettings";
+    private static final String CHANGE_PASSWORD_KEY = "changePassword";
+    private static final int MENU_SYNC_NOW_ID = Menu.FIRST;
+    private static final int MENU_SYNC_CANCEL_ID = Menu.FIRST + 1;
+    private static final int REALLY_REMOVE_DIALOG = 100;
+    private static final int FAILED_REMOVAL_DIALOG = 101;
+    private static final int CANT_DO_ONETIME_SYNC_DIALOG = 102;
+    private TextView mUserId;
+    private TextView mProviderId;
+    private ImageView mProviderIcon;
+    private TextView mErrorInfoView;
+    protected View mRemoveAccountArea;
+    private java.text.DateFormat mDateFormat;
+    private java.text.DateFormat mTimeFormat;
+    private Preference mAuthenticatorPreferences;
+    private Account mAccount;
+    // List of all accounts, updated when accounts are added/removed
+    // We need to re-scan the accounts on sync events, in case sync state changes.
+    private Account[] mAccounts;
+    private Button mRemoveAccountButton;
+    private ArrayList<SyncStateCheckBoxPreference> mCheckBoxes =
+                new ArrayList<SyncStateCheckBoxPreference>();
+    private ArrayList<String> mInvisibleAdapters = Lists.newArrayList();
+
+    public void onClick(View v) {
+        if (v == mRemoveAccountButton) {
+            showDialog(REALLY_REMOVE_DIALOG);
+        }
+    }
+
+    @Override
+    protected Dialog onCreateDialog(final int id) {
+        Dialog dialog = null;
+        if (id == REALLY_REMOVE_DIALOG) {
+            dialog = new AlertDialog.Builder(this)
+                .setTitle(R.string.really_remove_account_title)
+                .setMessage(R.string.really_remove_account_message)
+                .setNegativeButton(android.R.string.cancel, null)
+                .setPositiveButton(R.string.remove_account_label,
+                        new DialogInterface.OnClickListener() {
+                    public void onClick(DialogInterface dialog, int which) {
+                        AccountManager.get(AccountSyncSettings.this).removeAccount(mAccount,
+                                new AccountManagerCallback<Boolean>() {
+                            public void run(AccountManagerFuture<Boolean> future) {
+                                boolean failed = true;
+                                try {
+                                    if (future.getResult() == true) {
+                                        failed = false;
+                                    }
+                                } catch (OperationCanceledException e) {
+                                    // handled below
+                                } catch (IOException e) {
+                                    // handled below
+                                } catch (AuthenticatorException e) {
+                                    // handled below
+                                }
+                                if (failed) {
+                                    showDialog(FAILED_REMOVAL_DIALOG);
+                                } else {
+                                    finish();
+                                }
+                            }
+                        }, null);
+                    }
+                })
+                .create();
+        } else if (id == FAILED_REMOVAL_DIALOG) {
+            dialog = new AlertDialog.Builder(this)
+                .setTitle(R.string.really_remove_account_title)
+                .setPositiveButton(android.R.string.ok, null)
+                .setMessage(R.string.remove_account_failed)
+                .create();
+        } else if (id == CANT_DO_ONETIME_SYNC_DIALOG) {
+            dialog = new AlertDialog.Builder(this)
+                .setTitle(R.string.cant_sync_dialog_title)
+                .setMessage(R.string.cant_sync_dialog_message)
+                .setPositiveButton(android.R.string.ok, null)
+                .create();
+        }
+        return dialog;
+    }
+
+    @Override
+    public void onCreate(Bundle icicle) {
+        super.onCreate(icicle);
+
+        setContentView(R.layout.account_sync_screen);
+        addPreferencesFromResource(R.xml.account_sync_settings);
+
+        mErrorInfoView = (TextView) findViewById(R.id.sync_settings_error_info);
+        mErrorInfoView.setVisibility(View.GONE);
+        mErrorInfoView.setCompoundDrawablesWithIntrinsicBounds(
+                getResources().getDrawable(R.drawable.ic_list_syncerror), null, null, null);
+
+        mUserId = (TextView) findViewById(R.id.user_id);
+        mProviderId = (TextView) findViewById(R.id.provider_id);
+        mProviderIcon = (ImageView) findViewById(R.id.provider_icon);
+        mRemoveAccountArea = (View) findViewById(R.id.remove_account_area);
+        mRemoveAccountButton = (Button) findViewById(R.id.remove_account_button);
+        mRemoveAccountButton.setOnClickListener(this);
+
+
+        mDateFormat = DateFormat.getDateFormat(this);
+        mTimeFormat = DateFormat.getTimeFormat(this);
+
+        mAccount = (Account) getIntent().getParcelableExtra(ACCOUNT_KEY);
+        if (mAccount != null) {
+            Log.v(TAG, "Got account: " + mAccount);
+            mUserId.setText(mAccount.name);
+            mProviderId.setText(mAccount.type);
+        }
+        AccountManager.get(this).addOnAccountsUpdatedListener(this, null, false);
+        updateAuthDescriptions();
+        onAccountsUpdated(AccountManager.get(this).getAccounts());
+    }
+    
+    @Override
+    protected void onDestroy() {
+        super.onDestroy();
+        AccountManager.get(this).removeOnAccountsUpdatedListener(this);
+    }
+
+    private void addSyncStateCheckBox(Account account, String authority) {
+        SyncStateCheckBoxPreference item =
+                new SyncStateCheckBoxPreference(this, account, authority);
+        item.setPersistent(false);
+        final ProviderInfo providerInfo = getPackageManager().resolveContentProvider(authority, 0);
+        CharSequence providerLabel = providerInfo != null
+                ? providerInfo.loadLabel(getPackageManager()) : null;
+        if (TextUtils.isEmpty(providerLabel)) {
+            Log.e(TAG, "Provider needs a label for authority '" + authority + "'");
+            providerLabel = authority;
+        }
+        String title = getString(R.string.sync_item_title, providerLabel);
+        item.setTitle(title);
+        item.setKey(authority);
+        getPreferenceScreen().addPreference(item);
+        mCheckBoxes.add(item);
+    }
+
+    @Override
+    public boolean onCreateOptionsMenu(Menu menu) {
+        super.onCreateOptionsMenu(menu);
+        menu.add(0, MENU_SYNC_NOW_ID, 0, getString(R.string.sync_menu_sync_now))
+                .setIcon(com.android.internal.R.drawable.ic_menu_refresh);
+        menu.add(0, MENU_SYNC_CANCEL_ID, 0, getString(R.string.sync_menu_sync_cancel))
+                .setIcon(android.R.drawable.ic_menu_close_clear_cancel);
+        return true;
+    }
+
+    @Override
+    public boolean onPrepareOptionsMenu(Menu menu) {
+        super.onPrepareOptionsMenu(menu);
+        boolean syncActive = ContentResolver.getActiveSync() != null;
+        menu.findItem(MENU_SYNC_NOW_ID).setVisible(!syncActive);
+        menu.findItem(MENU_SYNC_CANCEL_ID).setVisible(syncActive);
+        return true;
+    }
+
+    @Override
+    public boolean onOptionsItemSelected(MenuItem item) {
+        switch (item.getItemId()) {
+            case MENU_SYNC_NOW_ID:
+                startSyncForEnabledProviders();
+                return true;
+            case MENU_SYNC_CANCEL_ID:
+                cancelSyncForEnabledProviders();
+                return true;
+        }
+        return super.onOptionsItemSelected(item);
+    }
+
+    @Override
+    public boolean onPreferenceTreeClick(PreferenceScreen preferences, Preference preference) {
+        if (preference instanceof SyncStateCheckBoxPreference) {
+            SyncStateCheckBoxPreference syncPref = (SyncStateCheckBoxPreference) preference;
+            String authority = syncPref.getAuthority();
+            Account account = syncPref.getAccount();
+            boolean syncAutomatically = ContentResolver.getSyncAutomatically(account, authority);
+            if (syncPref.isOneTimeSyncMode()) {
+                if (syncAutomatically) {
+                    requestOrCancelSync(account, authority, true);
+                } else {
+                    showDialog(CANT_DO_ONETIME_SYNC_DIALOG);
+                }
+            } else {
+                boolean syncOn = syncPref.isChecked();
+                boolean oldSyncState = syncAutomatically;
+                if (syncOn != oldSyncState) {
+                    // if we're enabling sync, this will request a sync as well
+                    ContentResolver.setSyncAutomatically(account, authority, syncOn);
+                    // if the master sync switch is off, the request above will
+                    // get dropped.  when the user clicks on this toggle,
+                    // we want to force the sync, however.
+                    if (!ContentResolver.getMasterSyncAutomatically() || !syncOn) {
+                        requestOrCancelSync(account, authority, syncOn);
+                    }
+                }
+            }
+            return true;
+        } else {
+            return super.onPreferenceTreeClick(preferences, preference);
+        }
+    }
+
+    private void startSyncForEnabledProviders() {
+        requestOrCancelSyncForEnabledProviders(true /* start them */);
+    }
+
+    private void cancelSyncForEnabledProviders() {
+        requestOrCancelSyncForEnabledProviders(false /* cancel them */);
+    }
+
+    private void requestOrCancelSyncForEnabledProviders(boolean startSync) {
+        // sync everything that the user has enabled
+        int count = getPreferenceScreen().getPreferenceCount();
+        for (int i = 0; i < count; i++) {
+            Preference pref = getPreferenceScreen().getPreference(i);
+            if (! (pref instanceof SyncStateCheckBoxPreference)) {
+                continue;
+            }
+            SyncStateCheckBoxPreference syncPref = (SyncStateCheckBoxPreference) pref;
+            if (!syncPref.isChecked()) {
+                continue;
+            }
+            requestOrCancelSync(syncPref.getAccount(), syncPref.getAuthority(), startSync);
+        }
+        // plus whatever the system needs to sync, e.g., invisible sync adapters
+        if (mAccount != null) {
+            for (String authority : mInvisibleAdapters) {
+                requestOrCancelSync(mAccount, authority, startSync);
+            }
+        }
+    }
+
+    private void requestOrCancelSync(Account account, String authority, boolean flag) {
+        if (flag) {
+            Bundle extras = new Bundle();
+            extras.putBoolean(ContentResolver.SYNC_EXTRAS_MANUAL, true);
+            ContentResolver.requestSync(account, authority, extras);
+        } else {
+            ContentResolver.cancelSync(account, authority);
+        }
+    }
+
+    @Override
+    protected void onSyncStateUpdated() {
+        // iterate over all the preferences, setting the state properly for each
+        Date date = new Date();
+        ActiveSyncInfo activeSyncValues = ContentResolver.getActiveSync();
+        boolean syncIsFailing = false;
+
+        // Refresh the sync status checkboxes - some syncs may have become active.
+        updateAccountCheckboxes(mAccounts);
+
+        for (int i = 0, count = getPreferenceScreen().getPreferenceCount(); i < count; i++) {
+            Preference pref = getPreferenceScreen().getPreference(i);
+            if (! (pref instanceof SyncStateCheckBoxPreference)) {
+                continue;
+            }
+            SyncStateCheckBoxPreference syncPref = (SyncStateCheckBoxPreference) pref;
+
+            String authority = syncPref.getAuthority();
+            Account account = syncPref.getAccount();
+
+            SyncStatusInfo status = ContentResolver.getSyncStatus(account, authority);
+            boolean syncEnabled = ContentResolver.getSyncAutomatically(account, authority);
+            boolean authorityIsPending = status == null ? false : status.pending;
+            boolean initialSync = status == null ? false : status.initialize;
+
+            boolean activelySyncing = activeSyncValues != null
+                    && activeSyncValues.account.equals(account)
+                    && activeSyncValues.authority.equals(authority);
+            boolean lastSyncFailed = status != null
+                    && status.lastFailureTime != 0
+                    && status.getLastFailureMesgAsInt(0)
+                       != ContentResolver.SYNC_ERROR_SYNC_ALREADY_IN_PROGRESS;
+            if (!syncEnabled) lastSyncFailed = false;
+            if (lastSyncFailed && !activelySyncing && !authorityIsPending) {
+                syncIsFailing = true;
+            }
+            if (Log.isLoggable(TAG, Log.DEBUG)) {
+                Log.d(TAG, "Update sync status: " + account + " " + authority +
+                        " active = " + activelySyncing + " pend =" +  authorityIsPending);
+            }
+
+            final long successEndTime = (status == null) ? 0 : status.lastSuccessTime;
+            if (successEndTime != 0) {
+                date.setTime(successEndTime);
+                final String timeString = mDateFormat.format(date) + " "
+                        + mTimeFormat.format(date);
+                syncPref.setSummary(timeString);
+            } else {
+                syncPref.setSummary("");
+            }
+            int syncState = ContentResolver.getIsSyncable(account, authority);
+
+            syncPref.setActive(activelySyncing && (syncState >= 0) &&
+                    !initialSync);
+            syncPref.setPending(authorityIsPending && (syncState >= 0) &&
+                    !initialSync);
+
+            syncPref.setFailed(lastSyncFailed);
+            ConnectivityManager connManager =
+                (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE);
+            final boolean masterSyncAutomatically = ContentResolver.getMasterSyncAutomatically();
+            final boolean backgroundDataEnabled = connManager.getBackgroundDataSetting();
+            syncPref.setOneTimeSyncMode(!masterSyncAutomatically || !backgroundDataEnabled);
+            syncPref.setChecked(syncEnabled);
+        }
+        mErrorInfoView.setVisibility(syncIsFailing ? View.VISIBLE : View.GONE);
+    }
+
+    @Override
+    public void onAccountsUpdated(Account[] accounts) {
+        super.onAccountsUpdated(accounts);
+        mAccounts = accounts;
+        updateAccountCheckboxes(accounts);
+        onSyncStateUpdated();
+    }
+
+    private void updateAccountCheckboxes(Account[] accounts) {
+        mInvisibleAdapters.clear();
+
+        SyncAdapterType[] syncAdapters = ContentResolver.getSyncAdapterTypes();
+        HashMap<String, ArrayList<String>> accountTypeToAuthorities =
+            Maps.newHashMap();
+        for (int i = 0, n = syncAdapters.length; i < n; i++) {
+            final SyncAdapterType sa = syncAdapters[i];
+            if (sa.isUserVisible()) {
+                ArrayList<String> authorities = accountTypeToAuthorities.get(sa.accountType);
+                if (authorities == null) {
+                    authorities = new ArrayList<String>();
+                    accountTypeToAuthorities.put(sa.accountType, authorities);
+                }
+                if (Log.isLoggable(TAG, Log.DEBUG)) {
+                    Log.d(TAG, "onAccountUpdated: added authority " + sa.authority
+                            + " to accountType " + sa.accountType);
+                }
+                authorities.add(sa.authority);
+            } else {
+                // keep track of invisible sync adapters, so sync now forces
+                // them to sync as well.
+                mInvisibleAdapters.add(sa.authority);
+            }
+        }
+
+        for (int i = 0, n = mCheckBoxes.size(); i < n; i++) {
+            getPreferenceScreen().removePreference(mCheckBoxes.get(i));
+        }
+        mCheckBoxes.clear();
+
+        for (int i = 0, n = accounts.length; i < n; i++) {
+            final Account account = accounts[i];
+            Log.d(TAG, "looking for sync adapters that match account " + account);
+            final ArrayList<String> authorities = accountTypeToAuthorities.get(account.type);
+            if (authorities != null && (mAccount == null || mAccount.equals(account))) {
+                for (int j = 0, m = authorities.size(); j < m; j++) {
+                    final String authority = authorities.get(j);
+                    // We could check services here....
+                    int syncState = ContentResolver.getIsSyncable(account, authority);
+                    if (Log.isLoggable(TAG, Log.DEBUG)) {
+                        Log.d(TAG, "  found authority " + authority + " " + syncState);
+                    }
+                    if (syncState > 0) {
+                        addSyncStateCheckBox(account, authority);
+                    }
+                }
+            }
+        }
+    }
+
+    /**
+     * Updates the titlebar with an icon for the provider type.
+     */
+    @Override
+    protected void onAuthDescriptionsUpdated() {
+        super.onAuthDescriptionsUpdated();
+        getPreferenceScreen().removeAll();
+        mProviderIcon.setImageDrawable(getDrawableForType(mAccount.type));
+        mProviderId.setText(getLabelForType(mAccount.type));
+        PreferenceScreen prefs = addPreferencesForType(mAccount.type);
+        if (prefs != null) {
+            updatePreferenceIntents(prefs);
+        }
+        addPreferencesFromResource(R.xml.account_sync_settings);
+    }
+
+    private void updatePreferenceIntents(PreferenceScreen prefs) {
+        for (int i = 0; i < prefs.getPreferenceCount(); i++) {
+            Intent intent = prefs.getPreference(i).getIntent();
+            if (intent != null) {
+                intent.putExtra(ACCOUNT_KEY, mAccount);
+                // This is somewhat of a hack. Since the preference screen we're accessing comes
+                // from another package, we need to modify the intent to launch it with
+                // FLAG_ACTIVITY_NEW_TASK.
+                // TODO: Do something smarter if we ever have PreferenceScreens of our own.
+                intent.setFlags(intent.getFlags() | Intent.FLAG_ACTIVITY_NEW_TASK);
+            }
+        }
+    }
+}
diff --git a/src/com/android/settings/AccountSyncSettingsInAddAccount.java b/src/com/android/settings/AccountSyncSettingsInAddAccount.java
new file mode 100644
index 0000000..4a23e7c
--- /dev/null
+++ b/src/com/android/settings/AccountSyncSettingsInAddAccount.java
@@ -0,0 +1,33 @@
+package com.android.settings;
+
+import com.android.providers.subscribedfeeds.R;
+
+import android.os.Bundle;
+import android.view.View;
+import android.view.View.OnClickListener;
+
+/**
+ * This is AccountSyncSettings with 'remove account' button always gone and 
+ * a wizard-like button bar to complete the activity.
+ *
+ */
+public class AccountSyncSettingsInAddAccount extends AccountSyncSettings 
+        implements OnClickListener {
+    private View mFinishArea;
+    private View mFinishButton;
+
+    @Override
+    public void onCreate(Bundle icicle) {
+        super.onCreate(icicle);
+        
+        mRemoveAccountArea.setVisibility(View.GONE);
+        mFinishArea = (View) findViewById(R.id.finish_button_area);
+        mFinishArea.setVisibility(View.VISIBLE);
+        mFinishButton = (View) findViewById(R.id.finish_button);
+        mFinishButton.setOnClickListener(this);
+    }
+
+    public void onClick(View v) {
+        finish();
+    }
+}
diff --git a/src/com/android/settings/AddAccountSettings.java b/src/com/android/settings/AddAccountSettings.java
new file mode 100644
index 0000000..564f4c7
--- /dev/null
+++ b/src/com/android/settings/AddAccountSettings.java
@@ -0,0 +1,150 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ *
+ * 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.
+ */
+
+package com.android.settings;
+
+import com.android.providers.subscribedfeeds.R;
+
+import android.accounts.AccountManager;
+import android.accounts.AuthenticatorException;
+import android.accounts.AccountManagerFuture;
+import android.accounts.OperationCanceledException;
+import android.accounts.AccountManagerCallback;
+import android.graphics.drawable.Drawable;
+import android.os.Bundle;
+import android.preference.Preference;
+import android.preference.PreferenceGroup;
+import android.preference.PreferenceScreen;
+import android.util.Log;
+
+import java.io.IOException;
+import java.util.ArrayList;
+
+public class AddAccountSettings extends AccountPreferenceBase {
+    private static final String TAG = "AddAccount";
+    private String[] mAuthorities;
+    private PreferenceGroup mAddAccountGroup;
+    private ArrayList<ProviderEntry> mProviderList = new ArrayList<ProviderEntry>();;
+
+    private static class ProviderEntry {
+        private final CharSequence name;
+        private final String type;
+        ProviderEntry(CharSequence providerName, String accountType) {
+            name = providerName;
+            type = accountType;
+        }
+    }
+
+    @Override
+    public void onCreate(Bundle icicle) {
+        super.onCreate(icicle);
+
+        setContentView(R.layout.add_account_screen);
+        addPreferencesFromResource(R.xml.add_account_settings);
+        mAuthorities = getIntent().getStringArrayExtra(AUTHORITIES_FILTER_KEY);
+        mAddAccountGroup = getPreferenceScreen();
+        updateAuthDescriptions();
+    }
+
+    @Override
+    protected void onAuthDescriptionsUpdated() {
+        // Create list of providers to show on preference screen
+        for (int i = 0; i < mAuthDescs.length; i++) {
+            String accountType = mAuthDescs[i].type;
+            CharSequence providerName = getLabelForType(accountType);
+
+            // Skip preferences for authorities not specified. If no authorities specified,
+            // then include them all.
+            ArrayList<String> accountAuths = getAuthoritiesForAccountType(accountType);
+            boolean addAccountPref = true;
+            if (mAuthorities != null && mAuthorities.length > 0) {
+                addAccountPref = false;
+                for (int k = 0; k < mAuthorities.length; k++) {
+                    if (accountAuths.contains(mAuthorities[k])) {
+                        addAccountPref = true;
+                        break;
+                    }
+                }
+            }
+            if (addAccountPref) {
+                mProviderList.add(new ProviderEntry(providerName, accountType));
+            } else {
+                Log.v(TAG, "Skipped pref " + providerName + ": has no authority we need");
+            }
+        }
+
+        if (mProviderList.size() == 1) {
+            // If there's only one provider that matches, just run it.
+            addAccount(mProviderList.get(0).type);
+            finish();
+        } else if (mProviderList.size() > 0) {
+            mAddAccountGroup.removeAll();
+            for (ProviderEntry pref : mProviderList) {
+                Drawable drawable = getDrawableForType(pref.type);
+                ProviderPreference p = new ProviderPreference(this, pref.type, drawable, pref.name);
+                mAddAccountGroup.addPreference(p);
+            }
+        } else {
+            String auths = new String();
+            for (String a : mAuthorities) auths += a + " ";
+            Log.w(TAG, "No providers found for authorities: " + auths);
+        }
+    }
+
+    private AccountManagerCallback<Bundle> mCallback = new AccountManagerCallback<Bundle>() {
+        public void run(AccountManagerFuture<Bundle> future) {
+            boolean accountAdded = false;
+            try {
+                Bundle bundle = future.getResult();
+                bundle.keySet();
+                accountAdded = true;
+                Log.d(TAG, "account added: " + bundle);
+            } catch (OperationCanceledException e) {
+                Log.d(TAG, "addAccount was canceled");
+            } catch (IOException e) {
+                Log.d(TAG, "addAccount failed: " + e);
+            } catch (AuthenticatorException e) {
+                Log.d(TAG, "addAccount failed: " + e);
+            } finally {
+                if (mProviderList.size() <= 1 || accountAdded) {
+                    finish();
+                }
+            }
+        }
+    };
+
+    @Override
+    public boolean onPreferenceTreeClick(PreferenceScreen preferences, Preference preference) {
+        if (preference instanceof ProviderPreference) {
+            ProviderPreference pref = (ProviderPreference) preference;
+            Log.v(TAG, "Attempting to add account of type " + pref.getAccountType());
+            addAccount(pref.getAccountType());
+            finish();
+        }
+        return true;
+    }
+
+    private void addAccount(String accountType) {
+        AccountManager.get(this).addAccount(
+                accountType,
+                null, /* authTokenType */
+                null, /* requiredFeatures */
+                null, /* addAccountOptions */
+                this,
+                mCallback,
+                null /* handler */);
+    }
+}
diff --git a/src/com/android/settings/ManageAccountsSettings.java b/src/com/android/settings/ManageAccountsSettings.java
new file mode 100644
index 0000000..7b672f1
--- /dev/null
+++ b/src/com/android/settings/ManageAccountsSettings.java
@@ -0,0 +1,264 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ *
+ * 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.
+ */
+
+package com.android.settings;
+
+import com.android.providers.subscribedfeeds.R;
+import com.google.android.collect.Maps;
+
+import android.accounts.AccountManager;
+import android.accounts.Account;
+import android.app.AlertDialog;
+import android.app.Dialog;
+import android.content.ActiveSyncInfo;
+import android.content.ContentResolver;
+import android.content.Context;
+import android.content.DialogInterface;
+import android.content.Intent;
+import android.content.SyncAdapterType;
+import android.content.SyncStatusInfo;
+import android.graphics.drawable.Drawable;
+import android.net.ConnectivityManager;
+import android.os.Bundle;
+import android.text.format.DateFormat;
+import android.preference.CheckBoxPreference;
+import android.preference.Preference;
+import android.preference.PreferenceCategory;
+import android.preference.PreferenceScreen;
+import android.view.Menu;
+import android.view.MenuItem;
+import android.view.View;
+import android.widget.Button;
+import android.widget.TextView;
+
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.HashMap;
+import java.util.HashSet;
+
+public class ManageAccountsSettings extends AccountPreferenceBase implements View.OnClickListener {
+    private static final String AUTO_SYNC_CHECKBOX_KEY = "syncAutomaticallyCheckBox";
+    private static final String MANAGE_ACCOUNTS_CATEGORY_KEY = "manageAccountsCategory";
+    private static final String BACKGROUND_DATA_CHECKBOX_KEY = "backgroundDataCheckBox";
+    private static final int DIALOG_DISABLE_BACKGROUND_DATA = 1;
+
+    private CheckBoxPreference mBackgroundDataCheckBox;
+    private PreferenceCategory mManageAccountsCategory;
+    private String[] mAuthorities;
+    private TextView mErrorInfoView;
+    private Button mAddAccountButton;
+    private CheckBoxPreference mAutoSyncCheckbox;
+
+    @Override
+    public void onCreate(Bundle icicle) {
+        super.onCreate(icicle);
+
+        setContentView(R.layout.manage_accounts_screen);
+        addPreferencesFromResource(R.xml.manage_accounts_settings);
+
+        mErrorInfoView = (TextView)findViewById(R.id.sync_settings_error_info);
+        mErrorInfoView.setVisibility(View.GONE);
+        mErrorInfoView.setCompoundDrawablesWithIntrinsicBounds(
+                getResources().getDrawable(R.drawable.ic_list_syncerror), null, null, null);
+
+        mBackgroundDataCheckBox = (CheckBoxPreference) findPreference(BACKGROUND_DATA_CHECKBOX_KEY);
+        mAutoSyncCheckbox = (CheckBoxPreference) findPreference(AUTO_SYNC_CHECKBOX_KEY);
+
+        mManageAccountsCategory =
+                (PreferenceCategory) findPreference(MANAGE_ACCOUNTS_CATEGORY_KEY);
+        mAuthorities = getIntent().getStringArrayExtra(AUTHORITIES_FILTER_KEY);
+        mAddAccountButton = (Button) findViewById(R.id.add_account_button);
+        mAddAccountButton.setOnClickListener(this);
+
+        AccountManager.get(this).addOnAccountsUpdatedListener(this, null, true);
+        updateAuthDescriptions();
+    }
+
+    @Override
+    public void onDestroy() {
+        AccountManager.get(this).removeOnAccountsUpdatedListener(this);
+        super.onDestroy();
+    }
+
+    @Override
+    public boolean onPreferenceTreeClick(PreferenceScreen preferences, Preference preference) {
+        if (preference == mBackgroundDataCheckBox) {
+            ConnectivityManager connManager =
+                    (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE);
+            boolean oldBackgroundDataSetting = connManager.getBackgroundDataSetting();
+            boolean backgroundDataSetting = mBackgroundDataCheckBox.isChecked();
+            if (oldBackgroundDataSetting != backgroundDataSetting) {
+                if (backgroundDataSetting) {
+                    setBackgroundDataInt(true);
+                    onSyncStateUpdated();
+                } else {
+                    // This will get unchecked only if the user hits "Ok"
+                    mBackgroundDataCheckBox.setChecked(true);
+                    showDialog(DIALOG_DISABLE_BACKGROUND_DATA);
+                }
+            }
+        } else if (preference == mAutoSyncCheckbox) {
+            ContentResolver.setMasterSyncAutomatically(mAutoSyncCheckbox.isChecked());
+            onSyncStateUpdated();
+        } else {
+            return false;
+        }
+        return true;
+    }
+
+    @Override
+    protected Dialog onCreateDialog(int id) {
+        switch (id) {
+            case DIALOG_DISABLE_BACKGROUND_DATA:
+                final CheckBoxPreference pref =
+                    (CheckBoxPreference) findPreference(BACKGROUND_DATA_CHECKBOX_KEY);
+                return new AlertDialog.Builder(this)
+                        .setTitle(R.string.background_data_dialog_title)
+                        .setIcon(android.R.drawable.ic_dialog_alert)
+                        .setMessage(R.string.background_data_dialog_message)
+                        .setPositiveButton(android.R.string.ok,
+                                    new DialogInterface.OnClickListener() {
+                                public void onClick(DialogInterface dialog, int which) {
+                                    setBackgroundDataInt(false);
+                                    pref.setChecked(false);
+                                    onSyncStateUpdated();
+                                }
+                            })
+                        .setNegativeButton(android.R.string.cancel, null)
+                        .create();
+        }
+
+        return null;
+    }
+
+    private void setBackgroundDataInt(boolean enabled) {
+        ConnectivityManager connManager =
+                (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE);
+        connManager.setBackgroundDataSetting(enabled);
+    }
+
+    @Override
+    protected void onSyncStateUpdated() {
+        // Set background connection state
+        ConnectivityManager connManager =
+                (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE);
+        boolean backgroundDataSetting = connManager.getBackgroundDataSetting();
+        mBackgroundDataCheckBox.setChecked(backgroundDataSetting);
+        boolean masterSyncAutomatically = ContentResolver.getMasterSyncAutomatically();
+        mAutoSyncCheckbox.setChecked(masterSyncAutomatically);
+
+        // iterate over all the preferences, setting the state properly for each
+        ActiveSyncInfo activeSyncValues = ContentResolver.getActiveSync();
+
+        boolean anySyncFailed = false; // true if sync on any account failed
+
+        // only track userfacing sync adapters when deciding if account is synced or not
+        final SyncAdapterType[] syncAdapters = ContentResolver.getSyncAdapterTypes();
+        HashSet<String> userFacing = new HashSet<String>();
+        for (int k = 0, n = syncAdapters.length; k < n; k++) {
+            final SyncAdapterType sa = syncAdapters[k];
+            if (sa.isUserVisible()) {
+                userFacing.add(sa.authority);
+            }
+        }
+        for (int i = 0, count = mManageAccountsCategory.getPreferenceCount(); i < count; i++) {
+            Preference pref = mManageAccountsCategory.getPreference(i);
+            if (! (pref instanceof AccountPreference)) {
+                continue;
+            }
+
+            AccountPreference accountPref = (AccountPreference) pref;
+            Account account = accountPref.getAccount();
+            int syncCount = 0;
+            boolean syncIsFailing = false;
+            for (String authority : accountPref.getAuthorities()) {
+                SyncStatusInfo status = ContentResolver.getSyncStatus(account, authority);
+                boolean syncEnabled = ContentResolver.getSyncAutomatically(account, authority)
+                        && masterSyncAutomatically
+                        && backgroundDataSetting;
+                boolean authorityIsPending = ContentResolver.isSyncPending(account, authority);
+                boolean activelySyncing = activeSyncValues != null
+                        && activeSyncValues.authority.equals(authority)
+                        && activeSyncValues.account.equals(account);
+                boolean lastSyncFailed = status != null
+                        && syncEnabled
+                        && status.lastFailureTime != 0
+                        && status.getLastFailureMesgAsInt(0)
+                           != ContentResolver.SYNC_ERROR_SYNC_ALREADY_IN_PROGRESS;
+                if (lastSyncFailed && !activelySyncing && !authorityIsPending) {
+                    syncIsFailing = true;
+                    anySyncFailed = true;
+                }
+                syncCount += syncEnabled && userFacing.contains(authority) ? 1 : 0;
+            }
+            int syncStatus = AccountPreference.SYNC_DISABLED;
+            if (syncIsFailing) {
+                syncStatus = AccountPreference.SYNC_ERROR;
+            } else if (syncCount == 0) {
+                syncStatus = AccountPreference.SYNC_DISABLED;
+            } else if (syncCount > 0) {
+                syncStatus = AccountPreference.SYNC_ENABLED;
+            }
+            accountPref.setSyncStatus(syncStatus);
+        }
+
+        mErrorInfoView.setVisibility(anySyncFailed ? View.VISIBLE : View.GONE);
+    }
+
+    public void onAccountsUpdated(Account[] accounts) {
+        mManageAccountsCategory.removeAll();
+        for (int i = 0, n = accounts.length; i < n; i++) {
+            final Account account = accounts[i];
+            final ArrayList<String> auths = getAuthoritiesForAccountType(account.type);
+
+            boolean showAccount = true;
+            if (mAuthorities != null) {
+                showAccount = false;
+                for (String requestedAuthority : mAuthorities) {
+                    if (auths.contains(requestedAuthority)) {
+                        showAccount = true;
+                        break;
+                    }
+                }
+            }
+
+            if (showAccount) {
+                Drawable icon = getDrawableForType(account.type);
+                AccountPreference preference = new AccountPreference(this, account, icon, auths);
+                mManageAccountsCategory.addPreference(preference);
+            }
+        }
+        onSyncStateUpdated();
+    }
+
+    @Override
+    protected void onAuthDescriptionsUpdated() {
+        // Update account icons for all account preference items
+        for (int i = 0; i < mManageAccountsCategory.getPreferenceCount(); i++) {
+            AccountPreference pref = (AccountPreference) mManageAccountsCategory.getPreference(i);
+            pref.setProviderIcon(getDrawableForType(pref.getAccount().type));
+            pref.setSummary(getLabelForType(pref.getAccount().type));
+        }
+    }
+
+    public void onClick(View v) {
+        if (v == mAddAccountButton) {
+            Intent intent = new Intent("android.settings.ADD_ACCOUNT_SETTINGS");
+            intent.putExtra(AUTHORITIES_FILTER_KEY, mAuthorities);
+            startActivity(intent);
+        }
+    }
+}
diff --git a/src/com/android/settings/ProviderPreference.java b/src/com/android/settings/ProviderPreference.java
new file mode 100644
index 0000000..2eb1f5b
--- /dev/null
+++ b/src/com/android/settings/ProviderPreference.java
@@ -0,0 +1,60 @@
+/*
+ * Copyright (C) 2008 The Android Open Source Project
+ *
+ * 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.
+ */
+
+package com.android.settings;
+
+import com.android.providers.subscribedfeeds.R;
+
+import android.content.Context;
+import android.graphics.drawable.Drawable;
+import android.preference.Preference;
+import android.view.View;
+import android.widget.ImageView;
+
+/**
+ * ProviderPreference is used to display an image to the left of a provider name.
+ * The preference ultimately calls AccountManager.addAccount() for the account type.
+ */
+public class ProviderPreference extends Preference {
+    private Drawable mProviderIcon;
+    private ImageView mProviderIconView;
+    private CharSequence mProviderName;
+    private String mAccountType;
+
+    public ProviderPreference(Context context, String accountType, Drawable icon, CharSequence providerName) {
+        super(context);
+        mAccountType = accountType;
+        mProviderIcon = icon;
+        mProviderName = providerName;
+        setLayoutResource(R.layout.provider_preference);
+        setPersistent(false);
+        setTitle(mProviderName);
+        //setSummary(mProviderName);
+    }
+
+    @Override
+    protected void onBindView(View view) {
+        super.onBindView(view);
+        mProviderIconView = (ImageView) view.findViewById(R.id.providerIcon);
+        mProviderIconView.setImageDrawable(mProviderIcon);
+        setTitle(mProviderName);
+        //setSummary(mProviderName);
+    }
+
+    public String getAccountType() {
+        return mAccountType;
+    }
+}
diff --git a/src/com/android/settings/SyncActivityTooManyDeletes.java b/src/com/android/settings/SyncActivityTooManyDeletes.java
index 3195ea3..61ac59d 100644
--- a/src/com/android/settings/SyncActivityTooManyDeletes.java
+++ b/src/com/android/settings/SyncActivityTooManyDeletes.java
@@ -18,9 +18,9 @@
 
 import com.android.providers.subscribedfeeds.R;
 
+import android.accounts.Account;
 import android.app.Activity;
 import android.content.ContentResolver;
-import android.net.Uri;
 import android.os.Bundle;
 import android.view.View;
 import android.view.ViewGroup;
@@ -40,7 +40,8 @@
         implements AdapterView.OnItemClickListener {
 
     private long mNumDeletes;
-    private String mAccount;
+    private Account mAccount;
+    private String mAuthority;
     private String mProvider;
 
     @Override
@@ -54,7 +55,8 @@
         }
 
         mNumDeletes = extras.getLong("numDeletes");
-        mAccount = extras.getString("account");
+        mAccount = (Account) extras.getParcelable("account");
+        mAuthority = extras.getString("authority");
         mProvider = extras.getString("provider");
 
         // the order of these must match up with the constants for position used in onItemClick
@@ -78,7 +80,7 @@
         CharSequence tooManyDeletesDescFormat =
                 getResources().getText(R.string.sync_too_many_deletes_desc);
         textView.setText(String.format(tooManyDeletesDescFormat.toString(),
-                mNumDeletes, mProvider, mAccount));
+                mNumDeletes, mProvider, mAccount.name));
 
         final LinearLayout ll = new LinearLayout(this);
         ll.setOrientation(LinearLayout.VERTICAL);
@@ -86,6 +88,22 @@
                 ViewGroup.LayoutParams.FILL_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT, 0);
         ll.addView(textView, lp);
         ll.addView(listView, lp);
+
+        // TODO: consider displaying the icon of the account type
+//        AuthenticatorDescription[] descs = AccountManager.get(this).getAuthenticatorTypes();
+//        for (AuthenticatorDescription desc : descs) {
+//            if (desc.type.equals(mAccount.type)) {
+//                try {
+//                    final Context authContext = createPackageContext(desc.packageName, 0);
+//                    ImageView imageView = new ImageView(this);
+//                    imageView.setImageDrawable(authContext.getResources().getDrawable(desc.iconId));
+//                    ll.addView(imageView, lp);
+//                } catch (PackageManager.NameNotFoundException e) {
+//                }
+//                break;
+//            }
+//        }
+
         setContentView(ll);
     }
 
@@ -97,24 +115,20 @@
     }
 
     private void startSyncReallyDelete() {
-        Uri uri = Uri.parse("content://" + mProvider);
         Bundle extras = new Bundle();
-        extras.putString(ContentResolver.SYNC_EXTRAS_ACCOUNT, mAccount);
         extras.putBoolean(ContentResolver.SYNC_EXTRAS_OVERRIDE_TOO_MANY_DELETIONS, true);
-        extras.putBoolean(ContentResolver.SYNC_EXTRAS_FORCE, true);
+        extras.putBoolean(ContentResolver.SYNC_EXTRAS_MANUAL, true);
         extras.putBoolean(ContentResolver.SYNC_EXTRAS_EXPEDITED, true);
         extras.putBoolean(ContentResolver.SYNC_EXTRAS_UPLOAD, true);
-        getContentResolver().startSync(uri, extras);
+        ContentResolver.requestSync(mAccount, mAuthority, extras);
     }
 
     private void startSyncUndoDeletes() {
-        Uri uri = Uri.parse("content://" + mProvider);
         Bundle extras = new Bundle();
-        extras.putString(ContentResolver.SYNC_EXTRAS_ACCOUNT, mAccount);
         extras.putBoolean(ContentResolver.SYNC_EXTRAS_DISCARD_LOCAL_DELETIONS, true);
-        extras.putBoolean(ContentResolver.SYNC_EXTRAS_FORCE, true);
+        extras.putBoolean(ContentResolver.SYNC_EXTRAS_MANUAL, true);
         extras.putBoolean(ContentResolver.SYNC_EXTRAS_EXPEDITED, true);
         extras.putBoolean(ContentResolver.SYNC_EXTRAS_UPLOAD, true);
-        getContentResolver().startSync(uri, extras);
+        ContentResolver.requestSync(mAccount, mAuthority, extras);
     }
 }
diff --git a/src/com/android/settings/SyncSettings.java b/src/com/android/settings/SyncSettings.java
deleted file mode 100644
index 483db9b..0000000
--- a/src/com/android/settings/SyncSettings.java
+++ /dev/null
@@ -1,487 +0,0 @@
-/*
- * Copyright (C) 2008 The Android Open Source Project
- *
- * 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.
- */
-
-package com.android.settings;
-
-import com.android.providers.subscribedfeeds.R;
-
-import android.app.ActivityThread;
-import android.app.AlertDialog;
-import android.app.Dialog;
-import android.content.ActiveSyncInfo;
-import android.content.ContentResolver;
-import android.content.ContentValues;
-import android.content.Context;
-import android.content.DialogInterface;
-import android.content.IContentService;
-import android.content.ISyncStatusObserver;
-import android.content.Intent;
-import android.content.SyncStatusInfo;
-import android.content.SyncStorageEngine;
-import android.content.pm.ProviderInfo;
-import android.net.ConnectivityManager;
-import android.net.Uri;
-import android.os.Bundle;
-import android.os.Handler;
-import android.os.RemoteException;
-import android.text.format.DateFormat;
-import android.preference.CheckBoxPreference;
-import android.preference.Preference;
-import android.preference.PreferenceActivity;
-import android.preference.PreferenceScreen;
-import android.provider.Gmail;
-import android.provider.SubscribedFeeds;
-import android.text.TextUtils;
-import android.view.Menu;
-import android.view.MenuItem;
-import android.view.View;
-import android.widget.TextView;
-
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.List;
-import java.util.Map;
-import java.util.Observable;
-import java.util.Observer;
-
-import com.google.android.googlelogin.GoogleLoginServiceConstants;
-import com.google.android.googlelogin.GoogleLoginServiceHelper;
-
-public class SyncSettings extends PreferenceActivity {
-
-    IContentService    mContentService;
-    List<String>       mProviderNames;
-    List<ProviderInfo> mProviderInfos;
-
-    CheckBoxPreference mAutoSyncCheckBox;
-    TextView mErrorInfoView;
-
-    java.text.DateFormat mDateFormat;
-    java.text.DateFormat mTimeFormat;
-
-    final Handler mHandler = new Handler();
-    
-    private static final String SYNC_CONNECTION_SETTING_CHANGED
-        = "com.android.sync.SYNC_CONN_STATUS_CHANGED";
-
-    private static final String BACKGROUND_DATA_SETTING_CHANGED
-        = "com.android.sync.BG_DATA_STATUS_CHANGED";
-
-    private static final String SYNC_KEY_PREFIX = "sync_";
-    private static final String SYNC_CHECKBOX_KEY = "autoSyncCheckBox";
-    private static final String BACKGROUND_DATA_CHECKBOX_KEY = "backgroundDataCheckBox";
-
-    private static final String BACKGROUND_DATA_INTENT_EXTRA_NAME = "value";
-
-    private static final int MENU_SYNC_NOW_ID = Menu.FIRST;
-    private static final int MENU_SYNC_CANCEL_ID = Menu.FIRST + 1;
-    private static final int GET_ACCOUNT_REQUEST = 14376;
-
-    private static final int DIALOG_DISABLE_BACKGROUND_DATA = 1;
-    
-    @Override
-    protected void onCreate(Bundle icicle) {
-        super.onCreate(icicle);
-        
-        mContentService = ContentResolver.getContentService();
-        
-        setContentView(R.layout.sync_settings_list_content);
-        addPreferencesFromResource(R.xml.sync_settings);
-
-        mErrorInfoView = (TextView)findViewById(R.id.sync_settings_error_info);
-        mErrorInfoView.setVisibility(View.GONE);
-        mErrorInfoView.setCompoundDrawablesWithIntrinsicBounds(
-                getResources().getDrawable(R.drawable.ic_list_syncerror), null, null, null);
-
-        mDateFormat = DateFormat.getDateFormat(this);
-        mTimeFormat = DateFormat.getTimeFormat(this);
-
-        mAutoSyncCheckBox = (CheckBoxPreference) findPreference(SYNC_CHECKBOX_KEY);
-        
-        if (icicle == null) checkForAccount(); // First launch only; ignore orientation changes.
-        
-        initProviders();
-        initUI();
-    }
-    
-    private void checkForAccount() {
-        // This will request a Gmail account and if none present will invoke SetupWizard
-        // to login or create a new one. The result is returned through onActivityResult().
-        Bundle bundle = new Bundle();
-        bundle.putCharSequence("optional_message", getText(R.string.sync_plug));
-        GoogleLoginServiceHelper.getCredentials(
-                this, 
-                GET_ACCOUNT_REQUEST, 
-                bundle,
-                GoogleLoginServiceConstants.PREFER_HOSTED, 
-                Gmail.GMAIL_AUTH_SERVICE, 
-                true);
-    }
-    
-    @Override
-    protected void onActivityResult(int requestCode, int resultCode, Intent data) {
-        super.onActivityResult(requestCode, resultCode, data);
-        if (requestCode == GET_ACCOUNT_REQUEST) {
-            if (resultCode != RESULT_OK) {
-                // The user canceled and there are no accounts. Just return to the previous
-                // settings page...
-                finish();
-            }
-        } 
-    }
-
-    @Override
-    public boolean onCreateOptionsMenu(Menu menu) {
-        super.onCreateOptionsMenu(menu);
-        menu.add(0, MENU_SYNC_NOW_ID, 0, getString(R.string.sync_menu_sync_now))
-                .setIcon(com.android.internal.R.drawable.ic_menu_refresh);
-        menu.add(0, MENU_SYNC_CANCEL_ID, 0, getString(R.string.sync_menu_sync_cancel))
-                .setIcon(android.R.drawable.ic_menu_close_clear_cancel);
-        return true;
-    }
-
-    @Override
-    public boolean onPrepareOptionsMenu(Menu menu) {
-        super.onPrepareOptionsMenu(menu);
-        boolean syncActive = false;
-        try {
-            syncActive = mContentService.getActiveSync() != null;
-        } catch (RemoteException e) {
-        }
-        menu.findItem(MENU_SYNC_NOW_ID).setVisible(!syncActive);
-        menu.findItem(MENU_SYNC_CANCEL_ID).setVisible(syncActive);
-        return true;
-    }
-
-    @Override
-    public boolean onOptionsItemSelected(MenuItem item) {
-        switch (item.getItemId()) {
-            case MENU_SYNC_NOW_ID:
-                startSyncForEnabledProviders();
-                return true;
-            case MENU_SYNC_CANCEL_ID:
-                cancelSyncForEnabledProviders();
-                return true;
-        }
-        return super.onOptionsItemSelected(item);
-    }
-
-    private void initProviders() {
-        mProviderNames = new ArrayList<String>();
-        mProviderInfos = new ArrayList<ProviderInfo>();
-
-        try {
-            ActivityThread.getPackageManager().querySyncProviders(mProviderNames,
-                    mProviderInfos);
-        } catch (RemoteException e) {
-        }
-        /*
-        for (int i = 0; i < mProviderNames.size(); i++) {
-            Log.i("SyncProviders", mProviderNames.get(i));
-        }
-        */
-    }
-
-    @Override
-    protected void onResume() {
-        super.onResume();
-        try {
-            mContentService.addStatusChangeListener(
-                    SyncStorageEngine.CHANGE_ACTIVE
-                    | SyncStorageEngine.CHANGE_STATUS
-                    | SyncStorageEngine.CHANGE_SETTINGS,
-                    mSyncStatusObserver);
-        } catch (RemoteException e) {
-        }
-        onSyncStateUpdated();
-    }
-
-    @Override
-    protected void onPause() {
-        super.onPause();
-        try {
-            mContentService.removeStatusChangeListener(mSyncStatusObserver);
-        } catch (RemoteException e) {
-        }
-    }
-
-    @Override
-    protected void onDestroy() {
-        super.onDestroy();
-    }
-
-    private void initUI() {
-        // Set background connection state
-        CheckBoxPreference backgroundData =
-            (CheckBoxPreference) findPreference(BACKGROUND_DATA_CHECKBOX_KEY);
-        ConnectivityManager connManager =
-                (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE);
-        backgroundData.setChecked(connManager.getBackgroundDataSetting());
-
-        // Set the Auto Sync toggle state
-        CheckBoxPreference autoSync = (CheckBoxPreference) findPreference(SYNC_CHECKBOX_KEY);
-        try {
-            autoSync.setChecked(mContentService.getListenForNetworkTickles());
-        } catch (RemoteException e) {
-        }
-        setOneTimeSyncMode(!autoSync.isChecked());
-
-        // Find individual sync provider's states and initialize the toggles
-        int i;
-        int count = getPreferenceScreen().getPreferenceCount();
-        for (i = 0; i < count; i++) {
-            Preference pref = getPreferenceScreen().getPreference(i);
-            if (pref.hasKey() && pref.getKey().startsWith(SYNC_KEY_PREFIX)) {
-                CheckBoxPreference toggle = (CheckBoxPreference) pref;
-                String providerName = toggle.getKey().substring(SYNC_KEY_PREFIX.length());
-                boolean enabled = false;
-                try {
-                    enabled = mContentService.getSyncProviderAutomatically(providerName);
-                } catch (RemoteException e) {
-                }
-                toggle.setChecked(enabled);
-            }
-        }
-
-    }
-
-    @Override
-    public boolean onPreferenceTreeClick(PreferenceScreen preferences, Preference preference) {
-        CheckBoxPreference togglePreference = (CheckBoxPreference) preference;
-        String key = preference.getKey();
-        if (key.equals(BACKGROUND_DATA_CHECKBOX_KEY)) {
-            ConnectivityManager connManager =
-                    (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE);
-            boolean oldBackgroundDataSetting = connManager.getBackgroundDataSetting();
-            boolean backgroundDataSetting = togglePreference.isChecked();
-            if (oldBackgroundDataSetting != backgroundDataSetting) {
-                if (backgroundDataSetting) {
-                    setBackgroundDataInt(true);
-                } else {
-                    confirmDisablingOfBackgroundData(togglePreference);
-                }
-            }
-        } else if (key.equals(SYNC_CHECKBOX_KEY)) {
-            boolean oldListenForTickles = false;
-            try {
-                oldListenForTickles = mContentService.getListenForNetworkTickles();
-            } catch (RemoteException e) {
-            }
-            boolean listenForTickles = togglePreference.isChecked();
-            if (oldListenForTickles != listenForTickles) {
-                try {
-                    mContentService.setListenForNetworkTickles(listenForTickles);
-                } catch (RemoteException e) {
-                }
-                Intent intent = new Intent();
-                intent.setAction(SYNC_CONNECTION_SETTING_CHANGED);
-                sendBroadcast(intent);
-                if (listenForTickles) {
-                    startSyncForEnabledProviders();
-                }
-            }
-            if (!listenForTickles) {
-                cancelSyncForEnabledProviders();
-            }
-            setOneTimeSyncMode(!listenForTickles);
-        } else if (key.startsWith(SYNC_KEY_PREFIX)) {
-            SyncStateCheckBoxPreference syncPref = (SyncStateCheckBoxPreference) preference;
-            String providerName = key.substring(SYNC_KEY_PREFIX.length());
-            if (syncPref.isOneTimeSyncMode()) {
-                startSync(providerName);
-            } else {
-                boolean syncOn = togglePreference.isChecked();
-                boolean oldSyncState = false;
-                try {
-                    oldSyncState = mContentService.getSyncProviderAutomatically(providerName);
-                } catch (RemoteException e) {
-                }
-                if (syncOn != oldSyncState) {
-                    try {
-                        mContentService.setSyncProviderAutomatically(providerName, syncOn);
-                    } catch (RemoteException e) {
-                    }
-                    if (syncOn) {
-                        startSync(providerName);
-                    } else {
-                        cancelSync(providerName);
-                    }
-                }
-            }
-        } else {
-            return false;
-        }
-        return true;
-    }
-
-    private void setOneTimeSyncMode(boolean oneTimeSyncMode) {
-        int count = getPreferenceScreen().getPreferenceCount();
-        for (int i = 0; i < count; i++) {
-            Preference pref = getPreferenceScreen().getPreference(i);
-            if (pref.hasKey() && pref.getKey().startsWith(SYNC_KEY_PREFIX)) {
-                SyncStateCheckBoxPreference syncPref = (SyncStateCheckBoxPreference) pref;
-                syncPref.setOneTimeSyncMode(oneTimeSyncMode);
-            }
-        }
-    }
-    
-    private void confirmDisablingOfBackgroundData(final CheckBoxPreference
-            backgroundDataPreference) {
-        // This will get unchecked only if the user hits "Ok"
-        backgroundDataPreference.setChecked(true);
-        showDialog(DIALOG_DISABLE_BACKGROUND_DATA);        
-    }
-
-    @Override
-    protected Dialog onCreateDialog(int id) {
-        switch (id) {
-            case DIALOG_DISABLE_BACKGROUND_DATA:
-                final CheckBoxPreference pref =
-                    (CheckBoxPreference) findPreference(BACKGROUND_DATA_CHECKBOX_KEY); 
-                return new AlertDialog.Builder(this)
-                        .setTitle(R.string.background_data_dialog_title)
-                        .setIcon(android.R.drawable.ic_dialog_alert)
-                        .setMessage(R.string.background_data_dialog_message)
-                        .setPositiveButton(android.R.string.ok,
-                                    new DialogInterface.OnClickListener() {
-                                public void onClick(DialogInterface dialog, int which) {
-                                    setBackgroundDataInt(false);
-                                    pref.setChecked(false);
-                                }
-                            })
-                        .setNegativeButton(android.R.string.cancel, null)
-                        .create();
-        }
-        
-        return null;
-    }
-
-    private void setBackgroundDataInt(boolean enabled) {
-        ConnectivityManager connManager =
-                (ConnectivityManager) getSystemService(Context.CONNECTIVITY_SERVICE);
-        connManager.setBackgroundDataSetting(enabled);
-    }
-    
-    private void startSyncForEnabledProviders() {
-        cancelOrStartSyncForEnabledProviders(true /* start them */);
-    }
-
-    private void cancelSyncForEnabledProviders() {
-        cancelOrStartSyncForEnabledProviders(false /* cancel them */);
-    }
-
-    private void cancelOrStartSyncForEnabledProviders(boolean startSync) {
-        int count = getPreferenceScreen().getPreferenceCount();
-        for (int i = 0; i < count; i++) {
-            Preference pref = getPreferenceScreen().getPreference(i);
-            if (pref.hasKey() && pref.getKey().startsWith(SYNC_KEY_PREFIX)) {
-                CheckBoxPreference toggle = (CheckBoxPreference) pref;
-                if (!toggle.isChecked()) {
-                    continue;
-                }
-                final String authority = toggle.getKey().substring(SYNC_KEY_PREFIX.length());
-                if (startSync) {
-                    startSync(authority);
-                } else {
-                    cancelSync(authority);
-                }
-            }
-        }
-
-        // treat SubscribedFeeds as an enabled provider
-        final String authority = SubscribedFeeds.Feeds.CONTENT_URI.getAuthority();
-        if (startSync) {
-            startSync(authority);
-        } else {
-            cancelSync(authority);
-        }
-    }
-
-    private void startSync(String providerName) {
-        Uri uriToSync = (providerName != null) ? Uri.parse("content://" + providerName) : null;
-        Bundle extras = new Bundle();
-        extras.putBoolean(ContentResolver.SYNC_EXTRAS_FORCE, true);
-        getContentResolver().startSync(uriToSync, extras);
-    }
-
-    private void cancelSync(String authority) {
-        getContentResolver().cancelSync(Uri.parse("content://" + authority));
-    }
-
-    private ISyncStatusObserver mSyncStatusObserver = new ISyncStatusObserver.Stub() {
-        public void onStatusChanged(int which) throws RemoteException {
-            mHandler.post(new Runnable() {
-                public void run() {
-                    onSyncStateUpdated();
-                }
-            });
-        }
-    };
-
-    private void onSyncStateUpdated() {
-        // iterate over all the preferences, setting the state properly for each
-        Date date = new Date();
-        ActiveSyncInfo activeSyncValues = null;
-        try {
-            activeSyncValues = mContentService.getActiveSync();
-        } catch (RemoteException e) {
-        }
-        boolean syncIsFailing = false;
-        int count = getPreferenceScreen().getPreferenceCount();
-        for (int i = 0; i < count; i++) {
-            Preference pref = getPreferenceScreen().getPreference(i);
-            final String prefKey = pref.getKey();
-            if (!TextUtils.isEmpty(prefKey) && prefKey.startsWith(SYNC_KEY_PREFIX)) {
-                String authority = prefKey.substring(SYNC_KEY_PREFIX.length());
-                SyncStateCheckBoxPreference toggle = (SyncStateCheckBoxPreference)pref;
-                SyncStatusInfo status = null;
-                boolean syncEnabled = false;
-                boolean authorityIsPending = false;
-                try {
-                    status = mContentService.getStatusByAuthority(authority);
-                    syncEnabled = mContentService.getSyncProviderAutomatically(authority);
-                    authorityIsPending = mContentService.isAuthorityPending(null, authority);
-                } catch (RemoteException e) {
-                }
-
-                boolean activelySyncing = activeSyncValues != null
-                        && activeSyncValues.authority.equals(authority);
-                boolean lastSyncFailed = status != null
-                        && status.lastFailureTime != 0
-                        && status.getLastFailureMesgAsInt(0)
-                           != SyncStorageEngine.ERROR_SYNC_ALREADY_IN_PROGRESS;
-                if (!syncEnabled) lastSyncFailed = false;
-                if (lastSyncFailed && !activelySyncing && !authorityIsPending) {
-                    syncIsFailing = true;
-                }
-                final long successEndTime =
-                    status == null ? 0 : status.lastSuccessTime;
-                if (successEndTime != 0) {
-                    date.setTime(successEndTime);
-                    final String timeString = mDateFormat.format(date) + " "
-                            + mTimeFormat.format(date);
-                    toggle.setSummary(timeString);
-                } else {
-                    toggle.setSummary("");
-                }
-                toggle.setActive(activelySyncing);
-                toggle.setPending(authorityIsPending);
-                toggle.setFailed(lastSyncFailed);
-            }
-        }
-        mErrorInfoView.setVisibility(syncIsFailing ? View.VISIBLE : View.GONE);
-    }
-}
diff --git a/src/com/android/settings/SyncStateCheckBoxPreference.java b/src/com/android/settings/SyncStateCheckBoxPreference.java
index 948287b..287979e 100644
--- a/src/com/android/settings/SyncStateCheckBoxPreference.java
+++ b/src/com/android/settings/SyncStateCheckBoxPreference.java
@@ -25,12 +25,15 @@
 import android.view.View;
 import android.widget.ImageView;
 import android.widget.TextView;
+import android.accounts.Account;
 
 public class SyncStateCheckBoxPreference extends CheckBoxPreference {
 
     private boolean mIsActive = false;
     private boolean mIsPending = false;
     private boolean mFailed = false;
+    private Account mAccount;
+    private String mAuthority;
 
     /**
      * A mode for this preference where clicking does a one-time sync instead of
@@ -41,6 +44,15 @@
     public SyncStateCheckBoxPreference(Context context, AttributeSet attrs) {
         super(context, attrs);
         setWidgetLayoutResource(R.layout.preference_widget_sync_toggle);
+        mAccount = null;
+        mAuthority = null;
+    }
+
+    public SyncStateCheckBoxPreference(Context context, Account account, String authority) {
+        super(context, null);
+        mAccount = account;
+        mAuthority = authority;
+        setWidgetLayoutResource(R.layout.preference_widget_sync_toggle);
     }
 
     @Override
@@ -51,11 +63,15 @@
         View syncFailedView = view.findViewById(R.id.sync_failed);
 
         syncActiveView.setVisibility(mIsActive ? View.VISIBLE : View.GONE);
-        AnimationDrawable anim = (AnimationDrawable) syncActiveView.getDrawable();
+        final AnimationDrawable anim = (AnimationDrawable) syncActiveView.getDrawable();
         boolean showError;
         boolean showPending;
         if (mIsActive) {
-            anim.start();
+            syncActiveView.post(new Runnable() {
+                public void run() {
+                    anim.start();
+                }
+            });
             showPending = false;
             showError = false;
         } else {
@@ -138,5 +154,12 @@
             super.onClick();
         }            
     }
-    
+
+    public Account getAccount() {
+        return mAccount;
+    }
+
+    public String getAuthority() {
+        return mAuthority;
+    }
 }