mirror of
https://github.com/nextcloud/talk-android
synced 2025-06-20 03:59:35 +01:00
Improve settings & Update webrtc stuff
Signed-off-by: Mario Danic <mario@lovelyhq.com>
This commit is contained in:
parent
ba5de1a7e0
commit
a49cab9b84
@ -612,8 +612,9 @@ public class CallActivity extends AppCompatActivity {
|
|||||||
|
|
||||||
private void gotRemoteStream(MediaStream stream) {
|
private void gotRemoteStream(MediaStream stream) {
|
||||||
//we have remote video stream. add to the renderer.
|
//we have remote video stream. add to the renderer.
|
||||||
final VideoTrack videoTrack = stream.videoTracks.getFirst();
|
if (stream.videoTracks.size() == 1 && stream.audioTracks.size() == 1) {
|
||||||
AudioTrack audioTrack = stream.audioTracks.getFirst();
|
final VideoTrack videoTrack = stream.videoTracks.get(0);
|
||||||
|
AudioTrack audioTrack = stream.audioTracks.get(0);
|
||||||
runOnUiThread(new Runnable() {
|
runOnUiThread(new Runnable() {
|
||||||
@Override
|
@Override
|
||||||
public void run() {
|
public void run() {
|
||||||
@ -625,6 +626,7 @@ public class CallActivity extends AppCompatActivity {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -108,6 +108,9 @@ public class SettingsController extends BaseController {
|
|||||||
@BindView(R.id.display_name_text)
|
@BindView(R.id.display_name_text)
|
||||||
TextView displayNameTextView;
|
TextView displayNameTextView;
|
||||||
|
|
||||||
|
@BindView(R.id.base_url_text)
|
||||||
|
TextView baseUrlTextView;
|
||||||
|
|
||||||
@BindView(R.id.settings_remove_account)
|
@BindView(R.id.settings_remove_account)
|
||||||
MaterialStandardPreference removeAccountButton;
|
MaterialStandardPreference removeAccountButton;
|
||||||
|
|
||||||
@ -138,6 +141,8 @@ public class SettingsController extends BaseController {
|
|||||||
@Inject
|
@Inject
|
||||||
UserUtils userUtils;
|
UserUtils userUtils;
|
||||||
|
|
||||||
|
private UserEntity userEntity;
|
||||||
|
|
||||||
private OnPreferenceValueChangedListener<String> proxyTypeChangeListener;
|
private OnPreferenceValueChangedListener<String> proxyTypeChangeListener;
|
||||||
private OnPreferenceValueChangedListener<Boolean> proxyCredentialsChangeListener;
|
private OnPreferenceValueChangedListener<Boolean> proxyCredentialsChangeListener;
|
||||||
|
|
||||||
@ -204,8 +209,11 @@ public class SettingsController extends BaseController {
|
|||||||
|
|
||||||
versionInfo.setSummary("v" + BuildConfig.VERSION_NAME);
|
versionInfo.setSummary("v" + BuildConfig.VERSION_NAME);
|
||||||
|
|
||||||
UserEntity userEntity = userUtils.getCurrentUser();
|
userEntity = userUtils.getCurrentUser();
|
||||||
if (userEntity != null) {
|
if (userEntity != null) {
|
||||||
|
|
||||||
|
baseUrlTextView.setText(userEntity.getBaseUrl());
|
||||||
|
|
||||||
reauthorizeButton.setOnClickListener(view14 -> {
|
reauthorizeButton.setOnClickListener(view14 -> {
|
||||||
reauthorizeButton.setEnabled(false);
|
reauthorizeButton.setEnabled(false);
|
||||||
getParentController().getRouter().pushController(RouterTransaction.with(
|
getParentController().getRouter().pushController(RouterTransaction.with(
|
||||||
@ -251,7 +259,7 @@ public class SettingsController extends BaseController {
|
|||||||
hideProxyCredentials();
|
hideProxyCredentials();
|
||||||
}
|
}
|
||||||
|
|
||||||
UserEntity userEntity = userUtils.getCurrentUser();
|
userEntity = userUtils.getCurrentUser();
|
||||||
if (userEntity != null) {
|
if (userEntity != null) {
|
||||||
// Awful hack
|
// Awful hack
|
||||||
if (userEntity.getDisplayName() != null) {
|
if (userEntity.getDisplayName() != null) {
|
||||||
|
@ -63,13 +63,22 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_below="@id/avatar_image"
|
android:layout_below="@id/avatar_image"
|
||||||
android:layout_centerHorizontal="true"
|
android:layout_centerHorizontal="true"
|
||||||
android:layout_margin="@dimen/margin_between_elements"/>
|
android:layout_marginTop="@dimen/margin_between_elements"/>
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/base_url_text"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_below="@id/display_name_text"
|
||||||
|
android:layout_centerHorizontal="true"
|
||||||
|
android:layout_margin="4dp"/>
|
||||||
|
|
||||||
|
|
||||||
<com.yarolegovich.mp.MaterialStandardPreference
|
<com.yarolegovich.mp.MaterialStandardPreference
|
||||||
android:id="@+id/settings_switch"
|
android:id="@+id/settings_switch"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_below="@id/display_name_text"
|
android:layout_below="@id/base_url_text"
|
||||||
android:tag="switchAccountButton"
|
android:tag="switchAccountButton"
|
||||||
apc:mp_title="@string/nc_settings_switch_account"/>
|
apc:mp_title="@string/nc_settings_switch_account"/>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user