Use valid context inside LauncherModel when calling loadAndBindXXX
b/20851075 Change-Id: Ie3feb387a142d4e11a0a18bbcc4fd4932cfe4439
This commit is contained in:
@@ -2863,11 +2863,13 @@ public class LauncherModel extends BroadcastReceiver
|
||||
// Post callback on main thread
|
||||
mHandler.post(new Runnable() {
|
||||
public void run() {
|
||||
|
||||
final long bindTime = SystemClock.uptimeMillis();
|
||||
final Callbacks callbacks = tryGetCallbacks(oldCallbacks);
|
||||
if (callbacks != null) {
|
||||
callbacks.bindAllApplications(added);
|
||||
loadAndBindWidgetsAndShortcuts(mContext, callbacks, true /* refresh */);
|
||||
loadAndBindWidgetsAndShortcuts(mApp.getContext(), callbacks,
|
||||
true /* refresh */);
|
||||
if (DEBUG_LOADERS) {
|
||||
Log.d(TAG, "bound " + added.size() + " apps in "
|
||||
+ (SystemClock.uptimeMillis() - bindTime) + "ms");
|
||||
|
||||
Reference in New Issue
Block a user