diff options
author | d34d <clark@cyngn.com> | 2015-06-18 15:08:41 -0700 |
---|---|---|
committer | d34d <clark@cyngn.com> | 2015-06-18 15:08:41 -0700 |
commit | e963932853caa238ba7bc6928e5243075e41fc75 (patch) | |
tree | c18d288ac468422398340c704e1df1f38bab2a2f /src/com/android | |
parent | 8de4b987b0a5ff9f09e59145a6ebab26a6abde73 (diff) | |
download | android_packages_apps_Trebuchet-e963932853caa238ba7bc6928e5243075e41fc75.tar.gz android_packages_apps_Trebuchet-e963932853caa238ba7bc6928e5243075e41fc75.tar.bz2 android_packages_apps_Trebuchet-e963932853caa238ba7bc6928e5243075e41fc75.zip |
Don't load title from intent if title loaded from DB
Title for shortcuts, when creating workspaces, are loaded from the
intent rather than the title stored in the DB. The title from the
DB is loaded in the ShortcutInfo so we will use that unless it is
null, in which case we'll fallback to loading the title from the
intent.
Change-Id: I436c11062dbc8ff3d7e1cd9f9564321ad0476933
Diffstat (limited to 'src/com/android')
-rw-r--r-- | src/com/android/launcher3/LauncherModel.java | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/com/android/launcher3/LauncherModel.java b/src/com/android/launcher3/LauncherModel.java index 2914d2324..f67e828aa 100644 --- a/src/com/android/launcher3/LauncherModel.java +++ b/src/com/android/launcher3/LauncherModel.java @@ -2284,9 +2284,11 @@ public class LauncherModel extends BroadcastReceiver iconPackageIndex, iconResourceIndex, iconIndex, titleIndex); - CharSequence title = getShortcutTitle(manager, intent); - if (title != null) { - info.title = title; + if (info.title == null) { + CharSequence title = getShortcutTitle(manager, intent); + if (title != null) { + info.title = title; + } } // App shortcuts that used to be automatically added to Launcher |