Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 166ee2a1 authored by Rekha Kumar's avatar Rekha Kumar Committed by Linux Build Service Account
Browse files

IMS-VT: Multitasking add video pause state

- Add video pause state for VT multitasking.

Change-Id: I96125d849ac6be35fc218007cdd7a4debbb98d83
CRs-Fixed: 629933
(cherry picked from commit a1aa60f0958515eafc9bf36972651abdc698d6df)
parent c53ce742
Loading
Loading
Loading
Loading
+25 −0
Original line number Diff line number Diff line
@@ -151,6 +151,16 @@ public class CallDetails {
                                                               * disabled
                                                               */

    public static final int VIDEO_PAUSE_STATE_PAUSED = 1; /*
                                                           * Indicates that
                                                           * video is paused;
                                                           */

    public static final int VIDEO_PAUSE_STATE_RESUMED = 2; /*
                                                            * Indicates that
                                                            * video is resumed;
                                                            */

    public static final String EXTRAS_IS_CONFERENCE_URI = "isConferenceUri";
    public static final String EXTRAS_PARENT_CALL_ID = "parentCallId";
    public static final String EXTRAS_HANDOVER_INFORMATION = "handoverInfo";
@@ -159,6 +169,7 @@ public class CallDetails {
    public int call_type;
    public int call_domain;
    public String[] extras;
    private int mVideoPauseState = VIDEO_PAUSE_STATE_RESUMED;

    public static class ServiceStatus {
        public boolean isValid;
@@ -225,6 +236,19 @@ public class CallDetails {
        this.extras = getExtrasFromMap(newExtras);
    }

    public void setVideoPauseState(int videoPauseState) {
        // Validate and set the new video pause state.
        switch (videoPauseState) {
            case VIDEO_PAUSE_STATE_RESUMED:
            case VIDEO_PAUSE_STATE_PAUSED:
                mVideoPauseState = videoPauseState;
        }
    }

    public int getVideoPauseState() {
        return mVideoPauseState;
    }

    public String getValueForKeyFromExtras(String[] extras, String key) {
        for (int i = 0; extras != null && i < extras.length; i++) {
            if (extras[i] != null) {
@@ -272,6 +296,7 @@ public class CallDetails {
        return (" " + call_type
                + " " + call_domain
                + " " + extrasResult
                + " videoPauseState" + mVideoPauseState
                + " Local Ability " + localSrvAbility
                + " Peer Ability " + peerSrvAbility);
    }