mirror of
https://github.com/nextcloud/talk-android.git
synced 2024-11-27 08:55:54 +03:00
Notify a data set change only if the properties are set
Note that this still notifies a data set change if the properties are set to the same value that they had already, but at least it is not notified when no data was actually changed. Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
This commit is contained in:
parent
9f445efc1c
commit
719797b1d1
1 changed files with 3 additions and 6 deletions
|
@ -2070,23 +2070,20 @@ public class CallActivity extends CallBaseActivity {
|
|||
PeerConnectionEvent.PeerConnectionEventType.NICK_CHANGE) {
|
||||
if (participantDisplayItems.get(sessionId) != null) {
|
||||
participantDisplayItems.get(sessionId).setNick(peerConnectionEvent.getNick());
|
||||
participantsAdapter.notifyDataSetChanged();
|
||||
}
|
||||
participantsAdapter.notifyDataSetChanged();
|
||||
|
||||
} else if (peerConnectionEvent.getPeerConnectionEventType() ==
|
||||
PeerConnectionEvent.PeerConnectionEventType.VIDEO_CHANGE && !isVoiceOnlyCall) {
|
||||
if (participantDisplayItems.get(sessionId) != null) {
|
||||
participantDisplayItems.get(sessionId).setStreamEnabled(peerConnectionEvent.getChangeValue());
|
||||
participantsAdapter.notifyDataSetChanged();
|
||||
}
|
||||
participantsAdapter.notifyDataSetChanged();
|
||||
|
||||
} else if (peerConnectionEvent.getPeerConnectionEventType() ==
|
||||
PeerConnectionEvent.PeerConnectionEventType.AUDIO_CHANGE) {
|
||||
if (participantDisplayItems.get(sessionId) != null) {
|
||||
participantDisplayItems.get(sessionId).setAudioEnabled(peerConnectionEvent.getChangeValue());
|
||||
participantsAdapter.notifyDataSetChanged();
|
||||
}
|
||||
participantsAdapter.notifyDataSetChanged();
|
||||
|
||||
} else if (peerConnectionEvent.getPeerConnectionEventType() ==
|
||||
PeerConnectionEvent.PeerConnectionEventType.PUBLISHER_FAILED) {
|
||||
currentCallStatus = CallStatus.PUBLISHER_FAILED;
|
||||
|
|
Loading…
Reference in a new issue