def createEditToolBarUICommands(self): ''' UI commands for editing items. ''' editCommand = uicommand.Edit(viewer=self) self.deleteUICommand = uicommand.Delete(viewer=self) # For unittests pylint: disable=W0201 editCommand.bind(self, wx.ID_EDIT) self.deleteUICommand.bind(self, wx.ID_DELETE) return editCommand, self.deleteUICommand
def createWidget(self): imageList = self.createImageList() itemPopupMenu = menu.AttachmentPopupMenu(self.parent, self.settings, self.presentation(), self) columnPopupMenu = menu.ColumnPopupMenu(self) self._popupMenus.extend([itemPopupMenu, columnPopupMenu]) self._columns = self._createColumns() widget = widgets.VirtualListCtrl(self, self.columns(), self.onSelect, uicommand.Edit(viewer=self), itemPopupMenu, columnPopupMenu, resizeableColumn=1, **self.widgetCreationKeywordArguments()) widget.SetColumnWidth(0, 150) widget.AssignImageList(imageList, wx.IMAGE_LIST_SMALL) return widget
def createWidget(self): imageList = self.createImageList() # Has side-effects self._columns = self._createColumns() itemPopupMenu = menu.NotePopupMenu(self.parent, self.settings, self.taskFile.categories(), self) columnPopupMenu = menu.ColumnPopupMenu(self) self._popupMenus.extend([itemPopupMenu, columnPopupMenu]) widget = widgets.TreeListCtrl(self, self.columns(), self.onSelect, uicommand.Edit(viewer=self), uicommand.NoteDragAndDrop(viewer=self, notes=self.presentation()), itemPopupMenu, columnPopupMenu, **self.widgetCreationKeywordArguments()) widget.AssignImageList(imageList) # pylint: disable=E1101 return widget
def createWidget(self): imageList = self.createImageList() # Has side-effects self._columns = self._createColumns() itemPopupMenu = self.createCategoryPopupMenu() columnPopupMenu = menu.ColumnPopupMenu(self) self._popupMenus.extend([itemPopupMenu, columnPopupMenu]) widget = widgets.CheckTreeCtrl( self, self._columns, self.onSelect, self.onCheck, uicommand.Edit(viewer=self), uicommand.CategoryDragAndDrop(viewer=self, categories=self.presentation()), itemPopupMenu, columnPopupMenu, **self.widgetCreationKeywordArguments()) widget.AssignImageList(imageList) # pylint: disable=E1101 return widget
def createWidget(self): imageList = self.createImageList() # Has side-effects self._columns = self._createColumns() # pylint: disable=W0201 itemPopupMenu = menu.EffortPopupMenu(self.parent, self.taskFile.tasks(), self.taskFile.efforts(), self.settings, self) columnPopupMenu = menu.EffortViewerColumnPopupMenu(self) self._popupMenus.extend([itemPopupMenu, columnPopupMenu]) widget = widgets.VirtualListCtrl( self, self.columns(), self.onSelect, uicommand.Edit(viewer=self), itemPopupMenu, columnPopupMenu, resizeableColumn=1, **self.widgetCreationKeywordArguments()) widget.AssignImageList(imageList, wx.IMAGE_LIST_SMALL) # pylint: disable=E1101 return widget