diff options
-rw-r--r-- | src/contact.py | 2 | ||||
-rw-r--r-- | src/tabs.py | 5 |
2 files changed, 4 insertions, 3 deletions
diff --git a/src/contact.py b/src/contact.py index 3de2f496..3a8e38ab 100644 --- a/src/contact.py +++ b/src/contact.py @@ -148,7 +148,7 @@ class Contact(object): def get_resources(self): """Return all resources, sorted by priority """ compare_resources = lambda x: x.priority - return sorted(self.resources, key=compare_resources) + return sorted(self.resources, key=compare_resources, reverse=True) def get_highest_priority_resource(self): """Return the resource with the highest priority""" diff --git a/src/tabs.py b/src/tabs.py index 4d52a285..7a9affb8 100644 --- a/src/tabs.py +++ b/src/tabs.py @@ -2424,10 +2424,11 @@ class RosterInfoTab(Tab): res.status if res else '',) elif isinstance(selected_row, Resource): res = selected_row - msg = 'Resource: %s (%s)\nCurrent status: %s' % ( + msg = 'Resource: %s (%s)\nCurrent status: %s\nPriority: %s' % ( res.jid, res.presence, - res.status,) + res.status, + res.priority) elif isinstance(selected_row, RosterGroup): rg = selected_row msg = 'Group: %s [%s/%s] contacts online' % ( |