Merge change 8291 into donut
* changes:
Add gservices flag for configuring the URL vending redirects to when TOS is inaccessible due to no/bad network.
diff --git a/data/sounds/AudioPackage2.mk b/data/sounds/AudioPackage2.mk
index 649787e..5dacc70 100644
--- a/data/sounds/AudioPackage2.mk
+++ b/data/sounds/AudioPackage2.mk
@@ -23,7 +23,6 @@
$(LOCAL_PATH)/Ring_Digital_02.ogg:system/media/audio/ringtones/Ring_Digital_02.ogg \
$(LOCAL_PATH)/Ring_Synth_04.ogg:system/media/audio/ringtones/Ring_Synth_04.ogg \
$(LOCAL_PATH)/Ring_Synth_02.ogg:system/media/audio/ringtones/Ring_Synth_02.ogg \
- $(LOCAL_PATH)/Silence.ogg:system/media/audio/ringtones/notifications/Silence.ogg \
$(LOCAL_PATH)/newwavelabs/BeatPlucker.ogg:system/media/audio/ringtones/BeatPlucker.ogg \
$(LOCAL_PATH)/newwavelabs/BentleyDubs.ogg:system/media/audio/ringtones/BentleyDubs.ogg \
$(LOCAL_PATH)/newwavelabs/BirdLoop.ogg:system/media/audio/ringtones/BirdLoop.ogg \
diff --git a/data/sounds/OriginalAudio.mk b/data/sounds/OriginalAudio.mk
index fc1e921..291f0b6 100644
--- a/data/sounds/OriginalAudio.mk
+++ b/data/sounds/OriginalAudio.mk
@@ -22,7 +22,6 @@
$(LOCAL_PATH)/Ring_Digital_02.ogg:system/media/audio/ringtones/Ring_Digital_02.ogg \
$(LOCAL_PATH)/Ring_Synth_04.ogg:system/media/audio/ringtones/Ring_Synth_04.ogg \
$(LOCAL_PATH)/Ring_Synth_02.ogg:system/media/audio/ringtones/Ring_Synth_02.ogg \
- $(LOCAL_PATH)/Silence.ogg:system/media/audio/ringtones/notifications/Silence.ogg \
$(LOCAL_PATH)/newwavelabs/BeatPlucker.ogg:system/media/audio/ringtones/BeatPlucker.ogg \
$(LOCAL_PATH)/newwavelabs/BentleyDubs.ogg:system/media/audio/ringtones/BentleyDubs.ogg \
$(LOCAL_PATH)/newwavelabs/BirdLoop.ogg:system/media/audio/ringtones/BirdLoop.ogg \
diff --git a/data/sounds/Silence.ogg b/data/sounds/Silence.ogg
deleted file mode 100644
index 6d78907..0000000
--- a/data/sounds/Silence.ogg
+++ /dev/null
Binary files differ
diff --git a/services/java/com/android/server/NotificationManagerService.java b/services/java/com/android/server/NotificationManagerService.java
index 38fb7c9..aac7124 100644
--- a/services/java/com/android/server/NotificationManagerService.java
+++ b/services/java/com/android/server/NotificationManagerService.java
@@ -90,7 +90,7 @@
private NotificationRecord mSoundNotification;
private AsyncPlayer mSound;
private boolean mSystemReady;
- private int mDisabledNotifications = StatusBarManager.DISABLE_NOTIFICATION_ALERTS;
+ private int mDisabledNotifications;
private NotificationRecord mVibrateNotification;
private Vibrator mVibrator = new Vibrator();
@@ -368,6 +368,15 @@
mStatusBarService = statusBar;
statusBar.setNotificationCallbacks(mNotificationCallbacks);
+ // Don't start allowing notifications until the setup wizard has run once.
+ // After that, including subsequent boots, init with notifications turned on.
+ // This works on the first boot because the setup wizard will toggle this
+ // flag at least once and we'll go back to 0 after that.
+ if (0 == Settings.Secure.getInt(mContext.getContentResolver(),
+ Settings.Secure.DEVICE_PROVISIONED, 0)) {
+ mDisabledNotifications = StatusBarManager.DISABLE_NOTIFICATION_ALERTS;
+ }
+
// register for battery changed notifications
IntentFilter filter = new IntentFilter();
filter.addAction(Intent.ACTION_BATTERY_CHANGED);
@@ -1049,6 +1058,8 @@
pw.println(" mSoundNotification=" + mSoundNotification);
pw.println(" mSound=" + mSound);
pw.println(" mVibrateNotification=" + mVibrateNotification);
+ pw.println(" mDisabledNotifications=0x" + Integer.toHexString(mDisabledNotifications));
+ pw.println(" mSystemReady=" + mSystemReady);
}
}
}