Fix pause view

This commit is contained in:
Erwan Croze 2018-07-31 16:41:38 +02:00
parent c02478738a
commit 1afb50292a
5 changed files with 60 additions and 1013 deletions

View file

@ -1,496 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/topLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<android.support.v4.widget.DrawerLayout
android:id="@+id/side_menu"
android:layout_width="match_parent"
android:layout_height="match_parent">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@id/status">
<LinearLayout
android:id="@+id/fragmentContainer"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal" />
<FrameLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="@+id/menu">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<LinearLayout
android:id="@+id/conference_list"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="top"
android:layout_alignParentTop="true"
android:orientation="vertical"
android:visibility="gone">
</LinearLayout>
<RelativeLayout
android:id="@+id/active_call"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="visible"
android:layout_marginTop="40dp">
<LinearLayout
android:id="@+id/active_call_info"
android:background="@color/colorH"
android:alpha="0.8"
android:paddingBottom="10dp"
android:layout_width="match_parent"
android:layout_height="60dp"
android:gravity="center_horizontal"
android:layout_below="@id/avatar_layout"
android:orientation="horizontal">
<TextView
android:id="@+id/current_contact_name"
style="@style/font5"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom"/>
<Chronometer
android:id="@+id/current_call_timer"
style="@style/font2"
android:layout_marginLeft="10dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom"/>
</LinearLayout>
<RelativeLayout
android:id="@+id/avatar_layout"
android:layout_width="match_parent"
android:layout_height="100dp"
android:layout_margin="5dp"
android:gravity="center_horizontal"
android:paddingTop="10dp">
<ImageView
android:id="@+id/contact_picture"
android:contentDescription="@string/content_description_contact_picture"
android:layout_width="150dp"
android:layout_height="150dp"
android:src="@drawable/avatar_big_secure1"/>
<ImageView
android:id="@+id/mask"
android:layout_width="150dp"
android:layout_height="150dp"
android:adjustViewBounds="true"
android:contentDescription="@string/content_description_contact_picture"
android:src="@drawable/avatar_mask_border"
android:visibility="gone"/>
</RelativeLayout>
<LinearLayout
android:id="@+id/remote_pause"
android:background="@color/colorC"
android:alpha="0.9"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
android:orientation="vertical"
android:visibility="gone">
<ImageView
android:src="@drawable/waiting_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"/>
<TextView
android:text="@string/call_paused_by_remote"
style="@style/font16"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"/>
</LinearLayout>
<ImageView
android:id="@+id/encryption"
android:layout_width="70dp"
android:layout_height="60dp"
android:layout_alignParentTop="true"
android:contentDescription="@string/content_description_encryption"
android:padding="5dp"
android:layout_below="@+id/pause"
android:src="@drawable/security_button1_over"
android:visibility="visible"/>
<ImageView
android:id="@+id/pause"
android:layout_width="70dp"
android:layout_height="60dp"
android:layout_alignParentRight="true"
android:contentDescription="@string/content_description_pause"
android:src="@drawable/pause_big_default"/>
<ImageView
android:id="@+id/switchCamera"
android:layout_width="70dp"
android:layout_height="60dp"
android:layout_alignParentLeft="true"
android:layout_below="@+id/active_call_info"
android:contentDescription="@string/content_description_switch_camera"
android:padding="5dp"
android:src="@drawable/switch_camera"
android:visibility="invisible"/>
</RelativeLayout>
<LinearLayout
android:id="@+id/calls_list"
android:background="@color/colorH"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_gravity="bottom"
android:orientation="vertical">
</LinearLayout>
<LinearLayout
android:id="@+id/no_current_call"
android:background="@color/colorC"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:layout_above="@id/calls_list"
android:gravity="center_vertical"
android:visibility="gone">
<ImageView
android:src="@drawable/waiting_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"/>
<TextView
android:text="@string/no_current_call"
style="@style/font16"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"/>
</LinearLayout>
</RelativeLayout>
</FrameLayout>
<org.linphone.ui.Numpad
android:id="@+id/numpad"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_above="@id/menu"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"
android:layout_margin="10dp"
android:background="#282727"
android:contentDescription="@string/content_description_numpad"
android:visibility="gone"/>
<LinearLayout
android:id="@+id/menu"
android:layout_width="wrap_content"
android:layout_height="60dp"
android:layout_alignParentBottom="true"
android:orientation="horizontal">
<LinearLayout
android:id="@+id/main_bar"
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_weight="1"
android:background="@color/colorB"
android:orientation="horizontal">
<ImageView
android:id="@+id/dialer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:background="@color/colorB"
android:contentDescription="@string/content_description_numpad"
android:padding="15dp"
android:src="@drawable/footer_dialer"/>
<ImageView
android:id="@+id/hang_up"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="0.5"
android:background="@drawable/hangup"
android:contentDescription="@string/content_description_hang_up"
android:padding="12dp"
android:src="@drawable/call_hangup"/>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:background="@drawable/footer_button">
<ImageView
android:id="@+id/chat"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:background="@color/colorB"
android:contentDescription="@string/content_description_chat_button"
android:padding="15dp"
android:src="@drawable/footer_chat"/>
<TextView
android:id="@+id/missed_chats"
android:layout_width="20dp"
android:layout_height="20dp"
android:layout_margin="15dp"
android:background="@drawable/history_chat_indicator"
android:gravity="center"
android:textColor="#000000"
android:visibility="gone"/>
</RelativeLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_weight="1"
android:background=" #595959 "
android:orientation="horizontal">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1">
<ImageView
android:id="@+id/video"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:contentDescription="@string/content_description_switch_video"
android:padding="20dp"
android:src="@drawable/camera_default"/>
<ProgressBar
android:id="@+id/video_in_progress"
style="?android:attr/progressBarStyle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"
android:visibility="gone"/>
</RelativeLayout>
<ImageView
android:id="@+id/micro"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:contentDescription="@string/content_description_toggle_micro"
android:padding="10dp"
android:src="@drawable/micro_default"/>
<ImageView
android:id="@+id/speaker"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1"
android:contentDescription="@string/content_description_toggle_speaker"
android:padding="15dp"
android:src="@drawable/speaker_default"/>
<ImageView
android:id="@+id/audio_route"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1"
android:contentDescription="@string/content_description_audio_route"
android:padding="20dp"
android:src="@drawable/routes_default"
android:visibility="gone"/>
<ImageView
android:id="@+id/options"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:contentDescription="@string/content_description_call_options"
android:padding="15dp"
android:src="@drawable/options_default"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:id="@+id/menu_bottom"
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_above="@id/menu"
android:orientation="horizontal" android:layout_alignParentLeft="true"
android:layout_alignParentStart="true">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="invisible"
android:layout_weight="1"/>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="invisible"
android:layout_weight="1"/>
<ImageView
android:id="@+id/route_bluetooth"
android:src="@drawable/route_bluetooth"
android:background="@drawable/button_background"
android:contentDescription="@string/content_description_bluetooth"
android:padding="15dp"
android:visibility="invisible"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1.4" />
<ImageView
android:id="@+id/add_call"
android:layout_width="70dp"
android:layout_height="60dp"
android:layout_weight="1.4"
android:background="@drawable/button_background"
android:contentDescription="@string/content_description_add_call"
android:padding="5dp"
android:src="@drawable/options_add_call"
android:visibility="invisible"/>
</LinearLayout>
<LinearLayout
android:id="@+id/menu_middle"
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_above="@id/menu_bottom"
android:orientation="horizontal" >
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="invisible"
android:layout_weight="1"/>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="invisible"
android:layout_weight="1"/>
<ImageView
android:id="@+id/route_earpiece"
android:src="@drawable/route_earpiece"
android:background="@drawable/button_background"
android:contentDescription="@string/content_description_earpiece"
android:padding="15dp"
android:visibility="invisible"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1.4"/>
<ImageView
android:id="@+id/transfer"
android:src="@drawable/options_transfer_call"
android:background="@drawable/button_background"
android:contentDescription="@string/content_description_transfer"
android:padding="15dp"
android:visibility="invisible"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1.4"/>
</LinearLayout>
<LinearLayout
android:layout_above="@id/menu_middle"
android:layout_width="match_parent"
android:layout_height="60dp"
android:orientation="horizontal" >
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="invisible"
android:layout_weight="1"/>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="invisible"
android:layout_weight="1"/>
<ImageView
android:id="@+id/route_speaker"
android:src="@drawable/route_speaker"
android:background="@drawable/button_background"
android:contentDescription="@string/content_description_toggle_speaker"
android:visibility="invisible"
android:padding="15dp"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1.4"/>
<ImageView
android:id="@+id/conference"
android:src="@drawable/options_start_conference"
android:background="@drawable/button_background"
android:contentDescription="@string/content_description_conference"
android:visibility="invisible"
android:padding="15dp"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1.4"/>
</LinearLayout>
</RelativeLayout>
<RelativeLayout
android:id="@+id/side_menu_content"
android:background="@color/colorH"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="left">
<include layout="@layout/incall_stats" android:id="@+id/incall_stats"/>
</RelativeLayout>
</android.support.v4.widget.DrawerLayout>
<fragment
android:id="@+id/status"
android:name="org.linphone.fragments.StatusFragment"
android:layout_width="match_parent"
android:layout_height="35dp"
tools:layout="@layout/status" />
</RelativeLayout>

