diff options
Diffstat (limited to 'src/com')
-rw-r--r-- | src/com/android/contacts/activities/PeopleActivity.java | 10 | ||||
-rw-r--r-- | src/com/android/contacts/incall/CallMethodStatusReceiver.java | 17 |
2 files changed, 22 insertions, 5 deletions
diff --git a/src/com/android/contacts/activities/PeopleActivity.java b/src/com/android/contacts/activities/PeopleActivity.java index 665d3cf8f..06e4b1356 100644 --- a/src/com/android/contacts/activities/PeopleActivity.java +++ b/src/com/android/contacts/activities/PeopleActivity.java @@ -1864,13 +1864,13 @@ public class PeopleActivity extends ContactsActivity implements return null; } - private void removePluginInfo(ComponentName cn) { + private InCallPluginInfo removePluginInfo(ComponentName cn) { for (int i = 0; i < mPluginTabInfo.size(); i++) { if (mPluginTabInfo.get(i).mCallMethodInfo.mComponent.equals(cn)) { - mPluginTabInfo.remove(i); - break; + return mPluginTabInfo.remove(i); } } + return null; } private void removeTabTitle(ComponentName cn) { @@ -1905,9 +1905,9 @@ public class PeopleActivity extends ContactsActivity implements } else { // Remove the tab associated with a plugin that's no longer available updateTabs = true; + mCallMethodMap.remove(cn); removeTabTitle(cn); - removePluginInfo(cn); - InCallPluginInfo removePlugin = getPluginInfo(cn); + InCallPluginInfo removePlugin = removePluginInfo(cn); if (removePlugin != null) { transaction = fragmentManager.beginTransaction(); transaction.remove(removePlugin.mFragment); diff --git a/src/com/android/contacts/incall/CallMethodStatusReceiver.java b/src/com/android/contacts/incall/CallMethodStatusReceiver.java new file mode 100644 index 000000000..0cc7fd559 --- /dev/null +++ b/src/com/android/contacts/incall/CallMethodStatusReceiver.java @@ -0,0 +1,17 @@ +package com.android.contacts.incall; + +import android.content.BroadcastReceiver; +import android.content.Context; +import android.content.Intent; +import android.util.Log; + +public class CallMethodStatusReceiver extends BroadcastReceiver { + private static final String TAG = CallMethodStatusReceiver.class.getSimpleName(); + private static final boolean DEBUG = false; + + @Override + public void onReceive(Context context, Intent intent) { + if (DEBUG) Log.d(TAG, "plugin status changed"); + InCallPluginHelper.refresh(); + } +} |