mirror of
https://github.com/nextcloud/talk-android.git
synced 2024-11-27 17:08:34 +03:00
parent
77f8652177
commit
3c9953196a
2 changed files with 9 additions and 2 deletions
|
@ -280,8 +280,13 @@ public class CallsListController extends BaseController implements SearchView.On
|
|||
|
||||
adapter.updateDataSet(callItems, true);
|
||||
|
||||
Collections.sort(callItems, (callItem, t1) ->
|
||||
Long.compare(t1.getModel().getLastPing(), callItem.getModel().getLastPing()));
|
||||
if (currentUser.hasSpreedCapabilityWithName("last-room-activity")) {
|
||||
Collections.sort(callItems, (callItem, t1) ->
|
||||
Long.compare(t1.getModel().getLastActivity(), callItem.getModel().getLastActivity()));
|
||||
} else {
|
||||
Collections.sort(callItems, (callItem, t1) ->
|
||||
Long.compare(t1.getModel().getLastPing(), callItem.getModel().getLastPing()));
|
||||
}
|
||||
|
||||
if (searchItem != null) {
|
||||
searchItem.setVisible(callItems.size() > 0);
|
||||
|
|
|
@ -65,6 +65,8 @@ public class Room {
|
|||
public String password;
|
||||
@JsonField(name = "isFavorite")
|
||||
public boolean isFavorite;
|
||||
@JsonField(name = "lastActivity")
|
||||
public long lastActivity;
|
||||
|
||||
public boolean isPublic() {
|
||||
return (RoomType.ROOM_PUBLIC_CALL.equals(type));
|
||||
|
|
Loading…
Reference in a new issue