ScummVM API documentation
container_widget_gump.h
1 /* ScummVM - Graphic Adventure Engine
2  *
3  * ScummVM is the legal property of its developers, whose names
4  * are too numerous to list here. Please refer to the COPYRIGHT
5  * file distributed with this source distribution.
6  *
7  * This program is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program. If not, see <http://www.gnu.org/licenses/>.
19  *
20  */
21 
22 #ifndef NUVIE_VIEWS_CONTAINER_WIDGET_GUMP_H
23 #define NUVIE_VIEWS_CONTAINER_WIDGET_GUMP_H
24 
25 #include "ultima/nuvie/gui/widgets/gui_widget.h"
26 #include "ultima/nuvie/core/obj_manager.h"
27 #include "ultima/nuvie/views/container_widget.h"
28 
29 namespace Ultima {
30 namespace Nuvie {
31 
32 class Configuration;
33 class TileManager;
34 class Actor;
35 class Font;
36 
38 
39 private:
40  sint16 cursor_x;
41  uint16 cursor_y;
42  sint16 check_x, check_y;
43  const Tile *cursor_tile;
44  bool show_cursor;
45 
46 public:
47  ContainerWidgetGump(const Configuration *cfg, GUI_CallBack *callback = nullptr);
48  ~ContainerWidgetGump() override;
49 
50  bool init(Actor *a, uint16 x, uint16 y, uint8 Cols, uint8 Rows, TileManager *tm, ObjManager *om, Font *f, uint8 check_xoff, uint8 check_yoff);
51 
52  void Display(bool full_redraw) override;
53  GUI_status KeyDown(const Common::KeyState &key) override;
54 
55  void set_actor(Actor *a) override;
56 private:
57 
58  void cursor_right();
59  void cursor_left();
60  void cursor_up();
61  void cursor_down();
62 };
63 
64 } // End of namespace Nuvie
65 } // End of namespace Ultima
66 
67 #endif
Definition: actor.h:178
Definition: configuration.h:61
Definition: container_widget_gump.h:37
Definition: tile_manager.h:145
Definition: detection.h:27
Definition: obj_manager.h:75
Definition: keyboard.h:294
Definition: container_widget.h:40
Definition: tile_manager.h:113
Definition: font.h:42
Definition: gui_callback.h:31