#include "server.h"
#include "guiPasswordChange.h"
#include "guiVolumeChange.h"
+#include "guiKeyChangeMenu.h"
#include "guiFormSpecMenu.h"
#include "tool.h"
#include "guiChatConsole.h"
return;
}
+ if (fields.find("btn_key_config") != fields.end()) {
+ g_gamecallback->keyConfig();
+ return;
+ }
+
if (fields.find("btn_exit_menu") != fields.end()) {
g_gamecallback->disconnect();
return;
os << "button_exit[4," << (ypos++) << ";3,0.5;btn_sound;"
<< wide_to_narrow(wstrgettext("Sound Volume")) << "]";
+ os << "button_exit[4," << (ypos++) << ";3,0.5;btn_key_config;"
+ << wide_to_narrow(wstrgettext("Change Keys")) << "]";
os << "button_exit[4," << (ypos++) << ";3,0.5;btn_exit_menu;"
<< wide_to_narrow(wstrgettext("Exit to Menu")) << "]";
os << "button_exit[4," << (ypos++) << ";3,0.5;btn_exit_os;"
g_gamecallback->changevolume_requested = false;
}
+ if(g_gamecallback->keyconfig_requested)
+ {
+ (new GUIKeyChangeMenu(guienv, guiroot, -1,
+ &g_menumgr))->drop();
+ g_gamecallback->keyconfig_requested = false;
+ }
+
+
/* Process TextureSource's queue */
tsrc->processQueue();
{
public:
virtual void exitToOS() = 0;
+ virtual void keyConfig() = 0;
virtual void disconnect() = 0;
virtual void changePassword() = 0;
virtual void changeVolume() = 0;
disconnect_requested(false),
changepassword_requested(false),
changevolume_requested(false),
+ keyconfig_requested(false),
shutdown_requested(false),
device(a_device)
{
{
changevolume_requested = true;
}
+
+ virtual void keyConfig()
+ {
+ keyconfig_requested = true;
+ }
+
bool disconnect_requested;
bool changepassword_requested;
bool changevolume_requested;
+ bool keyconfig_requested;
bool shutdown_requested;
IrrlichtDevice *device;
};