1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-16 06:49:55 +00:00
openmw-tes3mp/apps/openmw/mwmp/GUIController.hpp

69 lines
1.9 KiB
C++
Raw Normal View History

//
// Created by koncord on 20.07.16.
//
#ifndef OPENMW_GUICONTROLLER_HPP
#define OPENMW_GUICONTROLLER_HPP
#include <components/settings/settings.hpp>
#include <apps/openmw/mwgui/textinput.hpp>
#include <apps/openmw/mwgui/mode.hpp>
#include <components/openmw-mp/Base/BasePlayer.hpp>
#include "GUIChat.hpp"
2016-10-07 05:17:19 +00:00
#include "PlayerMarkerCollection.hpp"
namespace MWGui
{
class LocalMapBase;
class MapWindow;
}
namespace mwmp
{
class GUIController
{
public:
GUIController();
~GUIController();
2016-10-01 02:54:42 +00:00
void cleanup();
void setupChat(const Settings::Manager &manager);
void PrintChatMessage(std::string &msg);
void setChatVisible(bool chatVisible);
void ShowMessageBox(const BasePlayer::GUIMessageBox &guiMessageBox);
void ShowCustomMessageBox(const BasePlayer::GUIMessageBox &guiMessageBox);
void ShowInputBox(const BasePlayer::GUIMessageBox &guiMessageBox);
/// Return true if any tes3mp gui element in active state
bool HaveFocusedElement();
/// Returns 0 if there was no events
bool pressedKey(int key);
void update(float dt);
void WM_UpdateVisible(MWGui::GuiMode mode);
2016-10-07 05:17:19 +00:00
void updatePlayersMarkers(MWGui::LocalMapBase *localMapBase);
void updateGlobalMapMarkerTooltips(MWGui::MapWindow *pWindow);
2016-10-22 09:06:26 +00:00
ESM::CustomMarker CreateMarker(const RakNet::RakNetGUID &guid);
2016-10-07 05:17:19 +00:00
PlayerMarkerCollection mPlayerMarkers;
private:
void setGlobalMapMarkerTooltip(MWGui::MapWindow *mapWindow ,MyGUI::Widget* markerWidget, int x, int y);
private:
GUIChat *mChat;
int keySay;
int keyChatMode;
long id;
bool calledMessageBox;
MWGui::TextInputDialog *mInputBox;
void OnInputBoxDone(MWGui::WindowBase* parWindow);
//MyGUI::Widget *oldFocusWidget, *currentFocusWidget;
};
}
#endif //OPENMW_GUICONTROLLER_HPP