ScummVM API documentation
dialogs_manager.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 CRYOMNI3D_VERSAILLES_DIALOGS_MANAGER_H
23 #define CRYOMNI3D_VERSAILLES_DIALOGS_MANAGER_H
24 
25 #include "common/hashmap.h"
26 #include "common/hash-str.h"
27 #include "graphics/managed_surface.h"
28 
29 #include "cryomni3d/dialogs_manager.h"
30 #include "cryomni3d/font_manager.h"
31 
32 namespace CryOmni3D {
33 namespace Versailles {
34 
35 class CryOmni3DEngine_Versailles;
36 typedef void (CryOmni3DEngine_Versailles::*ShowCallback)();
37 
39 public:
40  Versailles_DialogsManager(CryOmni3DEngine_Versailles *engine, bool padAudioFileName);
41 
42  // This overload will hide the base one and this is what we want
43  bool play(const Common::String &sequence);
44 
45  void registerShowCallback(const Common::String &showName, ShowCallback callback) { _shows[showName] = callback; }
46 
47 protected:
48  void executeShow(const Common::String &show) override;
49  void playDialog(const Common::String &video, const Common::String &sound,
50  const Common::String &text, const SubtitlesSettings &settings) override;
51  void displayMessage(const Common::String &text) override;
52  uint askPlayerQuestions(const Common::String &video,
53  const Common::StringArray &questions) override;
54 
55 private:
58  bool _padAudioFileName;
59 
60  void loadFrame(const Common::String &video);
61 
62  Graphics::ManagedSurface _lastImage;
63 };
64 
65 } // End of namespace Versailles
66 } // End of namespace CryOmni3D
67 
68 #endif
Definition: managed_surface.h:51
Definition: dialogs_manager.h:38
Definition: cryomni3d.h:62
Definition: str.h:59
Definition: dialogs_manager.h:36
Definition: dialogs_manager.h:34