Implement API to have new broadcasts replace existing broadcasts.

Use this in various places where it should serve no purpose to deliver
both broadcasts.  This is intended to reduce somewhat the flurry of
broadcasts that we churn through during boot.
This commit is contained in:
Dianne Hackborn
2009-12-08 19:45:14 -08:00
parent 1955324151
commit 1c633fc89b
16 changed files with 117 additions and 37 deletions

View File

@ -949,6 +949,7 @@ public class InputMethodManagerService extends IInputMethodManager.Stub
if (ActivityManagerNative.isSystemReady()) {
Intent intent = new Intent(Intent.ACTION_INPUT_METHOD_CHANGED);
intent.addFlags(Intent.FLAG_RECEIVER_REPLACE_PENDING);
intent.putExtra("input_method_id", id);
mContext.sendBroadcast(intent);
}