summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMick Lin <Mick.Lin@mediatek.com>2015-01-10 01:49:52 +0000
committerAndroid Git Automerger <android-git-automerger@android.com>2015-01-10 01:49:52 +0000
commit820ebb5a23877f46f60366da52e9a4c7c39e633c (patch)
tree7cb21027e3b23b3a21dec1ffc8910aa206eb3c20
parentdf51476c019c1e0dc765d247b6a8839defabc5db (diff)
parent2f69c118339985311ae40aa271949d7ae83f67b3 (diff)
am 5295eadc: am 3a8eaf2d: [DS] Fix a bug about Sip incoming call screen do not show.
* commit '5295eadcbe7bf6a7cda137d4186bbc134dc6d4a0': [DS] Fix a bug about Sip incoming call screen do not show.
-rw-r--r--InCallUI/src/com/android/incallui/ConferenceManagerPresenter.java14
1 files changed, 13 insertions, 1 deletions
diff --git a/InCallUI/src/com/android/incallui/ConferenceManagerPresenter.java b/InCallUI/src/com/android/incallui/ConferenceManagerPresenter.java
index bef4ef30a..86fc18ff3 100644
--- a/InCallUI/src/com/android/incallui/ConferenceManagerPresenter.java
+++ b/InCallUI/src/com/android/incallui/ConferenceManagerPresenter.java
@@ -21,6 +21,7 @@ import android.content.Context;
import com.android.incallui.InCallPresenter.InCallDetailsListener;
import com.android.incallui.InCallPresenter.InCallState;
import com.android.incallui.InCallPresenter.InCallStateListener;
+import com.android.incallui.InCallPresenter.IncomingCallListener;
import com.google.common.base.Preconditions;
@@ -32,7 +33,7 @@ import java.util.List;
*/
public class ConferenceManagerPresenter
extends Presenter<ConferenceManagerPresenter.ConferenceManagerUi>
- implements InCallStateListener, InCallDetailsListener {
+ implements InCallStateListener, InCallDetailsListener, IncomingCallListener {
private Context mContext;
@@ -42,6 +43,7 @@ public class ConferenceManagerPresenter
// register for call state changes last
InCallPresenter.getInstance().addListener(this);
+ InCallPresenter.getInstance().addIncomingCallListener(this);
}
@Override
@@ -49,6 +51,7 @@ public class ConferenceManagerPresenter
super.onUiUnready(ui);
InCallPresenter.getInstance().removeListener(this);
+ InCallPresenter.getInstance().removeIncomingCallListener(this);
}
@Override
@@ -90,6 +93,15 @@ public class ConferenceManagerPresenter
}
}
+ @Override
+ public void onIncomingCall(InCallState oldState, InCallState newState, Call call) {
+ // When incoming call exists, set conference ui invisible.
+ if (getUi().isFragmentVisible()) {
+ Log.d(this, "onIncomingCall()... Conference ui is showing, hide it.");
+ InCallPresenter.getInstance().showConferenceCallManager(false);
+ }
+ }
+
public void init(Context context, CallList callList) {
mContext = Preconditions.checkNotNull(context);
mContext = context;