ScummVM API documentation
unknown-game-dialog.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 GUI_UNKNOWN_GAME_DIALOG_H
23 #define GUI_UNKNOWN_GAME_DIALOG_H
24 
25 #include "gui/dialog.h"
26 #include "common/array.h"
27 #include "engines/game.h"
28 
29 namespace GUI {
30 
31 class StaticTextWidget;
32 class ScrollContainerWidget;
33 class ButtonWidget;
34 
35 class UnknownGameDialog : public Dialog {
36 public:
37  UnknownGameDialog(const DetectedGame &detectedGame);
38 
39  void handleMouseWheel(int x, int y, int direction) override;
40 private:
41  void rebuild();
42 
43  // Dialog API
44  void handleCommand(GUI::CommandSender *sender, uint32 cmd, uint32 data) override;
45  void reflowLayout() override;
46 
47  Common::String generateBugtrackerURL();
48  static Common::String encodeUrlString(const Common::String &string);
49 
50  const DetectedGame &_detectedGame;
51  ScrollContainerWidget *_textContainer;
53  ButtonWidget *_openBugTrackerUrlButton;
54  ButtonWidget *_copyToClipboardButton;
55  ButtonWidget *_closeButton;
56  ButtonWidget *_addAnywayButton;
57 };
58 
59 } // End of namespace GUI
60 
61 #endif
Definition: str.h:59
Definition: game.h:147
Definition: array.h:52
Definition: scrollcontainer.h:31
Definition: system.h:46
Definition: dialog.h:49
Definition: unknown-game-dialog.h:35
Definition: widget.h:233
Definition: object.h:40