View file

@ -1,492 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/topLayout"
android:layout_width="match_parent"
android:layout_height="match_parent">
<fragment
android:id="@+id/status"
android:name="org.linphone.fragments.StatusFragment"
android:layout_width="match_parent"
android:layout_height="35dp"
tools:layout="@layout/status" />
<android.support.v4.widget.DrawerLayout
android:id="@+id/side_menu"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@id/status">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_below="@id/status">
<LinearLayout
android:id="@+id/fragmentContainer"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="horizontal" />
<FrameLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="@+id/menu">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<LinearLayout
android:id="@+id/conference_list"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="top"
android:layout_alignParentTop="true"
android:orientation="vertical"
android:visibility="gone">
</LinearLayout>
<RelativeLayout
android:id="@+id/active_call"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="visible">
<LinearLayout
android:id="@+id/active_call_info"
android:background="@color/colorH"
android:alpha="0.8"
android:paddingBottom="10dp"
android:layout_width="match_parent"
android:layout_height="60dp"
android:gravity="center_horizontal"
android:orientation="horizontal">
<TextView
android:id="@+id/current_contact_name"
style="@style/font5"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom"/>
<Chronometer
android:id="@+id/current_call_timer"
style="@style/font2"
android:layout_marginLeft="10dp"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom"/>
</LinearLayout>
<RelativeLayout
android:id="@+id/avatar_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@id/active_call_info"
android:layout_margin="5dp"
android:paddingTop="10dp"
android:gravity="center_horizontal">
<ImageView
android:id="@+id/contact_picture"
android:layout_width="150dp"
android:layout_height="150dp"
android:adjustViewBounds="true"
android:contentDescription="@string/content_description_contact_picture"
android:src="@drawable/avatar_big_secure1"/>
<ImageView
android:id="@+id/mask"
android:layout_width="150dp"
android:layout_height="150dp"
android:adjustViewBounds="true"
android:contentDescription="@string/content_description_contact_picture"
android:src="@drawable/avatar_mask_border"
android:visibility="gone"/>
</RelativeLayout>
<LinearLayout
android:id="@+id/remote_pause"
android:background="@color/colorC"
android:alpha="0.9"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center"
android:orientation="vertical"
android:visibility="gone">
<ImageView
android:src="@drawable/waiting_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"/>
<TextView
android:text="@string/call_paused_by_remote"
style="@style/font16"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"/>
</LinearLayout>
<ImageView
android:id="@+id/pause"
android:src="@drawable/pause_big_default"
android:contentDescription="@string/content_description_pause"
android:layout_width="80dp"
android:layout_height="80dp"
android:padding="10dp"
android:layout_below="@+id/active_call_info"
android:layout_alignParentRight="true"/>
<ImageView
android:id="@+id/switchCamera"
android:src="@drawable/switch_camera"
android:layout_width="80dp"
android:layout_height="80dp"
android:padding="10dp"
android:contentDescription="@string/content_description_switch_camera"
android:visibility="invisible"
android:layout_below="@+id/active_call_info"
android:layout_alignParentLeft="true"/>
</RelativeLayout>
<LinearLayout
android:id="@+id/calls_list"
android:background="@color/colorH"
android:layout_width="match_parent"
android:layout_weight="0.5"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_gravity="bottom"
android:orientation="vertical">
</LinearLayout>
<LinearLayout
android:id="@+id/no_current_call"
android:background="@color/colorC"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:layout_above="@id/calls_list"
android:gravity="center_vertical"
android:visibility="gone">
<ImageView
android:src="@drawable/waiting_time"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"/>
<TextView
android:text="@string/no_current_call"
style="@style/font16"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"/>
</LinearLayout>
</RelativeLayout>
</FrameLayout>
<org.linphone.ui.Numpad
android:id="@+id/numpad"
android:background="@color/colorF"
android:contentDescription="@string/content_description_numpad"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:visibility="gone"
android:layout_margin="10dp"
android:layout_above="@id/menu"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"/>
<LinearLayout
android:id="@+id/menu"
android:layout_width="wrap_content"
android:layout_height="60dp"
android:layout_alignParentBottom="true"
android:orientation="horizontal">
<LinearLayout
android:id="@+id/main_bar"
android:background="@color/colorF"
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_weight="1"
android:orientation="horizontal">
<ImageView
android:id="@+id/dialer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:background="@color/colorB"
android:contentDescription="@string/content_description_numpad"
android:padding="15dp"
android:src="@drawable/footer_dialer"/>
<ImageView
android:id="@+id/hang_up"
android:src="@drawable/call_hangup"
android:background="@drawable/hangup"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="0.5"
android:padding="12dp"
android:contentDescription="@string/content_description_hang_up"/>
<RelativeLayout
android:background="@drawable/footer_button"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1">
<ImageView
android:id="@+id/chat"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:background="@color/colorB"
android:contentDescription="@string/content_description_chat_button"
android:padding="15dp"
android:src="@drawable/footer_chat"/>
<TextView
android:id="@+id/missed_chats"
android:background="@drawable/history_chat_indicator"
style="@style/font18"
android:layout_width="20dp"
android:layout_height="20dp"
android:layout_margin="15dp"
android:gravity="center"
android:visibility="gone"/>
</RelativeLayout>
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_weight="1"
android:background=" #595959 "
android:orientation="horizontal">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1"
>
<ImageView
android:id="@+id/video"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:contentDescription="@string/content_description_switch_video"
android:padding="20dp"
android:src="@drawable/camera_default"/>
<ProgressBar
android:id="@+id/video_in_progress"
style="?android:attr/progressBarStyle"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_centerVertical="true"
android:visibility="gone"/>
</RelativeLayout>
<ImageView
android:id="@+id/micro"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:contentDescription="@string/content_description_toggle_micro"
android:padding="10dp"
android:src="@drawable/micro_default"/>
<ImageView
android:id="@+id/speaker"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1"
android:contentDescription="@string/content_description_toggle_speaker"
android:padding="15dp"
android:src="@drawable/speaker_default"/>
<ImageView
android:id="@+id/audio_route"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_weight="1"
android:contentDescription="@string/content_description_audio_route"
android:padding="15dp"
android:src="@drawable/routes_default"
android:visibility="gone"/>
<ImageView
android:id="@+id/options"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1"
android:contentDescription="@string/content_description_call_options"
android:padding="15dp"
android:src="@drawable/options_default"/>
</LinearLayout>
</LinearLayout>
<LinearLayout
android:id="@+id/menu_bottom"
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_above="@id/menu"
android:orientation="horizontal"
android:layout_alignParentLeft="true"
android:layout_alignParentStart="true">
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="invisible"
android:layout_weight="1"/>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="invisible"
android:layout_weight="1"/>
<ImageView
android:id="@+id/route_bluetooth"
android:src="@drawable/route_bluetooth"
android:background="@drawable/button_background"
android:padding="15dp"
android:visibility="invisible"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1.4"
android:contentDescription="@string/content_description_bluetooth"/>
<ImageView
android:id="@+id/add_call"
android:src="@drawable/options_add_call"
android:background="@drawable/button_background"
android:padding="15dp"
android:visibility="invisible"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1.4"
android:contentDescription="@string/content_description_add_call"/>
</LinearLayout>
<LinearLayout
android:id="@+id/menu_middle"
android:layout_width="match_parent"
android:layout_height="60dp"
android:layout_above="@id/menu_bottom"
android:orientation="horizontal" >
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="invisible"
android:layout_weight="1"/>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="invisible"
android:layout_weight="1"/>
<ImageView
android:id="@+id/route_earpiece"
android:src="@drawable/route_earpiece"
android:background="@drawable/button_background"
android:padding="15dp"
android:visibility="invisible"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1.4"
android:contentDescription="@string/content_description_earpiece"/>
<ImageView
android:id="@+id/transfer"
android:src="@drawable/options_transfer_call"
android:background="@drawable/button_background"
android:padding="15dp"
android:visibility="invisible"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1.4"
android:contentDescription="@string/content_description_transfer"/>
</LinearLayout>
<LinearLayout
android:layout_above="@id/menu_middle"
android:layout_width="match_parent"
android:layout_height="60dp"
android:orientation="horizontal" >
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="invisible"
android:layout_weight="1"/>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:visibility="invisible"
android:layout_weight="1"/>
<ImageView
android:id="@+id/route_speaker"
android:src="@drawable/route_speaker"
android:background="@drawable/button_background"
android:visibility="invisible"
android:padding="15dp"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1.4"
android:contentDescription="@string/content_description_toggle_speaker"/>
<ImageView
android:id="@+id/conference"
android:src="@drawable/options_start_conference"
android:background="@drawable/button_background"
android:visibility="invisible"
android:padding="15dp"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_weight="1.4"
android:contentDescription="@string/content_description_conference"/>
</LinearLayout>
</RelativeLayout>
<RelativeLayout
android:id="@+id/side_menu_content"
android:background="@color/colorH"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="left">
<include layout="@layout/incall_stats" android:id="@+id/incall_stats"/>
</RelativeLayout>
</android.support.v4.widget.DrawerLayout>
</RelativeLayout>

