mirror of
https://github.com/oxen-io/session-android.git
synced 2025-08-26 21:37:34 +00:00
Clean up camera flipping, handle having missing cameras.
Did a refactor to better organize the camera flipping code. Also, I wanted to make sure we handle the cases where the user doesn't have two cameras (or no cameras, for that matter). In these cases, we just don't show the appropriate buttons.
This commit is contained in:
8
res/drawable/webrtc_camera_front_button.xml
Normal file
8
res/drawable/webrtc_camera_front_button.xml
Normal file
@@ -0,0 +1,8 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:top="5dp"
|
||||
android:left="5dp"
|
||||
android:right="5dp"
|
||||
android:bottom="5dp"
|
||||
android:drawable="@drawable/quick_camera_front"/>
|
||||
</layer-list>
|
@@ -1,6 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<item android:drawable="@drawable/webrtc_control_background"/>
|
||||
<item android:top="5dp"
|
||||
android:left="5dp"
|
||||
android:right="5dp"
|
@@ -41,6 +41,7 @@
|
||||
android:id="@+id/camera_flip_button"
|
||||
style="@style/WebRtcCallCompoundButton"
|
||||
android:contentDescription="@string/redphone_call_controls__flip_camera_rear"
|
||||
android:background="@drawable/webrtc_camera_flip_button"/>
|
||||
android:background="@drawable/webrtc_camera_rear_button"
|
||||
android:visibility="gone"/>
|
||||
|
||||
</merge>
|
||||
|
@@ -995,7 +995,7 @@
|
||||
<!--- redphone_call_controls -->
|
||||
<string name="redphone_call_card__signal_call">Signal Call</string>
|
||||
<string name="redphone_call_controls__mute">Mute</string>
|
||||
<string name="redphone_call_controls__flip_camera_rear">Use rear camera</string>
|
||||
<string name="redphone_call_controls__flip_camera_rear">Switch Cameras</string>
|
||||
<string name="redphone_call_controls__signal_call">Signal Call</string>
|
||||
|
||||
<!-- registration_activity -->
|
||||
|
Reference in New Issue
Block a user