diff options
| author | 2011-01-26 23:52:41 -0800 | |
|---|---|---|
| committer | 2011-01-26 23:52:41 -0800 | |
| commit | da910fd5ea024f214f806d880d86d77bf94497b5 (patch) | |
| tree | 3c9b627cb325599afafa7fdb9ed7bc7411f6db36 | |
| parent | a45c056e62be0ca97edbdd6f6660822cf453c886 (diff) | |
| parent | f0a3cc5a5f3646c34c6dfd58a42368dfd5807e16 (diff) | |
Merge "Handle ActivityNotFoundException in the WM policy." into honeycomb
| -rwxr-xr-x | policy/src/com/android/internal/policy/impl/PhoneWindowManager.java | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java b/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java index fd84a2a2ea48..066daa89d267 100755 --- a/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java +++ b/policy/src/com/android/internal/policy/impl/PhoneWindowManager.java @@ -1402,7 +1402,14 @@ public class PhoneWindowManager implements WindowManagerPolicy { Intent shortcutIntent = mShortcutManager.getIntent(kcm, keyCode, metaState); if (shortcutIntent != null) { shortcutIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK); - mContext.startActivity(shortcutIntent); + try { + mContext.startActivity(shortcutIntent); + } catch (ActivityNotFoundException ex) { + Slog.w(TAG, "Dropping shortcut key combination because " + + "the activity to which it is registered was not found: " + + KeyEvent.keyCodeToString(mShortcutKeyPressed) + + "+" + KeyEvent.keyCodeToString(keyCode), ex); + } } else { Slog.i(TAG, "Dropping unregistered shortcut key combination: " + KeyEvent.keyCodeToString(mShortcutKeyPressed) |