From bda1633979a5cca988cb71059931d04b090ef6fd Mon Sep 17 00:00:00 2001 From: onurays Date: Mon, 25 May 2020 11:23:45 +0300 Subject: [PATCH] New material resources added. --- .../riotx/features/call/VectorCallActivity.kt | 10 +-- .../src/main/res/drawable/bg_call_actions.xml | 12 ++++ .../{ic_call_incoming.xml => ic_call.xml} | 0 vector/src/main/res/drawable/ic_call_end.xml | 10 +++ .../drawable/ic_call_flip_camera_active.xml | 11 +++ .../drawable/ic_call_flip_camera_default.xml | 7 ++ .../main/res/drawable/ic_call_mute_active.xml | 11 +++ .../res/drawable/ic_call_mute_default.xml | 7 ++ .../res/drawable/ic_call_speaker_active.xml | 11 +++ .../res/drawable/ic_call_speaker_default.xml | 7 ++ .../drawable/ic_call_videocam_off_active.xml | 11 +++ .../drawable/ic_call_videocam_off_default.xml | 7 ++ vector/src/main/res/drawable/ic_videocam.xml | 5 ++ vector/src/main/res/layout/activity_call.xml | 67 ++++++++++++++++++- 14 files changed, 170 insertions(+), 6 deletions(-) create mode 100644 vector/src/main/res/drawable/bg_call_actions.xml rename vector/src/main/res/drawable/{ic_call_incoming.xml => ic_call.xml} (100%) create mode 100644 vector/src/main/res/drawable/ic_call_end.xml create mode 100644 vector/src/main/res/drawable/ic_call_flip_camera_active.xml create mode 100644 vector/src/main/res/drawable/ic_call_flip_camera_default.xml create mode 100644 vector/src/main/res/drawable/ic_call_mute_active.xml create mode 100644 vector/src/main/res/drawable/ic_call_mute_default.xml create mode 100644 vector/src/main/res/drawable/ic_call_speaker_active.xml create mode 100644 vector/src/main/res/drawable/ic_call_speaker_default.xml create mode 100644 vector/src/main/res/drawable/ic_call_videocam_off_active.xml create mode 100644 vector/src/main/res/drawable/ic_call_videocam_off_default.xml create mode 100644 vector/src/main/res/drawable/ic_videocam.xml diff --git a/vector/src/main/java/im/vector/riotx/features/call/VectorCallActivity.kt b/vector/src/main/java/im/vector/riotx/features/call/VectorCallActivity.kt index 51a4341336..fef5aa0647 100644 --- a/vector/src/main/java/im/vector/riotx/features/call/VectorCallActivity.kt +++ b/vector/src/main/java/im/vector/riotx/features/call/VectorCallActivity.kt @@ -53,8 +53,10 @@ import javax.inject.Inject @Parcelize data class CallArgs( -// val callId: String? = null, - val roomId: String + val roomId: String, + val participantUserId: String, + val isIncomingCall: Boolean, + val isVideoCall: Boolean ) : Parcelable class VectorCallActivity : VectorBaseActivity(), WebRtcPeerConnectionManager.Listener { @@ -400,9 +402,9 @@ class VectorCallActivity : VectorBaseActivity(), WebRtcPeerConnectionManager.Lis // mandatory.add(MediaConstraints.KeyValuePair("googHighpassFilter", "true")) // } - fun newIntent(context: Context, signalingRoomId: String): Intent { + fun newIntent(context: Context, roomId: String, participantUserId: String, isIncomingCall: Boolean, isVideoCall: Boolean): Intent { return Intent(context, VectorCallActivity::class.java).apply { - putExtra(MvRx.KEY_ARG, CallArgs(roomId = signalingRoomId)) + putExtra(MvRx.KEY_ARG, CallArgs(roomId, participantUserId, isIncomingCall, isVideoCall)) } } } diff --git a/vector/src/main/res/drawable/bg_call_actions.xml b/vector/src/main/res/drawable/bg_call_actions.xml new file mode 100644 index 0000000000..f074beb8f9 --- /dev/null +++ b/vector/src/main/res/drawable/bg_call_actions.xml @@ -0,0 +1,12 @@ + + + + + + + + \ No newline at end of file diff --git a/vector/src/main/res/drawable/ic_call_incoming.xml b/vector/src/main/res/drawable/ic_call.xml similarity index 100% rename from vector/src/main/res/drawable/ic_call_incoming.xml rename to vector/src/main/res/drawable/ic_call.xml diff --git a/vector/src/main/res/drawable/ic_call_end.xml b/vector/src/main/res/drawable/ic_call_end.xml new file mode 100644 index 0000000000..2879c2433e --- /dev/null +++ b/vector/src/main/res/drawable/ic_call_end.xml @@ -0,0 +1,10 @@ + + + + diff --git a/vector/src/main/res/drawable/ic_call_flip_camera_active.xml b/vector/src/main/res/drawable/ic_call_flip_camera_active.xml new file mode 100644 index 0000000000..25590cc753 --- /dev/null +++ b/vector/src/main/res/drawable/ic_call_flip_camera_active.xml @@ -0,0 +1,11 @@ + + + + diff --git a/vector/src/main/res/drawable/ic_call_flip_camera_default.xml b/vector/src/main/res/drawable/ic_call_flip_camera_default.xml new file mode 100644 index 0000000000..75ad0133f8 --- /dev/null +++ b/vector/src/main/res/drawable/ic_call_flip_camera_default.xml @@ -0,0 +1,7 @@ + + + diff --git a/vector/src/main/res/drawable/ic_call_mute_active.xml b/vector/src/main/res/drawable/ic_call_mute_active.xml new file mode 100644 index 0000000000..757f9cfa17 --- /dev/null +++ b/vector/src/main/res/drawable/ic_call_mute_active.xml @@ -0,0 +1,11 @@ + + + + diff --git a/vector/src/main/res/drawable/ic_call_mute_default.xml b/vector/src/main/res/drawable/ic_call_mute_default.xml new file mode 100644 index 0000000000..37a0c83fec --- /dev/null +++ b/vector/src/main/res/drawable/ic_call_mute_default.xml @@ -0,0 +1,7 @@ + + + diff --git a/vector/src/main/res/drawable/ic_call_speaker_active.xml b/vector/src/main/res/drawable/ic_call_speaker_active.xml new file mode 100644 index 0000000000..97035b1915 --- /dev/null +++ b/vector/src/main/res/drawable/ic_call_speaker_active.xml @@ -0,0 +1,11 @@ + + + + diff --git a/vector/src/main/res/drawable/ic_call_speaker_default.xml b/vector/src/main/res/drawable/ic_call_speaker_default.xml new file mode 100644 index 0000000000..2fc06a5795 --- /dev/null +++ b/vector/src/main/res/drawable/ic_call_speaker_default.xml @@ -0,0 +1,7 @@ + + + diff --git a/vector/src/main/res/drawable/ic_call_videocam_off_active.xml b/vector/src/main/res/drawable/ic_call_videocam_off_active.xml new file mode 100644 index 0000000000..106317ed56 --- /dev/null +++ b/vector/src/main/res/drawable/ic_call_videocam_off_active.xml @@ -0,0 +1,11 @@ + + + + diff --git a/vector/src/main/res/drawable/ic_call_videocam_off_default.xml b/vector/src/main/res/drawable/ic_call_videocam_off_default.xml new file mode 100644 index 0000000000..0b3d9baf04 --- /dev/null +++ b/vector/src/main/res/drawable/ic_call_videocam_off_default.xml @@ -0,0 +1,7 @@ + + + diff --git a/vector/src/main/res/drawable/ic_videocam.xml b/vector/src/main/res/drawable/ic_videocam.xml new file mode 100644 index 0000000000..b7a50f9a57 --- /dev/null +++ b/vector/src/main/res/drawable/ic_videocam.xml @@ -0,0 +1,5 @@ + + + diff --git a/vector/src/main/res/layout/activity_call.xml b/vector/src/main/res/layout/activity_call.xml index f1a2a3075f..3b158d8828 100644 --- a/vector/src/main/res/layout/activity_call.xml +++ b/vector/src/main/res/layout/activity_call.xml @@ -1,10 +1,11 @@ - + + + + + + + + + + + + + + - \ No newline at end of file + \ No newline at end of file