Fixing clipped landscape layout and crash when tapping to add widgets.
Change-Id: Ifcd2090cf9d374731726356b611750e1bca5c3cf
This commit is contained in:
@@ -293,20 +293,22 @@ public class AppsCustomizePagedView extends PagedViewWithDraggableItems implemen
|
||||
}
|
||||
});
|
||||
} else if (v instanceof PagedViewWidget) {
|
||||
final ResolveInfo info = (ResolveInfo) v.getTag();
|
||||
if (mWallpapers.contains(info)) {
|
||||
// Start the wallpaper picker
|
||||
animateClickFeedback(v, new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
// add the shortcut
|
||||
Intent createWallpapersIntent = new Intent(Intent.ACTION_SET_WALLPAPER);
|
||||
ComponentName name = new ComponentName(info.activityInfo.packageName,
|
||||
info.activityInfo.name);
|
||||
createWallpapersIntent.setComponent(name);
|
||||
mLauncher.processWallpaper(createWallpapersIntent);
|
||||
}
|
||||
});
|
||||
if (v.getTag() instanceof ResolveInfo) {
|
||||
final ResolveInfo info = (ResolveInfo) v.getTag();
|
||||
if (mWallpapers.contains(info)) {
|
||||
// Start the wallpaper picker
|
||||
animateClickFeedback(v, new Runnable() {
|
||||
@Override
|
||||
public void run() {
|
||||
// add the shortcut
|
||||
Intent createWallpapersIntent = new Intent(Intent.ACTION_SET_WALLPAPER);
|
||||
ComponentName name = new ComponentName(info.activityInfo.packageName,
|
||||
info.activityInfo.name);
|
||||
createWallpapersIntent.setComponent(name);
|
||||
mLauncher.processWallpaper(createWallpapersIntent);
|
||||
}
|
||||
});
|
||||
}
|
||||
} else {
|
||||
// Add the widget to the current workspace screen
|
||||
Workspace w = mLauncher.getWorkspace();
|
||||
|
||||
Reference in New Issue
Block a user