A little more on #2256270: Package manager sends bad broadcasts when components change

Don't go through all this work if the enabled state hasn't changed.

Change-Id: If7393f53d6c0d0770960bb37bcaa5adebdbb3099
This commit is contained in:
Dianne Hackborn
2009-11-12 12:55:51 -08:00
parent d05fd6c335
commit 826d17c069

View File

@@ -12816,6 +12816,11 @@ public final class ActivityManagerService extends ActivityManagerNative implemen
mConfiguration = newConfig;
Log.i(TAG, "Config changed: " + newConfig);
AttributeCache ac = AttributeCache.instance();
if (ac != null) {
ac.updateConfiguration(mConfiguration);
}
Message msg = mHandler.obtainMessage(UPDATE_CONFIGURATION_MSG);
msg.obj = new Configuration(mConfiguration);
@@ -12843,11 +12848,6 @@ public final class ActivityManagerService extends ActivityManagerNative implemen
null, null, 0, null, null,
null, false, false, MY_PID, Process.SYSTEM_UID);
}
AttributeCache ac = AttributeCache.instance();
if (ac != null) {
ac.updateConfiguration(mConfiguration);
}
}
}