diff --git a/gertty/view/change_list.py b/gertty/view/change_list.py index d2fa671..8475207 100644 --- a/gertty/view/change_list.py +++ b/gertty/view/change_list.py @@ -154,6 +154,10 @@ class ChangeListHeader(urwid.WidgetWrap): class ChangeListView(urwid.WidgetWrap): def help(self): key = self.app.config.keymap.formatKeys + if self.project_key: + refresh_help = "Sync current project" + else: + refresh_help = "Sync subscribed projects" return [ (key(keymap.TOGGLE_HELD), "Toggle the held flag for the currently selected change"), @@ -168,7 +172,7 @@ class ChangeListView(urwid.WidgetWrap): (key(keymap.TOGGLE_STARRED), "Toggle the starred flag for the currently selected change"), (key(keymap.REFRESH), - "Sync all projects"), + refresh_help), (key(keymap.SORT_BY_NUMBER), "Sort changes by number"), (key(keymap.SORT_BY_UPDATED), @@ -455,8 +459,12 @@ class ChangeListView(urwid.WidgetWrap): row.update(change, self.categories) return None if keymap.REFRESH in commands: - self.app.sync.submitTask( - sync.SyncSubscribedProjectsTask(sync.HIGH_PRIORITY)) + if self.project_key: + self.app.sync.submitTask( + sync.SyncProjectTask(self.project_key, sync.HIGH_PRIORITY)) + else: + self.app.sync.submitTask( + sync.SyncSubscribedProjectsTask(sync.HIGH_PRIORITY)) self.app.status.update() return None if keymap.SORT_BY_NUMBER in commands: diff --git a/gertty/view/project_list.py b/gertty/view/project_list.py index 97ef5e2..49d788a 100644 --- a/gertty/view/project_list.py +++ b/gertty/view/project_list.py @@ -79,7 +79,7 @@ class ProjectListView(urwid.WidgetWrap): (key(keymap.TOGGLE_SUBSCRIBED), "Toggle the subscription flag for the currently selected project"), (key(keymap.REFRESH), - "Sync all projects") + "Sync subscribed projects") ] def __init__(self, app):