449 |
449 |
450 for category in self.__categoryToActions: |
450 for category in self.__categoryToActions: |
451 if action in self.__categoryToActions[category]: |
451 if action in self.__categoryToActions[category]: |
452 self.__categoryToActions[category].remove(action) |
452 self.__categoryToActions[category].remove(action) |
453 |
453 |
|
454 def removeCategoryActions(self, category): |
|
455 """ |
|
456 Public method to remove the actions belonging to a category. |
|
457 |
|
458 @param category category for the actions (string) |
|
459 """ |
|
460 for action in self.categoryActions(category): |
|
461 self.removeAction(action) |
|
462 |
454 def saveState(self, version=0): |
463 def saveState(self, version=0): |
455 """ |
464 """ |
456 Public method to save the state of the toolbar manager. |
465 Public method to save the state of the toolbar manager. |
457 |
466 |
458 @param version version number stored with the data (integer) |
467 @param version version number stored with the data (integer) |
637 |
646 |
638 def categoryActions(self, category): |
647 def categoryActions(self, category): |
639 """ |
648 """ |
640 Public method to get the actions belonging to a category. |
649 Public method to get the actions belonging to a category. |
641 |
650 |
642 @param category category for the toolbar (string) |
651 @param category category for the actions (string) |
643 @return list of actions (list of QAction) |
652 @return list of actions (list of QAction) |
644 """ |
653 """ |
645 if category not in self.__categoryToActions: |
654 if category not in self.__categoryToActions: |
646 return [] |
655 return [] |
647 |
656 |