ManaPlus
virtshortcutcontainer.h
Go to the documentation of this file.
1 /*
2  * The ManaPlus Client
3  * Copyright (C) 2009 The Mana World Development Team
4  * Copyright (C) 2011-2019 The ManaPlus Developers
5  * Copyright (C) 2009-2021 Andrei Karas
6  *
7  * This file is part of The ManaPlus Client.
8  *
9  * This program is free software; you can redistribute it and/or modify
10  * it under the terms of the GNU General Public License as published by
11  * the Free Software Foundation; either version 2 of the License, or
12  * any later version.
13  *
14  * This program is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17  * GNU General Public License for more details.
18  *
19  * You should have received a copy of the GNU General Public License
20  * along with this program. If not, see <http://www.gnu.org/licenses/>.
21  */
22 
23 #ifndef GUI_WIDGETS_VIRTSHORTCUTCONTAINER_H
24 #define GUI_WIDGETS_VIRTSHORTCUTCONTAINER_H
25 
27 
28 class ShortcutBase;
29 
36 {
37  public:
41  VirtShortcutContainer(Widget2 *const widget,
42  ShortcutBase *const shortcut);
43 
45 
46 
49  ~VirtShortcutContainer() override final;
50 
54  void draw(Graphics *const graphics) override final A_NONNULL(2);
55 
56  void safeDraw(Graphics *const graphics) override final A_NONNULL(2);
57 
61  void mouseDragged(MouseEvent &event) override final;
62 
66  void mousePressed(MouseEvent &event) override final;
67 
71  void mouseReleased(MouseEvent &event) override final;
72 
73  void widgetHidden(const Event &event) override final;
74 
75  void mouseExited(MouseEvent &event) override final;
76 
77  void mouseMoved(MouseEvent &event) override final;
78 
79  void setSkin(const Widget2 *const widget,
80  Skin *const skin) override final;
81 
82  private:
84 
89 
91 };
92 
93 #endif // GUI_WIDGETS_VIRTSHORTCUTCONTAINER_H
Definition: color.h:76
Definition: event.h:79
Definition: skin.h:37
void mousePressed(MouseEvent &event)
void setSkin(const Widget2 *const widget, Skin *const skin)
VirtShortcutContainer(Widget2 *const widget, ShortcutBase *const shortcut)
void widgetHidden(const Event &event)
void draw(Graphics *const graphics)
void mouseDragged(MouseEvent &event)
void mouseMoved(MouseEvent &event)
void mouseExited(MouseEvent &event)
void safeDraw(Graphics *const graphics)
void mouseReleased(MouseEvent &event)
#define A_NONNULL(...)
Definition: localconsts.h:168
#define final
Definition: localconsts.h:46
#define A_DELETE_COPY(func)
Definition: localconsts.h:53
bool shortcut(InputEvent &event)
Definition: actions.cpp:35