Loading src/com/android/launcher3/Folder.java +2 −2 Original line number Diff line number Diff line Loading @@ -1202,7 +1202,7 @@ public class Folder extends LinearLayout implements DragSource, View.OnClickList } private void replaceFolderWithFinalItem() { if (mInfo.hidden) { if (mInfo.hidden && getItemCount() >= 1) { return; } // Add the last remaining child to the workspace in place of the folder Loading Loading @@ -1245,7 +1245,7 @@ public class Folder extends LinearLayout implements DragSource, View.OnClickList if (finalChild != null) { mFolderIcon.performDestroyAnimation(finalChild, onCompleteRunnable); } else { onCompleteRunnable.run(); mLauncher.runOnUiThread(onCompleteRunnable); } mDestroyed = true; } Loading src/com/android/launcher3/FolderIcon.java +1 −1 Original line number Diff line number Diff line Loading @@ -690,7 +690,7 @@ public class FolderIcon extends FrameLayout implements FolderListener { public void onAnimationEnd(Animator animation) { mAnimating = false; if (onCompleteRunnable != null) { onCompleteRunnable.run(); mLauncher.runOnUiThread(onCompleteRunnable); } } }); Loading src/com/android/launcher3/Launcher.java +13 −1 Original line number Diff line number Diff line Loading @@ -456,10 +456,21 @@ public class Launcher extends Activity return Log.isLoggable(propertyName, Log.VERBOSE); } Runnable mUpdateDynamicGridRunnable = new Runnable() { @Override public void run() { updateDynamicGrid(); } }; private BroadcastReceiver protectedAppsChangedReceiver = new BroadcastReceiver() { @Override public void onReceive(Context context, Intent intent) { // Update the workspace if (waitUntilResume(mUpdateDynamicGridRunnable, true)) { return; } updateDynamicGrid(); } }; Loading Loading @@ -1329,7 +1340,8 @@ public class Launcher extends Activity protected void startThemeSettings() { Intent chooser = new Intent(Intent.ACTION_MAIN) .addCategory(OverviewSettingsPanel.THEME_CHOOSER_CATEGORY) .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK) .addFlags(Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS); try { startActivity(chooser); } catch (ActivityNotFoundException e) { Loading src/com/android/launcher3/LauncherModel.java +13 −3 Original line number Diff line number Diff line Loading @@ -2445,18 +2445,28 @@ public class LauncherModel extends BroadcastReceiver { int NN = shortcuts.size() - 1; for (int j = NN; j >= 0; j--) { ShortcutInfo sci = shortcuts.get(j); final ShortcutInfo sci = shortcuts.get(j); if (sci.intent != null && sci.intent.getComponent() != null) { if (!folder.hidden){ if (mHiddenApps.contains(sci.intent.getComponent())) { LauncherModel.deleteItemFromDatabase(mContext, sci); Runnable r = new Runnable() { public void run() { folder.remove(sci); } }; runOnMainThread(r, MAIN_THREAD_BINDING_RUNNABLE); } } else { if (!mHiddenApps.contains(sci.intent.getComponent())) { LauncherModel.deleteItemFromDatabase(mContext, sci); Runnable r = new Runnable() { public void run() { folder.remove(sci); } }; runOnMainThread(r, MAIN_THREAD_BINDING_RUNNABLE); } } } Loading src/com/android/launcher3/Workspace.java +15 −3 Original line number Diff line number Diff line Loading @@ -1337,7 +1337,7 @@ public class Workspace extends SmoothPagedView float mAnimationStartOffset; private final int ANIMATION_DURATION = 250; // Don't use all the wallpaper for parallax until you have at least this many pages private final int MIN_PARALLAX_PAGE_SPAN = 3; private final int MIN_PARALLAX_PAGE_SPAN = 2; int mNumScreens; boolean mCompletedInitialOffset; Loading Loading @@ -1390,8 +1390,8 @@ public class Workspace extends SmoothPagedView } private float wallpaperOffsetForCurrentScroll() { if (getChildCount() <= 1) { return 0; if (getNumScreensExcludingEmptyAndCustom() <= 1) { return mWallpaperIsLiveWallpaper ? 0 : 0.5f; } // Exclude the leftmost page Loading Loading @@ -2767,6 +2767,18 @@ public class Workspace extends SmoothPagedView v.getWidth() + padding, v.getHeight() + padding, Bitmap.Config.ARGB_8888); } // Special case for dragging All Apps button if (v.getTag() instanceof ItemInfo) { ItemInfo info = (ItemInfo) v.getTag(); if (info.itemType == LauncherSettings.Favorites.ITEM_TYPE_ALLAPPS) { // Special case for all apps icon Drawable d = ((TextView) v).getCompoundDrawables()[1]; Rect r = d.getBounds(); b = Bitmap.createBitmap(r.width() + padding, r.height() + padding, Bitmap.Config.ARGB_8888); } } canvas.setBitmap(b); drawDragView(v, canvas, padding, true); canvas.setBitmap(null); Loading Loading
src/com/android/launcher3/Folder.java +2 −2 Original line number Diff line number Diff line Loading @@ -1202,7 +1202,7 @@ public class Folder extends LinearLayout implements DragSource, View.OnClickList } private void replaceFolderWithFinalItem() { if (mInfo.hidden) { if (mInfo.hidden && getItemCount() >= 1) { return; } // Add the last remaining child to the workspace in place of the folder Loading Loading @@ -1245,7 +1245,7 @@ public class Folder extends LinearLayout implements DragSource, View.OnClickList if (finalChild != null) { mFolderIcon.performDestroyAnimation(finalChild, onCompleteRunnable); } else { onCompleteRunnable.run(); mLauncher.runOnUiThread(onCompleteRunnable); } mDestroyed = true; } Loading
src/com/android/launcher3/FolderIcon.java +1 −1 Original line number Diff line number Diff line Loading @@ -690,7 +690,7 @@ public class FolderIcon extends FrameLayout implements FolderListener { public void onAnimationEnd(Animator animation) { mAnimating = false; if (onCompleteRunnable != null) { onCompleteRunnable.run(); mLauncher.runOnUiThread(onCompleteRunnable); } } }); Loading
src/com/android/launcher3/Launcher.java +13 −1 Original line number Diff line number Diff line Loading @@ -456,10 +456,21 @@ public class Launcher extends Activity return Log.isLoggable(propertyName, Log.VERBOSE); } Runnable mUpdateDynamicGridRunnable = new Runnable() { @Override public void run() { updateDynamicGrid(); } }; private BroadcastReceiver protectedAppsChangedReceiver = new BroadcastReceiver() { @Override public void onReceive(Context context, Intent intent) { // Update the workspace if (waitUntilResume(mUpdateDynamicGridRunnable, true)) { return; } updateDynamicGrid(); } }; Loading Loading @@ -1329,7 +1340,8 @@ public class Launcher extends Activity protected void startThemeSettings() { Intent chooser = new Intent(Intent.ACTION_MAIN) .addCategory(OverviewSettingsPanel.THEME_CHOOSER_CATEGORY) .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); .addFlags(Intent.FLAG_ACTIVITY_NEW_TASK) .addFlags(Intent.FLAG_ACTIVITY_EXCLUDE_FROM_RECENTS); try { startActivity(chooser); } catch (ActivityNotFoundException e) { Loading
src/com/android/launcher3/LauncherModel.java +13 −3 Original line number Diff line number Diff line Loading @@ -2445,18 +2445,28 @@ public class LauncherModel extends BroadcastReceiver { int NN = shortcuts.size() - 1; for (int j = NN; j >= 0; j--) { ShortcutInfo sci = shortcuts.get(j); final ShortcutInfo sci = shortcuts.get(j); if (sci.intent != null && sci.intent.getComponent() != null) { if (!folder.hidden){ if (mHiddenApps.contains(sci.intent.getComponent())) { LauncherModel.deleteItemFromDatabase(mContext, sci); Runnable r = new Runnable() { public void run() { folder.remove(sci); } }; runOnMainThread(r, MAIN_THREAD_BINDING_RUNNABLE); } } else { if (!mHiddenApps.contains(sci.intent.getComponent())) { LauncherModel.deleteItemFromDatabase(mContext, sci); Runnable r = new Runnable() { public void run() { folder.remove(sci); } }; runOnMainThread(r, MAIN_THREAD_BINDING_RUNNABLE); } } } Loading
src/com/android/launcher3/Workspace.java +15 −3 Original line number Diff line number Diff line Loading @@ -1337,7 +1337,7 @@ public class Workspace extends SmoothPagedView float mAnimationStartOffset; private final int ANIMATION_DURATION = 250; // Don't use all the wallpaper for parallax until you have at least this many pages private final int MIN_PARALLAX_PAGE_SPAN = 3; private final int MIN_PARALLAX_PAGE_SPAN = 2; int mNumScreens; boolean mCompletedInitialOffset; Loading Loading @@ -1390,8 +1390,8 @@ public class Workspace extends SmoothPagedView } private float wallpaperOffsetForCurrentScroll() { if (getChildCount() <= 1) { return 0; if (getNumScreensExcludingEmptyAndCustom() <= 1) { return mWallpaperIsLiveWallpaper ? 0 : 0.5f; } // Exclude the leftmost page Loading Loading @@ -2767,6 +2767,18 @@ public class Workspace extends SmoothPagedView v.getWidth() + padding, v.getHeight() + padding, Bitmap.Config.ARGB_8888); } // Special case for dragging All Apps button if (v.getTag() instanceof ItemInfo) { ItemInfo info = (ItemInfo) v.getTag(); if (info.itemType == LauncherSettings.Favorites.ITEM_TYPE_ALLAPPS) { // Special case for all apps icon Drawable d = ((TextView) v).getCompoundDrawables()[1]; Rect r = d.getBounds(); b = Bitmap.createBitmap(r.width() + padding, r.height() + padding, Bitmap.Config.ARGB_8888); } } canvas.setBitmap(b); drawDragView(v, canvas, padding, true); canvas.setBitmap(null); Loading