View file

@ -105,18 +105,35 @@
</RelativeLayout>
<LinearLayout
<RelativeLayout
android:id="@+id/remote_pause"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/colorN"
android:background="#e6ff6600"
android:gravity="center"
android:orientation="vertical"
android:visibility="gone">
<RelativeLayout
android:id="@+id/action_menu2"
android:layout_width="match_parent"
android:layout_height="50dp"
android:layout_alignParentStart="true"
android:layout_alignParentTop="true">
<ImageView
android:id="@+id/pause2"
android:layout_width="70dp"
android:layout_height="60dp"
android:layout_alignParentRight="true"
android:contentDescription="@string/content_description_pause"
android:src="@drawable/pause_big_default"/>
</RelativeLayout>
<ImageView
android:id="@+id/pause_logo"
android:layout_width="115dp"
android:layout_height="115dp"
android:layout_centerHorizontal="true"
android:layout_gravity="center"
android:src="@drawable/waiting_time"/>
@ -124,20 +141,22 @@
style="@style/font16"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/pause_logo"
android:layout_centerHorizontal="true"
android:layout_gravity="center"
android:text="@string/call_paused_by_remote"/>
</LinearLayout>
</RelativeLayout>
<LinearLayout
android:id="@+id/active_call_info"
android:layout_width="match_parent"
android:layout_height="80dp"
android:layout_below="@id/avatar_layout"
android:layout_centerHorizontal="true"
android:layout_alignParentBottom="true"
android:layout_below="@+id/avatar_layout"
android:layout_marginTop="-5dp"
android:background="@color/colorH"
android:orientation="vertical"
>
android:orientation="vertical">
<TextView
android:id="@+id/current_contact_name"
@ -145,17 +164,17 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
android:gravity="center"
android:background="@color/colorH"
android:gravity="center"
android:paddingTop="5dp"/>
<Chronometer
android:id="@+id/current_call_timer"
style="@style/font2"
android:background="@color/colorH"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"/>
android:layout_gravity="center"
android:background="@color/colorH"/>
</LinearLayout>
</RelativeLayout>
@ -174,8 +193,8 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_above="@id/calls_list"
android:alpha="0.85"
android:background="@color/colorN"
android:alpha="0"
android:background="#e6ff6600"
android:gravity="center_vertical"
android:orientation="vertical"
android:visibility="gone">
@ -184,7 +203,8 @@
android:layout_width="115dp"
android:layout_height="115dp"
android:layout_gravity="center"
android:src="@drawable/waiting_time"/>
android:src="@drawable/waiting_time"
android:visibility="gone"/>
<TextView
style="@style/font16"

