def _create_bindings(self, wnd):
		BaseFrame._create_bindings(self, wnd)
		wnd.Bind(wx.EVT_LISTBOX, self._on_folders_listbox, self._lb_folders)
		wnd.Bind(wx.EVT_LIST_ITEM_ACTIVATED, self._on_pages_list_activated,
				self._lb_pages)
		wnd.Bind(wx.EVT_LIST_COL_CLICK, self._on_pages_list_col_click)
		publisher.subscribe(self._on_notebook_update, ('notebook', 'update'))
		publisher.subscribe(self._on_notebook_update, ('notebook', 'delete'))
Beispiel #2
0
	def _create_bindings(self, wnd):
		BaseFrame._create_bindings(self, wnd)
		#self.wnd.Bind(wx.EVT_TEXT, self._on_search, self._searchbox)
		self.wnd.Bind(wx.EVT_SEARCHCTRL_SEARCH_BTN, self._on_search,
				self._searchbox)
		self.wnd.Bind(wx.EVT_SEARCHCTRL_CANCEL_BTN, self._on_search_cancel,
				self._searchbox)
		self.wnd.Bind(wx.EVT_TEXT_ENTER, self._on_search, self._searchbox)
		self.wnd.Bind(wx.EVT_BUTTON, self._on_search, id=wx.ID_FIND)
		wnd.Bind(wx.EVT_LIST_ITEM_ACTIVATED, self._on_items_list_activated,
				self._items_list_ctrl)
Beispiel #3
0
	def _create_bindings(self, wnd):
		BaseFrame._create_bindings(self, wnd)

		self._create_menu_bind('menu_file_load', self._on_menu_file_load)
		self._create_menu_bind('menu_file_save', self._on_menu_file_save)
		self._create_menu_bind('menu_file_exit', self._on_menu_file_exit)
		self._create_menu_bind('menu_file_sync', self._on_menu_file_sync)
		self._create_menu_bind('menu_file_export_tasks',
				self._on_menu_file_export_tasks)
		self._create_menu_bind('menu_help_about', self._on_menu_help_about)
		self._create_menu_bind('menu_task_new', self._on_menu_task_new)
		self._create_menu_bind('menu_task_quick', self._on_menu_task_quick)
		self._create_menu_bind('menu_task_edit', self._on_menu_task_edit)
		self._create_menu_bind('menu_task_delete', self._on_menu_task_delete)
		self._create_menu_bind('menu_task_clone', self._on_menu_task_clone)
		self._create_menu_bind('menu_notebook_open', self._on_menu_notebook_open)
		self._create_menu_bind('menu_task_complete', self._on_menu_task_complete)
		self._create_menu_bind('menu_task_starred', self._on_menu_task_starred)
		self._create_menu_bind('menu_search_task', self._on_menu_search_task)
		self._create_menu_bind('menu_sett_tags', self._on_menu_sett_tags)
		self._create_menu_bind('menu_sett_goals', self._on_menu_sett_goals)
		self._create_menu_bind('menu_sett_folders', self._on_menu_sett_folders)
		self._create_menu_bind('menu_sett_contexts', self._on_menu_sett_contexts)
		self._create_menu_bind('menu_sett_preferences',
				self._on_menu_sett_preferences)

		wnd.Bind(wx.EVT_TREE_ITEM_ACTIVATED, self._on_filter_tree_item_activated,
				self._filter_tree_ctrl)
		wnd.Bind(CT.EVT_TREE_ITEM_CHECKED, self._on_filter_tree_item_selected,
				self._filter_tree_ctrl)
		wnd.Bind(wx.EVT_RADIOBOX, self._on_rb_show_selection,
				self['rb_show_selection'])
		wnd.Bind(wx.EVT_LIST_ITEM_ACTIVATED, self._on_items_list_activated,
				self._items_list_ctrl)
		self._items_list_ctrl.Bind(wx.EVT_COMMAND_RIGHT_CLICK,
				self._on_items_list_right_click)
		self._items_list_ctrl.Bind(wx.EVT_RIGHT_UP,
				self._on_items_list_right_click)
		self._items_list_ctrl.Bind(TLC.EVT_DRAG_TASK, self._on_item_drag)
		wnd.Bind(wx.EVT_BUTTON, self._on_btn_path_back, id=wx.ID_UP)
		wnd.Bind(wx.EVT_BUTTON, self._on_btn_edit_parent,
				self['btn_parent_edit'])
		wnd.Bind(wx.EVT_TIMER, self._on_timer)
		wnd.Bind(wx.EVT_ICONIZE, self._on_window_iconze)

		publisher.subscribe(self._on_tasks_update, ('task', 'update'))
		publisher.subscribe(self._on_tasks_update, ('task', 'delete'))
		publisher.subscribe(self._on_frame_messsage, ('gui', 'frame_main'))

		self._create_popup_menu_bindings(wnd)