mirror of
https://github.com/nextcloud/talk-android.git
synced 2024-11-28 09:38:14 +03:00
Fix bugs
Signed-off-by: Mario Danic <mario@lovelyhq.com>
This commit is contained in:
parent
9ef1128b59
commit
e44ce6e7b4
1 changed files with 11 additions and 7 deletions
|
@ -369,10 +369,12 @@ public class CallActivity extends AppCompatActivity {
|
||||||
}
|
}
|
||||||
|
|
||||||
private void startVideoCapture() {
|
private void startVideoCapture() {
|
||||||
|
if (videoCapturer != null) {
|
||||||
Resources r = getResources();
|
Resources r = getResources();
|
||||||
int px = (int) TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 120, r.getDisplayMetrics());
|
int px = (int) TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 120, r.getDisplayMetrics());
|
||||||
videoCapturerAndroid.startCapture(px, px, 30);
|
videoCapturerAndroid.startCapture(px, px, 30);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
private void joinRoomAndCall() {
|
private void joinRoomAndCall() {
|
||||||
ncApi.joinRoom(credentials, ApiHelper.getUrlForRoom(userEntity.getBaseUrl(), roomToken))
|
ncApi.joinRoom(credentials, ApiHelper.getUrlForRoom(userEntity.getBaseUrl(), roomToken))
|
||||||
|
@ -796,12 +798,14 @@ public class CallActivity extends AppCompatActivity {
|
||||||
public void onStop() {
|
public void onStop() {
|
||||||
super.onStop();
|
super.onStop();
|
||||||
eventBus.unregister(this);
|
eventBus.unregister(this);
|
||||||
|
if (videoCapturer != null) {
|
||||||
try {
|
try {
|
||||||
videoCapturer.stopCapture();
|
videoCapturer.stopCapture();
|
||||||
} catch (InterruptedException e) {
|
} catch (InterruptedException e) {
|
||||||
Log.e(TAG, "Failed to stop the capturing process");
|
Log.e(TAG, "Failed to stop the capturing process");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Subscribe(threadMode = ThreadMode.BACKGROUND)
|
@Subscribe(threadMode = ThreadMode.BACKGROUND)
|
||||||
public void onMessageEvent(PeerConnectionEvent peerConnectionEvent) {
|
public void onMessageEvent(PeerConnectionEvent peerConnectionEvent) {
|
||||||
|
|
Loading…
Reference in a new issue