View file

@ -95,7 +95,6 @@
android:layout_weight="0.2"
android:background="@drawable/toolbar_button"
android:contentDescription="@string/content_description_back_call"
android:padding="15dp"
android:src="@drawable/call_back"
android:visibility="gone"/>

View file

@ -110,10 +110,10 @@ public class CallActivity extends LinphoneGenericActivity implements OnClickList
private Runnable mControls;
private ImageView switchCamera;
private TextView missedChats;
private RelativeLayout mActiveCallHeader, sideMenuContent, avatar_layout;
private ImageView pause, hangUp, dialer, video, micro, speaker, options, addCall, transfer, conference, conferenceStatus, contactPicture;
private RelativeLayout mActiveCallHeader, sideMenuContent, avatar_layout, action_bar, mCallPaused;
private ImageView pause, pause2, hangUp, dialer, video, micro, speaker, options, addCall, transfer, conference, conferenceStatus, contactPicture;
private ImageView audioRoute, routeSpeaker, routeEarpiece, routeBluetooth, menu, chat, encryption;
private LinearLayout mNoCurrentCall, callInfo, mCallPaused;
private LinearLayout mNoCurrentCall, callInfo;
private ProgressBar videoProgress;
private StatusFragment status;
private CallAudioFragment audioCallFragment;
@ -392,14 +392,17 @@ public class CallActivity extends LinphoneGenericActivity implements OnClickList
pause = (ImageView) findViewById(R.id.pause);
pause.setOnClickListener(this);
pause2 = (ImageView) findViewById(R.id.pause2);
pause2.setOnClickListener(this);
enabledPauseButton(false);
mActiveCallHeader = (RelativeLayout) findViewById(R.id.active_call);
mNoCurrentCall = (LinearLayout) findViewById(R.id.no_current_call);
mCallPaused = (LinearLayout) findViewById(R.id.remote_pause);
mCallPaused = (RelativeLayout) findViewById(R.id.remote_pause);
contactPicture = (ImageView) findViewById(R.id.contact_picture);
avatar_layout = (RelativeLayout) findViewById(R.id.avatar_layout);
action_bar = (RelativeLayout) findViewById(R.id.action_menu);
//Options
addCall = (ImageView) findViewById(R.id.add_call);
@ -679,7 +682,7 @@ public class CallActivity extends LinphoneGenericActivity implements OnClickList
else if (id == R.id.add_call) {
goBackToDialer();
}
else if (id == R.id.pause) {
else if (id == R.id.pause || id == R.id.pause2) {
pauseOrResumeCall(LinphoneManager.getLc().getCurrentCall());
}
else if (id == R.id.hang_up) {
@ -764,9 +767,11 @@ public class CallActivity extends LinphoneGenericActivity implements OnClickList
private void enabledPauseButton(boolean enabled){
if(enabled) {
pause.setEnabled(true);
pause2.setEnabled(true);
pause.setImageResource(R.drawable.pause_big_default);
} else {
pause.setEnabled(false);
pause2.setEnabled(false);
//pause.setImageResource(R.drawable.pause_big_disabled);
}
}
@ -870,20 +875,24 @@ public class CallActivity extends LinphoneGenericActivity implements OnClickList
}
private void displayNoCurrentCall(boolean display){
if(!display) {
/*if(!display) {
mActiveCallHeader.setVisibility(View.VISIBLE);
mNoCurrentCall.setVisibility(View.GONE);
} else {
mActiveCallHeader.setVisibility(View.GONE);
mNoCurrentCall.setVisibility(View.VISIBLE);
}
}*/
}
private void displayCallPaused(boolean display){
if(display){
mCallPaused.setVisibility(View.VISIBLE);
avatar_layout.setVisibility(View.GONE);
action_bar.setVisibility(View.GONE);
} else {
mCallPaused.setVisibility(View.GONE);
avatar_layout.setVisibility(View.VISIBLE);
action_bar.setVisibility(View.VISIBLE);
}
}
@ -957,12 +966,19 @@ public class CallActivity extends LinphoneGenericActivity implements OnClickList
//pause.setImageResource(R.drawable.pause_big_over_selected);
} else if (call != null) {
if (call.getState() == State.Paused) {
lc.resumeCall(call);
call.resume();
if (isVideoCallPaused) {
isVideoCallPaused = false;
}
pause.setImageResource(R.drawable.pause_big_default);
}
} else if (lc.getCallsNb() > 0) {
for (int cpt = 0 ; cpt < lc.getCallsNb() ; cpt++) {
if (lc.getCalls()[cpt].getState() == State.Paused) {
lc.getCalls()[cpt].resume();
return;
}
}
}
}
@ -1230,7 +1246,7 @@ public class CallActivity extends LinphoneGenericActivity implements OnClickList
refreshIncallUi();
handleViewIntent();
if (lc != null) {
if (lc != null && lc.getCurrentCall() != null) {
refreshStatusItems(lc.getCurrentCall(), lc.getCurrentCall().getCurrentParams().videoEnabled());
}
@ -1247,7 +1263,7 @@ public class CallActivity extends LinphoneGenericActivity implements OnClickList
}
public void showZRTPDialog(final Call call) {
if(ZRTPdialog == null || !ZRTPdialog.isShowing()) {
if(call != null && (ZRTPdialog == null || !ZRTPdialog.isShowing())) {
String token = call.getAuthenticationToken();
if (token == null){