ManaPlus
emoteshortcutcontainer.h
Go to the documentation of this file.
1 /*
2  * The ManaPlus Client
3  * Copyright (C) 2009 Aethyra Development Team
4  * Copyright (C) 2011-2019 The ManaPlus Developers
5  * Copyright (C) 2019-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_EMOTESHORTCUTCONTAINER_H
24 #define GUI_WIDGETS_EMOTESHORTCUTCONTAINER_H
25 
27 
28 struct EmoteSprite;
29 
36 {
37  public:
41  explicit EmoteShortcutContainer(Widget2 *restrict const widget);
42 
44 
45 
48  ~EmoteShortcutContainer() override final;
49 
53  void draw(Graphics *restrict graphics)
54  restrict2 override final A_NONNULL(2);
55 
56  void safeDraw(Graphics *restrict graphics)
57  restrict2 override final A_NONNULL(2);
58 
62  void mouseDragged(MouseEvent &restrict event)
63  restrict2 override final;
64 
68  void mousePressed(MouseEvent &restrict event) restrict2 override final;
69 
73  void mouseReleased(MouseEvent &restrict event)
74  restrict2 override final;
75 
76  void mouseMoved(MouseEvent &restrict event) restrict2 override final;
77 
78  void mouseExited(MouseEvent &restrict event) restrict2 override final;
79 
80  void widgetHidden(const Event &restrict event)
81  restrict2 override final;
82 
83  void setSkin(const Widget2 *const widget,
84  Skin *const skin) override final;
85 
86  private:
87  STD_VECTOR<const EmoteSprite*> mEmoteImg;
88 
90  unsigned char mEmoteMoved;
91 };
92 
93 #endif // GUI_WIDGETS_EMOTESHORTCUTCONTAINER_H
void widgetHidden(const Event &event)
void mousePressed(MouseEvent &event)
void mouseReleased(MouseEvent &event)
void draw(Graphics *graphics)
void setSkin(const Widget2 *const widget, Skin *const skin)
void mouseMoved(MouseEvent &event)
EmoteShortcutContainer(Widget2 *const widget)
std::vector< const EmoteSprite * > mEmoteImg
void safeDraw(Graphics *graphics)
void mouseExited(MouseEvent &event)
void mouseDragged(MouseEvent &event)
Definition: event.h:79
Definition: skin.h:37
#define restrict
Definition: localconsts.h:165
#define restrict2
Definition: localconsts.h:166
#define A_NONNULL(...)
Definition: localconsts.h:168
#define final
Definition: localconsts.h:46
#define A_DELETE_COPY(func)
Definition: localconsts.h:53