Removing all dependencies of launcher code on wallpaper-picker
> WallpaperPicker can still depend on launcher code, but not the
other way round.
Change-Id: I93a07f985c3955c638a68a5fad9c09b184a879b9
diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java
index f2610d6..58c4cf7 100644
--- a/src/com/android/launcher3/Launcher.java
+++ b/src/com/android/launcher3/Launcher.java
@@ -2409,13 +2409,6 @@
sFolders.remove(folder.id);
}
- protected ComponentName getWallpaperPickerComponent() {
- if (mLauncherCallbacks != null) {
- return mLauncherCallbacks.getWallpaperPickerComponent();
- }
- return new ComponentName(getPackageName(), LauncherWallpaperPickerActivity.class.getName());
- }
-
/**
* Registers various content observers. The current implementation registers
* only a favorites observer to keep track of the favorites applications.
@@ -2780,9 +2773,8 @@
*/
protected void onClickWallpaperPicker(View v) {
if (LOGD) Log.d(TAG, "onClickWallpaperPicker");
- final Intent pickWallpaper = new Intent(Intent.ACTION_SET_WALLPAPER);
- pickWallpaper.setComponent(getWallpaperPickerComponent());
- startActivityForResult(pickWallpaper, REQUEST_PICK_WALLPAPER);
+ startActivityForResult(new Intent(Intent.ACTION_SET_WALLPAPER).setPackage(getPackageName()),
+ REQUEST_PICK_WALLPAPER);
if (mLauncherCallbacks != null) {
mLauncherCallbacks.onClickWallpaperPicker(v);