Bind Filter create function to menu bar

This commit is contained in:
Manuel Cortez 2025-03-07 10:13:34 -06:00
parent 3f72185817
commit 00e5766f90

View File

@ -165,6 +165,7 @@ class Controller(object):
widgetUtils.connect_event(self.view, widgetUtils.MENU, self.update_buffer, self.view.update_buffer) widgetUtils.connect_event(self.view, widgetUtils.MENU, self.update_buffer, self.view.update_buffer)
widgetUtils.connect_event(self.view, widgetUtils.MENU, self.manage_aliases, self.view.manageAliases) widgetUtils.connect_event(self.view, widgetUtils.MENU, self.manage_aliases, self.view.manageAliases)
widgetUtils.connect_event(self.view, widgetUtils.MENU, self.report_error, self.view.reportError) widgetUtils.connect_event(self.view, widgetUtils.MENU, self.report_error, self.view.reportError)
widgetUtils.connect_event(self.view, widgetUtils.MENU, self.create_filter, self.view.filter)
def set_systray_icon(self): def set_systray_icon(self):
self.systrayIcon = sysTrayIcon.SysTrayIcon() self.systrayIcon = sysTrayIcon.SysTrayIcon()
@ -1155,3 +1156,9 @@ class Controller(object):
handler = self.get_handler(type=buffer.session.type) handler = self.get_handler(type=buffer.session.type)
if handler and hasattr(handler, 'community_timeline'): if handler and hasattr(handler, 'community_timeline'):
handler.community_timeline(self, buffer) handler.community_timeline(self, buffer)
def create_filter(self, *args, **kwargs):
buffer = self.get_best_buffer()
handler = self.get_handler(type=buffer.session.type)
if handler and hasattr(handler, 'create_filter'):
handler.create_filter(self, buffer)