Start the memory dumper directly.

Launching it as an activity from within Launcher is
problematic, so we'll just treat it as a special shortcut
and run the dump when the user clicks that shortcut icon.

Change-Id: Ibe9f4adcaff674f5bafa9b0fc58b5a86cf5ceb00
diff --git a/src/com/android/launcher3/Launcher.java b/src/com/android/launcher3/Launcher.java
index bfe0be3..0294961 100644
--- a/src/com/android/launcher3/Launcher.java
+++ b/src/com/android/launcher3/Launcher.java
@@ -2027,12 +2027,20 @@
             // Open shortcut
             final Intent intent = ((ShortcutInfo) tag).intent;
 
-            ComponentName widgetComp = new ComponentName(this, WidgetAdder.class);
-            if (intent.getComponent() != null &&
-                    intent.getComponent().getClassName().equals(widgetComp.getClassName())) {
-                showAllApps(true);
-                return;
+            // Check for special shortcuts
+            if (intent.getComponent() != null) {
+                final String shortcutClass = intent.getComponent().getClassName();
+
+                if (shortcutClass.equals(WidgetAdder.class.getName())) {
+                    showAllApps(true);
+                    return;
+                } else if (shortcutClass.equals(MemoryDumpActivity.class.getName())) {
+                    MemoryDumpActivity.startDump(this);
+                    return;
+                }
             }
+
+            // Start activities
             int[] pos = new int[2];
             v.getLocationOnScreen(pos);
             intent.setSourceBounds(new Rect(pos[0], pos[1],