mirror of
https://github.com/OpenMW/openmw.git
synced 2025-02-21 09:39:43 +00:00
Appease the evil spirits of C++
This commit is contained in:
parent
68d185ad4d
commit
fcb820f1f7
4 changed files with 24 additions and 38 deletions
|
@ -12,10 +12,7 @@
|
|||
|
||||
#include "windowbase.hpp"
|
||||
|
||||
namespace MWMechanics
|
||||
{
|
||||
class Alchemy;
|
||||
}
|
||||
#include "../mwmechanics/alchemy.hpp"
|
||||
|
||||
namespace MWGui
|
||||
{
|
||||
|
|
|
@ -32,31 +32,15 @@
|
|||
|
||||
namespace MWGui
|
||||
{
|
||||
|
||||
class ResponseCallback : public MWBase::DialogueManager::ResponseCallback
|
||||
void ResponseCallback::addResponse(const std::string& title, const std::string& text)
|
||||
{
|
||||
public:
|
||||
ResponseCallback(DialogueWindow* win, bool needMargin=true)
|
||||
: mWindow(win)
|
||||
, mNeedMargin(needMargin)
|
||||
{
|
||||
mWindow->addResponse(title, text, mNeedMargin);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void addResponse(const std::string& title, const std::string& text) override
|
||||
{
|
||||
mWindow->addResponse(title, text, mNeedMargin);
|
||||
}
|
||||
|
||||
void updateTopics()
|
||||
{
|
||||
mWindow->updateTopics();
|
||||
}
|
||||
|
||||
private:
|
||||
DialogueWindow* mWindow;
|
||||
bool mNeedMargin;
|
||||
};
|
||||
void ResponseCallback::updateTopics() const
|
||||
{
|
||||
mWindow->updateTopics();
|
||||
}
|
||||
|
||||
PersuasionDialog::PersuasionDialog(std::unique_ptr<ResponseCallback> callback)
|
||||
: WindowModal("openmw_persuasion_dialog.layout")
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
|
||||
#include "bookpage.hpp"
|
||||
|
||||
#include "../mwbase/dialoguemanager.hpp"
|
||||
#include "../mwdialogue/keywordsearch.hpp"
|
||||
|
||||
#include <MyGUI_Delegate.h>
|
||||
|
@ -20,7 +21,21 @@ namespace Gui
|
|||
|
||||
namespace MWGui
|
||||
{
|
||||
class ResponseCallback;
|
||||
class DialogueWindow;
|
||||
|
||||
class ResponseCallback : public MWBase::DialogueManager::ResponseCallback
|
||||
{
|
||||
DialogueWindow* mWindow;
|
||||
bool mNeedMargin;
|
||||
|
||||
public:
|
||||
ResponseCallback(DialogueWindow* win, bool needMargin = true) : mWindow(win), mNeedMargin(needMargin)
|
||||
{}
|
||||
|
||||
void addResponse(const std::string& title, const std::string& text) override;
|
||||
|
||||
void updateTopics() const;
|
||||
};
|
||||
|
||||
class PersuasionDialog : public WindowModal
|
||||
{
|
||||
|
|
|
@ -13,7 +13,6 @@
|
|||
#include <MyGUI_LanguageManager.h>
|
||||
#include <MyGUI_PointerManager.h>
|
||||
#include <MyGUI_InputManager.h>
|
||||
#include <MyGUI_Gui.h>
|
||||
#include <MyGUI_ClipboardManager.h>
|
||||
|
||||
// For BT_NO_PROFILE
|
||||
|
@ -24,9 +23,6 @@
|
|||
|
||||
#include <components/debug/debuglog.hpp>
|
||||
|
||||
#include <components/sdlutil/sdlcursormanager.hpp>
|
||||
#include <components/sdlutil/sdlvideowrapper.hpp>
|
||||
|
||||
#include <components/esm3/esmreader.hpp>
|
||||
#include <components/esm3/esmwriter.hpp>
|
||||
|
||||
|
@ -71,17 +67,13 @@
|
|||
#include "../mwmechanics/npcstats.hpp"
|
||||
#include "../mwmechanics/actorutil.hpp"
|
||||
|
||||
#include "../mwrender/localmap.hpp"
|
||||
#include "../mwrender/postprocessor.hpp"
|
||||
|
||||
#include "console.hpp"
|
||||
#include "journalwindow.hpp"
|
||||
#include "journalviewmodel.hpp"
|
||||
#include "charactercreation.hpp"
|
||||
#include "dialogue.hpp"
|
||||
#include "statswindow.hpp"
|
||||
#include "messagebox.hpp"
|
||||
#include "tooltips.hpp"
|
||||
#include "scrollwindow.hpp"
|
||||
#include "bookwindow.hpp"
|
||||
#include "hud.hpp"
|
||||
|
@ -105,7 +97,6 @@
|
|||
#include "cursor.hpp"
|
||||
#include "merchantrepair.hpp"
|
||||
#include "repair.hpp"
|
||||
#include "soulgemdialog.hpp"
|
||||
#include "companionwindow.hpp"
|
||||
#include "inventorywindow.hpp"
|
||||
#include "bookpage.hpp"
|
||||
|
@ -117,7 +108,6 @@
|
|||
#include "debugwindow.hpp"
|
||||
#include "postprocessorhud.hpp"
|
||||
#include "spellview.hpp"
|
||||
#include "draganddrop.hpp"
|
||||
#include "container.hpp"
|
||||
#include "controllers.hpp"
|
||||
#include "jailscreen.hpp"
|
||||
|
|
Loading…
Reference in a new issue