Enable the help system in the map editor.
This commit is contained in:
parent
c59da51bac
commit
4a559b6b94
2 changed files with 18 additions and 7 deletions
|
@ -61,16 +61,18 @@ editor_controller::editor_controller(const config &game_config, CVideo& video)
|
|||
, teams_()
|
||||
, tods_()
|
||||
, context_manager_(new context_manager(*gui_.get(), game_config_))
|
||||
, toolkit_()
|
||||
, toolkit_(NULL)
|
||||
, prefs_disp_manager_(NULL)
|
||||
, tooltip_manager_(video)
|
||||
, floating_label_manager_(NULL)
|
||||
, halo_manager_(NULL)
|
||||
, help_manager_(NULL)
|
||||
, do_quit_(false)
|
||||
, quit_mode_(EXIT_ERROR)
|
||||
{
|
||||
init_gui();
|
||||
toolkit_.reset(new editor_toolkit(*gui_.get(), key_, game_config_, *context_manager_.get()));
|
||||
help_manager_.reset(new help::help_manager(&game_config, &(context_manager_->get_map_context().get_map())));
|
||||
context_manager_->switch_context(0);
|
||||
init_tods(game_config);
|
||||
init_music(game_config);
|
||||
|
@ -656,6 +658,12 @@ bool editor_controller::execute_command(hotkey::HOTKEY_COMMAND command, int inde
|
|||
}
|
||||
}
|
||||
|
||||
void editor_controller::show_help()
|
||||
{
|
||||
help::show_help(*gui_);
|
||||
//menu_handler_.show_help();
|
||||
}
|
||||
|
||||
void editor_controller::show_menu(const std::vector<std::string>& items_arg, int xloc, int yloc, bool context_menu)
|
||||
{
|
||||
if (context_menu) {
|
||||
|
|
|
@ -15,18 +15,18 @@
|
|||
#ifndef EDITOR_EDITOR_CONTROLLER_HPP_INCLUDED
|
||||
#define EDITOR_EDITOR_CONTROLLER_HPP_INCLUDED
|
||||
|
||||
#include "editor_display.hpp"
|
||||
#include "editor_main.hpp"
|
||||
#include "map/map_context.hpp"
|
||||
#include "map/map_fragment.hpp"
|
||||
|
||||
#include "editor/editor_display.hpp"
|
||||
#include "editor/editor_main.hpp"
|
||||
#include "editor/map/context_manager.hpp"
|
||||
#include "editor/map/map_context.hpp"
|
||||
#include "editor/map/map_fragment.hpp"
|
||||
#include "editor/toolkit/editor_toolkit.hpp"
|
||||
|
||||
#include "../controller_base.hpp"
|
||||
#include "../help.hpp"
|
||||
#include "../mouse_handler_base.hpp"
|
||||
#include "../tooltips.hpp"
|
||||
|
||||
#include "editor/map/context_manager.hpp"
|
||||
|
||||
class map_generator;
|
||||
|
||||
|
@ -114,6 +114,8 @@ class editor_controller : public controller_base,
|
|||
/** controller_base override */
|
||||
void show_menu(const std::vector<std::string>& items_arg, int xloc, int yloc, bool context_menu);
|
||||
|
||||
void show_help();
|
||||
|
||||
/** Show the preferences dialog */
|
||||
void preferences();
|
||||
|
||||
|
@ -233,6 +235,7 @@ class editor_controller : public controller_base,
|
|||
boost::scoped_ptr<font::floating_label_context> floating_label_manager_;
|
||||
|
||||
boost::scoped_ptr<halo::manager> halo_manager_;
|
||||
boost::scoped_ptr<help::help_manager> help_manager_;
|
||||
|
||||
/** Quit main loop flag */
|
||||
bool do_quit_;
|
||||
|
|
Loading…
Add table
Reference in a new issue