mirror of
https://github.com/nextcloud/talk-android
synced 2025-07-04 11:34:30 +01:00
display participants via flexbox layout
This commit is contained in:
parent
9f80e846cd
commit
e70751d945
@ -141,6 +141,8 @@ dependencies {
|
|||||||
|
|
||||||
implementation 'com.github.Kennyc1012:BottomSheet:2.4.0'
|
implementation 'com.github.Kennyc1012:BottomSheet:2.4.0'
|
||||||
|
|
||||||
|
implementation 'com.google.android:flexbox:0.3.1'
|
||||||
|
|
||||||
testImplementation 'junit:junit:4.12'
|
testImplementation 'junit:junit:4.12'
|
||||||
androidTestImplementation ('com.android.support.test.espresso:espresso-core:3.0.1', {
|
androidTestImplementation ('com.android.support.test.espresso:espresso-core:3.0.1', {
|
||||||
exclude group: 'com.android.support', module: 'support-annotations'
|
exclude group: 'com.android.support', module: 'support-annotations'
|
||||||
|
@ -51,6 +51,7 @@ import android.widget.TextView;
|
|||||||
import com.bluelinelabs.logansquare.LoganSquare;
|
import com.bluelinelabs.logansquare.LoganSquare;
|
||||||
import com.evernote.android.job.JobRequest;
|
import com.evernote.android.job.JobRequest;
|
||||||
import com.evernote.android.job.util.Device;
|
import com.evernote.android.job.util.Device;
|
||||||
|
import com.google.android.flexbox.FlexboxLayout;
|
||||||
import com.nextcloud.talk.R;
|
import com.nextcloud.talk.R;
|
||||||
import com.nextcloud.talk.api.NcApi;
|
import com.nextcloud.talk.api.NcApi;
|
||||||
import com.nextcloud.talk.api.helpers.api.ApiHelper;
|
import com.nextcloud.talk.api.helpers.api.ApiHelper;
|
||||||
@ -147,7 +148,7 @@ public class CallActivity extends AppCompatActivity {
|
|||||||
@BindView(R.id.relative_layout)
|
@BindView(R.id.relative_layout)
|
||||||
RelativeLayout relativeLayout;
|
RelativeLayout relativeLayout;
|
||||||
@BindView(R.id.remote_renderers_layout)
|
@BindView(R.id.remote_renderers_layout)
|
||||||
LinearLayout remoteRenderersLayout;
|
FlexboxLayout remoteRenderersLayout;
|
||||||
|
|
||||||
@BindView(R.id.call_controls)
|
@BindView(R.id.call_controls)
|
||||||
RelativeLayout callControls;
|
RelativeLayout callControls;
|
||||||
@ -1217,14 +1218,6 @@ public class CallActivity extends AppCompatActivity {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onConfigurationChanged(Configuration newConfig) {
|
public void onConfigurationChanged(Configuration newConfig) {
|
||||||
|
|
||||||
// Checks the orientation of the screen
|
|
||||||
if (newConfig.orientation == Configuration.ORIENTATION_LANDSCAPE) {
|
|
||||||
remoteRenderersLayout.setOrientation(LinearLayout.HORIZONTAL);
|
|
||||||
} else if (newConfig.orientation == Configuration.ORIENTATION_PORTRAIT) {
|
|
||||||
remoteRenderersLayout.setOrientation(LinearLayout.VERTICAL);
|
|
||||||
}
|
|
||||||
|
|
||||||
super.onConfigurationChanged(newConfig);
|
super.onConfigurationChanged(newConfig);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -21,20 +21,23 @@
|
|||||||
|
|
||||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
android:id="@+id/relative_layout"
|
android:id="@+id/relative_layout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:fitsSystemWindows="true"
|
android:fitsSystemWindows="true"
|
||||||
tools:context=".activities.CallActivity">
|
tools:context=".activities.CallActivity">
|
||||||
|
|
||||||
<LinearLayout
|
<com.google.android.flexbox.FlexboxLayout
|
||||||
android:id="@+id/remote_renderers_layout"
|
android:id="@+id/remote_renderers_layout"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:animateLayoutChanges="true"
|
android:animateLayoutChanges="true"
|
||||||
android:background="#000000"
|
android:background="#000000"
|
||||||
android:orientation="vertical">
|
android:visibility="invisible"
|
||||||
</LinearLayout>
|
app:flexWrap="wrap"
|
||||||
|
app:alignItems="flex_end"
|
||||||
|
app:alignContent="flex_end"/>
|
||||||
|
|
||||||
<org.webrtc.SurfaceViewRenderer
|
<org.webrtc.SurfaceViewRenderer
|
||||||
android:id="@+id/pip_video_view"
|
android:id="@+id/pip_video_view"
|
||||||
|
Loading…
Reference in New Issue
Block a user