diff --git a/assets/en/momotalk/SORT_OFF.png b/assets/en/momotalk/SORT_ASCENDING.png similarity index 59% rename from assets/en/momotalk/SORT_OFF.png rename to assets/en/momotalk/SORT_ASCENDING.png index bd1203a..617998d 100644 Binary files a/assets/en/momotalk/SORT_OFF.png and b/assets/en/momotalk/SORT_ASCENDING.png differ diff --git a/assets/en/momotalk/SORT_ON.png b/assets/en/momotalk/SORT_DESCENDING.png similarity index 60% rename from assets/en/momotalk/SORT_ON.png rename to assets/en/momotalk/SORT_DESCENDING.png index 4d917da..f97331a 100644 Binary files a/assets/en/momotalk/SORT_ON.png and b/assets/en/momotalk/SORT_DESCENDING.png differ diff --git a/tasks/momotalk/assets/assets_momotalk.py b/tasks/momotalk/assets/assets_momotalk.py index 6f4ca49..3f0de62 100644 --- a/tasks/momotalk/assets/assets_momotalk.py +++ b/tasks/momotalk/assets/assets_momotalk.py @@ -113,26 +113,26 @@ SKIP = ButtonWrapper( button=(1192, 103, 1229, 141), ), ) -SORT_OFF = ButtonWrapper( - name='SORT_OFF', +SORT_ASCENDING = ButtonWrapper( + name='SORT_ASCENDING', jp=None, en=Button( - file='./assets/en/momotalk/SORT_OFF.png', - area=(591, 158, 662, 199), - search=(571, 138, 682, 219), - color=(235, 237, 238), - button=(591, 158, 662, 199), + file='./assets/en/momotalk/SORT_ASCENDING.png', + area=(631, 166, 648, 188), + search=(611, 146, 668, 208), + color=(221, 228, 233), + button=(631, 166, 648, 188), ), ) -SORT_ON = ButtonWrapper( - name='SORT_ON', +SORT_DESCENDING = ButtonWrapper( + name='SORT_DESCENDING', jp=None, en=Button( - file='./assets/en/momotalk/SORT_ON.png', - area=(594, 159, 658, 196), - search=(574, 139, 678, 216), - color=(233, 235, 236), - button=(594, 159, 658, 196), + file='./assets/en/momotalk/SORT_DESCENDING.png', + area=(631, 166, 648, 189), + search=(611, 146, 668, 209), + color=(221, 228, 234), + button=(631, 166, 648, 189), ), ) STORY = ButtonWrapper( diff --git a/tasks/momotalk/ui.py b/tasks/momotalk/ui.py index 4f82ff7..a41d080 100644 --- a/tasks/momotalk/ui.py +++ b/tasks/momotalk/ui.py @@ -19,8 +19,8 @@ SWITCH_UNREAD.add_state("on", UNREAD_ON) SWITCH_UNREAD.add_state("off", UNREAD_OFF) SWITCH_SORT = Switch("Sort_switch") -SWITCH_SORT.add_state("on", SORT_ON) -SWITCH_SORT.add_state("off", SORT_OFF) +SWITCH_SORT.add_state("ascending", SORT_ASCENDING) +SWITCH_SORT.add_state("descending", SORT_DESCENDING) """Required for template matching as reply and story button can be found in different locations""" @@ -145,7 +145,7 @@ class MomoTalkUI(UI): """ if self.match_color(FIRST_UNREAD, threshold=80) and self.select_then_disappear(FIRST_UNREAD, SELECT_STUDENT, force_select=True): return True - logger.warn("No students available for interaction") + logger.warning("No students available for interaction") return False def chat(self):