diff options
Diffstat (limited to 'third_party/libwebrtc/examples/androidapp/res/layout')
4 files changed, 218 insertions, 0 deletions
diff --git a/third_party/libwebrtc/examples/androidapp/res/layout/activity_call.xml b/third_party/libwebrtc/examples/androidapp/res/layout/activity_call.xml new file mode 100644 index 0000000000..bf811426f3 --- /dev/null +++ b/third_party/libwebrtc/examples/androidapp/res/layout/activity_call.xml @@ -0,0 +1,34 @@ +<?xml version="1.0" encoding="utf-8"?> + +<!-- tools:ignore is needed because lint thinks this can be replaced with a merge. Replacing this + with a merge causes the fullscreen SurfaceView not to be centered. --> +<FrameLayout + xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:tools="http://schemas.android.com/tools" + android:layout_width="match_parent" + android:layout_height="match_parent" + tools:ignore="MergeRootFrame"> + + <org.webrtc.SurfaceViewRenderer + android:id="@+id/fullscreen_video_view" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_gravity="center" /> + + <org.webrtc.SurfaceViewRenderer + android:id="@+id/pip_video_view" + android:layout_height="144dp" + android:layout_width="wrap_content" + android:layout_gravity="bottom|end" + android:layout_margin="16dp"/> + + <FrameLayout + android:id="@+id/call_fragment_container" + android:layout_width="match_parent" + android:layout_height="match_parent" /> + <FrameLayout + android:id="@+id/hud_fragment_container" + android:layout_width="match_parent" + android:layout_height="match_parent" /> + +</FrameLayout> diff --git a/third_party/libwebrtc/examples/androidapp/res/layout/activity_connect.xml b/third_party/libwebrtc/examples/androidapp/res/layout/activity_connect.xml new file mode 100644 index 0000000000..017e5cabff --- /dev/null +++ b/third_party/libwebrtc/examples/androidapp/res/layout/activity_connect.xml @@ -0,0 +1,80 @@ +<?xml version="1.0" encoding="utf-8"?> +<LinearLayout + xmlns:android="http://schemas.android.com/apk/res/android" + xmlns:tools="http://schemas.android.com/tools" + android:layout_margin="16dp" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:orientation="vertical" + android:weightSum="1" + android:layout_centerHorizontal="true"> + + <TextView + android:id="@+id/room_edittext_description" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:text="@string/room_description"/> + + <LinearLayout + android:orientation="horizontal" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:gravity="center" + android:layout_marginBottom="8dp"> + + <!-- TODO(crbug.com/900912): Fix and remove lint ignore --> + <EditText + tools:ignore="LabelFor,Autofill" + android:id="@+id/room_edittext" + android:layout_width="0dp" + android:layout_height="wrap_content" + android:layout_weight="1" + android:maxLines="1" + android:imeOptions="actionDone" + android:inputType="text"/> + + <ImageButton + android:id="@+id/connect_button" + android:layout_width="48dp" + android:layout_height="48dp" + android:contentDescription="@string/connect_description" + android:background="@android:drawable/sym_action_call" /> + + <ImageButton + android:id="@+id/add_favorite_button" + android:layout_width="48dp" + android:layout_height="48dp" + android:contentDescription="@string/add_favorite_description" + android:background="@android:drawable/ic_input_add" /> + </LinearLayout> + + <TextView + android:id="@+id/room_listview_description" + android:layout_width="match_parent" + android:layout_height="48dp" + android:layout_marginTop="8dp" + android:lines="1" + android:maxLines="1" + android:textAppearance="?android:attr/textAppearanceMedium" + android:text="@string/favorites" + android:gravity="center_vertical"/> + + <FrameLayout + android:layout_width="match_parent" + android:layout_height="0dp" + android:layout_weight="1"> + + <ListView + android:id="@+id/room_listview" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:drawSelectorOnTop="false" /> + + <TextView + android:id="@android:id/empty" + android:layout_width="match_parent" + android:layout_height="match_parent" + android:gravity="center" + android:text="@string/no_favorites" /> + </FrameLayout> +</LinearLayout> diff --git a/third_party/libwebrtc/examples/androidapp/res/layout/fragment_call.xml b/third_party/libwebrtc/examples/androidapp/res/layout/fragment_call.xml new file mode 100644 index 0000000000..90b1e9ca0e --- /dev/null +++ b/third_party/libwebrtc/examples/androidapp/res/layout/fragment_call.xml @@ -0,0 +1,77 @@ +<?xml version="1.0" encoding="utf-8"?> + +<RelativeLayout + xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_width="match_parent" + android:layout_height="match_parent"> + + <TextView + android:id="@+id/contact_name_call" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_centerHorizontal="true" + android:layout_above="@+id/buttons_call_container" + android:textSize="24sp" + android:layout_margin="8dp"/> + + <LinearLayout + android:id="@+id/buttons_call_container" + android:orientation="horizontal" + android:layout_above="@+id/capture_format_text_call" + android:layout_alignWithParentIfMissing="true" + android:layout_marginBottom="32dp" + android:layout_centerHorizontal="true" + android:layout_width="wrap_content" + android:layout_height="wrap_content"> + + <ImageButton + android:id="@+id/button_call_disconnect" + android:background="@drawable/disconnect" + android:contentDescription="@string/disconnect_call" + android:layout_marginEnd="16dp" + android:layout_width="48dp" + android:layout_height="48dp"/> + + <ImageButton + android:id="@+id/button_call_switch_camera" + android:background="@android:drawable/ic_menu_camera" + android:contentDescription="@string/switch_camera" + android:layout_marginEnd="8dp" + android:layout_width="48dp" + android:layout_height="48dp"/> + + <ImageButton + android:id="@+id/button_call_scaling_mode" + android:background="@drawable/ic_action_return_from_full_screen" + android:contentDescription="@string/disconnect_call" + android:layout_width="48dp" + android:layout_height="48dp"/> + + <ImageButton + android:id="@+id/button_call_toggle_mic" + android:background="@android:drawable/ic_btn_speak_now" + android:contentDescription="@string/toggle_mic" + android:layout_marginEnd="8dp" + android:layout_width="48dp" + android:layout_height="48dp"/> + </LinearLayout> + + <TextView + android:id="@+id/capture_format_text_call" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_centerHorizontal="true" + android:layout_above="@+id/capture_format_slider_call" + android:textSize="16sp" + android:text="@string/capture_format_change_text"/> + + <SeekBar + android:id="@+id/capture_format_slider_call" + android:layout_width="match_parent" + android:layout_height="wrap_content" + android:layout_centerHorizontal="true" + android:layout_alignParentBottom="true" + android:progress="50" + android:layout_margin="8dp"/> + +</RelativeLayout> diff --git a/third_party/libwebrtc/examples/androidapp/res/layout/fragment_hud.xml b/third_party/libwebrtc/examples/androidapp/res/layout/fragment_hud.xml new file mode 100644 index 0000000000..483e7ba456 --- /dev/null +++ b/third_party/libwebrtc/examples/androidapp/res/layout/fragment_hud.xml @@ -0,0 +1,27 @@ +<?xml version="1.0" encoding="utf-8"?> + +<RelativeLayout + xmlns:android="http://schemas.android.com/apk/res/android" + android:layout_width="match_parent" + android:layout_height="match_parent"> + + <ImageButton + android:id="@+id/button_toggle_debug" + android:background="@android:drawable/ic_menu_info_details" + android:contentDescription="@string/toggle_debug" + android:layout_alignParentBottom="true" + android:layout_alignParentStart="true" + android:layout_width="48dp" + android:layout_height="48dp"/> + + <TextView + android:id="@+id/hud_stat_call" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:layout_alignParentEnd="true" + android:textStyle="bold" + android:textColor="#C000FF00" + android:textSize="12sp" + android:layout_margin="8dp"/> + +</RelativeLayout> |