Making "tap to add" in customization mode automatically
add to the current screen
diff --git a/src/com/android/launcher2/PagedView.java b/src/com/android/launcher2/PagedView.java
index 17d18f8..5aec48e 100644
--- a/src/com/android/launcher2/PagedView.java
+++ b/src/com/android/launcher2/PagedView.java
@@ -104,7 +104,7 @@
// Multiple selection mode is not supported by all Launcher actions atm
protected static final int CHOICE_MODE_MULTIPLE = 2;
- private int mChoiceMode;
+ protected int mChoiceMode;
private ActionMode mActionMode;
protected PagedViewIconCache mPageViewIconCache;
@@ -1084,7 +1084,7 @@
if (!isChoiceMode(CHOICE_MODE_NONE)) {
mChoiceMode = CHOICE_MODE_NONE;
resetCheckedGrandchildren();
- mActionMode.finish();
+ if (mActionMode != null) mActionMode.finish();
mActionMode = null;
}
}