Started conference call incoming layout
This commit is contained in:
parent
70ecd32065
commit
ff3762007e
14 changed files with 165 additions and 13 deletions
|
@ -23,7 +23,6 @@ import android.content.BroadcastReceiver
|
|||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import androidx.core.app.NotificationManagerCompat
|
||||
import org.linphone.LinphoneApplication.Companion.coreContext
|
||||
import org.linphone.LinphoneApplication.Companion.corePreferences
|
||||
import org.linphone.R
|
||||
import org.linphone.compatibility.Compatibility
|
||||
|
|
BIN
app/src/main/res/drawable-xhdpi/voip_conference.png
Normal file
BIN
app/src/main/res/drawable-xhdpi/voip_conference.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 9.1 KiB |
Binary file not shown.
Before Width: | Height: | Size: 5.9 KiB |
7
app/src/main/res/drawable/icon_video_conf_incoming.xml
Normal file
7
app/src/main/res/drawable/icon_video_conf_incoming.xml
Normal file
|
@ -0,0 +1,7 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item>
|
||||
<bitmap android:src="@drawable/voip_conference"
|
||||
android:tint="@color/white_color"/>
|
||||
</item>
|
||||
</selector>
|
|
@ -1,15 +1,15 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:state_pressed="true">
|
||||
<bitmap android:src="@drawable/voip_conference_new"
|
||||
<bitmap android:src="@drawable/voip_conference"
|
||||
android:tint="?attr/drawableTintOverColor"/>
|
||||
</item>
|
||||
<item android:state_enabled="false">
|
||||
<bitmap android:src="@drawable/voip_conference_new"
|
||||
<bitmap android:src="@drawable/voip_conference"
|
||||
android:tint="?attr/drawableTintDisabledColor"/>
|
||||
</item>
|
||||
<item>
|
||||
<bitmap android:src="@drawable/voip_conference_new"
|
||||
<bitmap android:src="@drawable/voip_conference"
|
||||
android:tint="?attr/drawableTintColor"/>
|
||||
</item>
|
||||
</selector>
|
||||
|
|
|
@ -77,7 +77,7 @@
|
|||
android:layout_weight="2"
|
||||
android:background="?attr/button_background_drawable"
|
||||
android:padding="5dp"
|
||||
android:src="@drawable/voip_conference_new" />
|
||||
android:src="@drawable/icon_video_conf_new" />
|
||||
|
||||
<ImageView
|
||||
android:onClick="@{newContactClickListener}"
|
||||
|
|
|
@ -118,7 +118,7 @@
|
|||
android:layout_weight="2"
|
||||
android:background="?attr/button_background_drawable"
|
||||
android:padding="5dp"
|
||||
android:src="@drawable/voip_conference_new" />
|
||||
android:src="@drawable/icon_video_conf_new" />
|
||||
|
||||
<ImageView
|
||||
android:onClick="@{newContactClickListener}"
|
||||
|
|
|
@ -118,7 +118,7 @@
|
|||
android:layout_weight="2"
|
||||
android:background="?attr/button_background_drawable"
|
||||
android:padding="5dp"
|
||||
android:src="@drawable/voip_conference_new" />
|
||||
android:src="@drawable/icon_video_conf_new" />
|
||||
|
||||
<ImageView
|
||||
android:onClick="@{newContactClickListener}"
|
||||
|
|
|
@ -29,7 +29,7 @@
|
|||
android:id="@+id/progress"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:layout_marginTop="20dp"
|
||||
android:indeterminate="true"
|
||||
android:indeterminateDrawable="@drawable/icon_spinner_rotating"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
|
@ -42,7 +42,7 @@
|
|||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:text="@string/call_incoming_title"
|
||||
android:text="@{callsViewModel.currentCallData.remoteConferenceSubject.length > 0 ? @string/conference_incoming_title : @string/call_incoming_title, default=@string/call_incoming_title}"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/progress" />
|
||||
|
@ -57,13 +57,24 @@
|
|||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/incoming_call_title" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/incoming_conference_subject"
|
||||
style="@style/call_header_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="5dp"
|
||||
android:text="@{callsViewModel.currentCallData.remoteConferenceSubject, default=`Conference subject`}"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/incoming_call_title" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/avatar"
|
||||
coilVoipContactAlt="@{callsViewModel.currentCallData}"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:layout_margin="10dp"
|
||||
android:contentDescription="@null"
|
||||
coilVoipContactAlt="@{callsViewModel.currentCallData}"
|
||||
app:layout_constraintBottom_toTopOf="@id/caller_name"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHeight_max="@dimen/voip_contact_avatar_max_size"
|
||||
|
@ -81,13 +92,13 @@
|
|||
android:ellipsize="end"
|
||||
android:maxLines="1"
|
||||
android:text="@{callsViewModel.currentCallData.contact.name ?? callsViewModel.currentCallData.displayName, default=`Bilbo Baggins`}"
|
||||
app:layout_constraintBottom_toTopOf="@id/textView"
|
||||
app:layout_constraintBottom_toTopOf="@id/sipAddress"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/avatar" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/textView"
|
||||
android:id="@+id/sipAddress"
|
||||
style="@style/call_header_subtitle"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
|
@ -101,6 +112,102 @@
|
|||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/caller_name" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/conference_avatar"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
android:src="@drawable/icon_video_conf_incoming"
|
||||
app:layout_constraintBottom_toTopOf="@id/participants_count"
|
||||
app:layout_constraintHeight_max="120dp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toBottomOf="@id/incoming_conference_subject" />
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/participants_count"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginStart="20dp"
|
||||
android:layout_marginEnd="20dp"
|
||||
android:layout_marginBottom="20dp"
|
||||
android:background="@drawable/event_decoration_gray"
|
||||
android:gravity="center"
|
||||
android:orientation="horizontal"
|
||||
app:layout_constraintBottom_toTopOf="@id/participants_list"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent">
|
||||
|
||||
<TextView
|
||||
style="@style/call_header_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="?attr/voipBackgroundColor"
|
||||
android:lineSpacingExtra="0sp"
|
||||
android:paddingLeft="10dp"
|
||||
android:paddingRight="10dp"
|
||||
android:text="Participants (6)" /><!-- TODO -->
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<androidx.core.widget.NestedScrollView
|
||||
android:id="@+id/participants_list"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_marginStart="5dp"
|
||||
android:layout_marginEnd="5dp"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:fadeScrollbars="false"
|
||||
android:scrollbars="vertical"
|
||||
app:layout_constraintBottom_toTopOf="@id/buttons"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintHeight_max="400dp"
|
||||
app:layout_constraintHeight_min="200dp"
|
||||
app:layout_constraintStart_toStartOf="parent">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical">
|
||||
|
||||
<include layout="@layout/voip_conference_incoming_participant_cell" />
|
||||
|
||||
<include layout="@layout/voip_conference_incoming_participant_cell" />
|
||||
|
||||
<include layout="@layout/voip_conference_incoming_participant_cell" />
|
||||
|
||||
<include layout="@layout/voip_conference_incoming_participant_cell" />
|
||||
|
||||
<include layout="@layout/voip_conference_incoming_participant_cell" />
|
||||
|
||||
<include layout="@layout/voip_conference_incoming_participant_cell" />
|
||||
|
||||
<include layout="@layout/voip_conference_incoming_participant_cell" />
|
||||
|
||||
<include layout="@layout/voip_conference_incoming_participant_cell" />
|
||||
|
||||
<include layout="@layout/voip_conference_incoming_participant_cell" />
|
||||
|
||||
<include layout="@layout/voip_conference_incoming_participant_cell" />
|
||||
<!-- TODO -->
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
|
||||
<androidx.constraintlayout.widget.Group
|
||||
android:id="@+id/single_call_group"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:visibility="@{callsViewModel.currentCallData.remoteConferenceSubject.length > 0 ? View.GONE : View.VISIBLE, default=visible}"
|
||||
app:constraint_referenced_ids="incoming_call_timer, avatar, caller_name, sipAddress" />
|
||||
|
||||
<androidx.constraintlayout.widget.Group
|
||||
android:id="@+id/conference_group"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:visibility="@{callsViewModel.currentCallData.remoteConferenceSubject.length > 0 ? View.VISIBLE : View.GONE, default=gone}"
|
||||
app:constraint_referenced_ids="incoming_conference_subject, conference_avatar, participants_count, participants_list" />
|
||||
|
||||
<include
|
||||
android:id="@+id/buttons"
|
||||
layout="@layout/voip_buttons_incoming"
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
android:id="@+id/progress"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="10dp"
|
||||
android:layout_marginTop="20dp"
|
||||
android:indeterminate="true"
|
||||
android:indeterminateDrawable="@drawable/icon_spinner_rotating"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
|
|
|
@ -0,0 +1,36 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<data>
|
||||
<import type="android.view.View"/>
|
||||
<variable
|
||||
name="data"
|
||||
type="org.linphone.activities.voip.data.ConferenceParticipantData" />
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="50dp"
|
||||
android:layout_margin="5dp"
|
||||
android:orientation="vertical"
|
||||
android:gravity="center">
|
||||
|
||||
<org.linphone.views.MarqueeTextView
|
||||
style="@style/call_header_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:singleLine="true"
|
||||
android:text="Bilbo Baggins" />
|
||||
|
||||
<org.linphone.views.MarqueeTextView
|
||||
style="@style/sip_uri_font"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:singleLine="true"
|
||||
android:ellipsize="end"
|
||||
android:text="sip:bilbo.baggins@sip.linphone.org" />
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</layout>
|
|
@ -718,4 +718,5 @@
|
|||
<string name="content_description_conference_participants">Participants de la conférence</string>
|
||||
<string name="conference_first_to_join">Vous êtes le premier à avoir rejoint la conférence</string>
|
||||
<string name="conference_last_user">Tous les autres participants ont quitté la conférence</string>
|
||||
<string name="conference_incoming_title">Appel de conférence entrant</string>
|
||||
</resources>
|
|
@ -290,6 +290,7 @@
|
|||
<string name="conference_low_bandwidth">Low bandwidth detected, disabling video</string>
|
||||
<string name="conference_first_to_join">You\'re the first to join the conference</string>
|
||||
<string name="conference_last_user">All other participants have left the conference</string>
|
||||
<string name="conference_incoming_title">Incoming conference call</string>
|
||||
|
||||
<!-- Call -->
|
||||
<string name="call_incoming_title">Incoming Call</string>
|
||||
|
|
|
@ -13,6 +13,7 @@
|
|||
<item name="android:windowBackground">@color/transparent_color</item>
|
||||
|
||||
<!-- Android theme override -->
|
||||
<item name="android:scrollbarThumbVertical">@color/light_grey_color</item>
|
||||
<item name="colorAccent">@color/primary_color</item>
|
||||
<item name="colorPrimary">@color/primary_color</item>
|
||||
<item name="android:colorPrimary">@color/primary_color</item>
|
||||
|
|
Loading…
Reference in a new issue