def keypress(self, size, key): """ Handle keypress. Can switch tabs, control playback, flags, notifications and app state. """ for tab in self.tabs: if 'meta {}'.format(tab.page.key) == key: self.set_page(tab.page.__class__.__name__) return hotkey_manager.keypress("global", self, super(AppWidget, self), size, key)
def keypress(self, size, key): """ Handle keypress. """ return hotkey_manager.keypress("station_page", self, super(MyStationListItem, self), size, key)
def keypress(self, size, key): """ Handle keypress. """ return hotkey_manager.keypress("playlist_page", self, super(MyPlaylistListItem, self), size, key)
def keypress(self, size, key): if key in ascii_letters + digits + ' _-.,?!()[]/': self.perform_filtering(key) elif key == 'backspace': self.perform_filtering(key) elif self._is_filtering: try: return hotkey_manager.keypress("library_view", self, super(SongListBox, self), size, key) except IndexError: pass else: return super(SongListBox, self).keypress(size, key) return None
def keypress(self, _, key): """ Handle equalizer band modification. """ return hotkey_manager.keypress("settings_page", self, None, None, key)
def keypress(self, _, key): """ Handle heypress. """ return hotkey_manager.keypress("debug_page", self, None, None, key)
def keypress(self, size, key): """ Handle keypress. """ return hotkey_manager.keypress("library_item", self, super(SongListItem, self), size, key)
def keypress(self, size, key): """ Handle keypress. """ return hotkey_manager.keypress("search_page", self, super(SearchBox, self), size, key)