summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMichael Jurka <mikejurka@google.com>2010-07-30 21:47:52 (GMT)
committerMichael Jurka <mikejurka@google.com>2010-07-30 21:47:52 (GMT)
commit54dd75463d0eb47c2f468e19063bdc4141dfdf74 (patch)
tree33c88708c477586506fb4faeb491b7d2af55408e /src
parentb0f28bd9a52fa4e343c8299d1c3e225d8e01c1e9 (diff)
downloadandroid_packages_apps_Trebuchet-54dd75463d0eb47c2f468e19063bdc4141dfdf74.zip
android_packages_apps_Trebuchet-54dd75463d0eb47c2f468e19063bdc4141dfdf74.tar.gz
android_packages_apps_Trebuchet-54dd75463d0eb47c2f468e19063bdc4141dfdf74.tar.bz2
Tapping on mini-screen in All Apps view now goes back to home screen
- had to disable touch event swallowing in workspace in X-Large mode to get this to work - also changed default screen in XLarge mode to 2 (the middle one)
Diffstat (limited to 'src')
-rw-r--r--src/com/android/launcher2/Launcher.java3
-rw-r--r--src/com/android/launcher2/Workspace.java10
2 files changed, 9 insertions, 4 deletions
diff --git a/src/com/android/launcher2/Launcher.java b/src/com/android/launcher2/Launcher.java
index 8102d19..1de318f 100644
--- a/src/com/android/launcher2/Launcher.java
+++ b/src/com/android/launcher2/Launcher.java
@@ -2147,8 +2147,7 @@ public final class Launcher extends Activity
void onWorkspaceUnshrink() {
if (isAllAppsVisible()) {
- // TODO: Make a smoother transition here
- closeAllApps(false);
+ closeAllApps(true);
}
if (isCustomizationDrawerVisible()) {
hideCustomizationDrawer();
diff --git a/src/com/android/launcher2/Workspace.java b/src/com/android/launcher2/Workspace.java
index 3e52d7f..5200dbc 100644
--- a/src/com/android/launcher2/Workspace.java
+++ b/src/com/android/launcher2/Workspace.java
@@ -804,7 +804,10 @@ public class Workspace extends ViewGroup
@Override
public boolean dispatchTouchEvent(MotionEvent ev) {
if (ev.getAction() == MotionEvent.ACTION_DOWN) {
- if (mLauncher.isWorkspaceLocked() || mLauncher.isAllAppsVisible()) {
+ // (In XLarge mode, the workspace is shrunken below all apps, and responds to taps
+ // ie when you click on a mini-screen, it zooms back to that screen)
+ if (mLauncher.isWorkspaceLocked() ||
+ (!LauncherApplication.isScreenXLarge() && mLauncher.isAllAppsVisible())) {
return false;
}
}
@@ -815,7 +818,10 @@ public class Workspace extends ViewGroup
public boolean onInterceptTouchEvent(MotionEvent ev) {
final boolean workspaceLocked = mLauncher.isWorkspaceLocked();
final boolean allAppsVisible = mLauncher.isAllAppsVisible();
- if (workspaceLocked || allAppsVisible) {
+
+ // (In XLarge mode, the workspace is shrunken below all apps, and responds to taps
+ // ie when you click on a mini-screen, it zooms back to that screen)
+ if (workspaceLocked || (!LauncherApplication.isScreenXLarge() && allAppsVisible)) {
return false; // We don't want the events. Let them fall through to the all apps view.
}