Removing first launcher broadcast

Change-Id: I225205a219cf2e0f27bb3c78cbdad1a3429d466f
This commit is contained in:
Sunny Goyal
2016-04-14 11:25:56 -07:00
parent ddec1c739e
commit 53b7ce18f4
3 changed files with 0 additions and 24 deletions
-4
View File
@@ -44,9 +44,6 @@
android:name="com.android.launcher3.permission.RECEIVE_LAUNCH_BROADCASTS"
android:protectionLevel="signature"
/>
<permission
android:name="com.android.launcher3.permission.RECEIVE_FIRST_LOAD_BROADCAST"
android:protectionLevel="signatureOrSystem" />
<uses-permission android:name="android.permission.CALL_PHONE" />
<uses-permission android:name="android.permission.SET_WALLPAPER" />
@@ -59,7 +56,6 @@
<uses-permission android:name="com.android.launcher3.permission.READ_SETTINGS" />
<uses-permission android:name="com.android.launcher3.permission.WRITE_SETTINGS" />
<uses-permission android:name="com.android.launcher3.permission.RECEIVE_LAUNCH_BROADCASTS" />
<uses-permission android:name="com.android.launcher3.permission.RECEIVE_FIRST_LOAD_BROADCAST" />
<application
android:allowBackup="@bool/enable_backup"
-3
View File
@@ -27,9 +27,6 @@
<!-- Permission to receive the com.android.launcher3.action.LAUNCH intent. [DO NOT TRANSLATE] -->
<string name="receive_launch_broadcasts_permission" translatable="false">com.android.launcher3.permission.RECEIVE_LAUNCH_BROADCASTS</string>
<!-- Permission to receive the com.android.launcher3.action.FIRST_LOAD_COMPLETE intent. [DO NOT TRANSLATE] -->
<string name="receive_first_load_broadcast_permission" translatable="false">com.android.launcher3.permission.RECEIVE_FIRST_LOAD_BROADCAST</string>
<!-- Application name -->
<string name="app_name">Launcher3</string>
<!-- Default folder name -->
-17
View File
@@ -196,10 +196,6 @@ public class Launcher extends Activity
static final String INTRO_SCREEN_DISMISSED = "launcher.intro_screen_dismissed";
static final String FIRST_RUN_ACTIVITY_DISPLAYED = "launcher.first_run_activity_displayed";
static final String FIRST_LOAD_COMPLETE = "launcher.first_load_complete";
static final String ACTION_FIRST_LOAD_COMPLETE =
"com.android.launcher3.action.FIRST_LOAD_COMPLETE";
private static final String QSB_WIDGET_ID = "qsb_widget_id";
private static final String QSB_WIDGET_PROVIDER = "qsb_widget_provider";
@@ -4102,7 +4098,6 @@ public class Launcher extends Activity
mWorkspace.restoreInstanceStateForRemainingPages();
setWorkspaceLoading(false);
sendLoadingCompleteBroadcastIfNecessary();
// If we received the result of any pending adds while the loader was running (e.g. the
// widget configuration forced an orientation change), process them now.
@@ -4128,18 +4123,6 @@ public class Launcher extends Activity
}
}
private void sendLoadingCompleteBroadcastIfNecessary() {
if (!mSharedPrefs.getBoolean(FIRST_LOAD_COMPLETE, false)) {
String permission =
getResources().getString(R.string.receive_first_load_broadcast_permission);
Intent intent = new Intent(ACTION_FIRST_LOAD_COMPLETE);
sendBroadcast(intent, permission);
SharedPreferences.Editor editor = mSharedPrefs.edit();
editor.putBoolean(FIRST_LOAD_COMPLETE, true);
editor.apply();
}
}
public boolean isAllAppsButtonRank(int rank) {
if (mHotseat != null) {
return mHotseat.isAllAppsButtonRank(rank);