umbrello  2.32.1
Umbrello UML Modeller is a Unified Modelling Language (UML) diagram program based on KDE Technology
toolbarstatefactory.h
Go to the documentation of this file.
1 /***************************************************************************
2  * *
3  * This program is free software; you can redistribute it and/or modify *
4  * it under the terms of the GNU General Public License as published by *
5  * the Free Software Foundation; either version 2 of the License, or *
6  * (at your option) any later version. *
7  * *
8  * copyright (C) 2004-2020 *
9  * Umbrello UML Modeller Authors <umbrello-devel@kde.org> *
10  ***************************************************************************/
11 
12 #ifndef TOOLBARSTATEFACTORY_H
13 #define TOOLBARSTATEFACTORY_H
14 
15 #include "toolbarstate.h"
16 
17 #include "worktoolbar.h"
18 
19 #include <QPointer>
20 #define NR_OF_TOOLBAR_STATES 5
21 
22 
23 
34 {
35 public:
36  // constructor.
38 
39  // Destructor
40  virtual ~ToolBarStateFactory();
41 
42  ToolBarState* getState(const WorkToolBar::ToolBar_Buttons &toolbarButton, UMLScene* umlScene);
43 
44 protected:
45  int getKey(const WorkToolBar::ToolBar_Buttons &toolbarButton) const;
46 
47 protected:
48  QPointer<ToolBarState> m_states[NR_OF_TOOLBAR_STATES];
49 };
50 
51 #endif //TOOLBARSTATEFACTORY_H
Definition: toolbarstatefactory.h:34
ToolBarState * getState(const WorkToolBar::ToolBar_Buttons &toolbarButton, UMLScene *umlScene)
Definition: toolbarstatefactory.cpp:40
QPointer< ToolBarState > m_states[NR_OF_TOOLBAR_STATES]
Definition: toolbarstatefactory.h:48
virtual ~ToolBarStateFactory()
Definition: toolbarstatefactory.cpp:30
ToolBarStateFactory()
Definition: toolbarstatefactory.cpp:22
int getKey(const WorkToolBar::ToolBar_Buttons &toolbarButton) const
Definition: toolbarstatefactory.cpp:67
Definition: toolbarstate.h:70
Definition: umlscene.h:70
ToolBar_Buttons
Definition: worktoolbar.h:57
#define NR_OF_TOOLBAR_STATES
Definition: toolbarstatefactory.h:20