forked from mirror/openmw-tes3mp
[Client] Fix build after recent OpenMW changes to GUI
This commit is contained in:
parent
3e8d7c8416
commit
711c4d83da
11 changed files with 21 additions and 22 deletions
|
@ -105,7 +105,7 @@ namespace MWBase
|
||||||
|
|
||||||
Declare this method here so it can be used from outside of MWDialogue::DialogueManager
|
Declare this method here so it can be used from outside of MWDialogue::DialogueManager
|
||||||
*/
|
*/
|
||||||
virtual void updateTopics() = 0;
|
virtual void updateActorKnownTopics() = 0;
|
||||||
/*
|
/*
|
||||||
End of tes3mp addition
|
End of tes3mp addition
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -226,7 +226,7 @@ namespace MWGui
|
||||||
|
|
||||||
Mark this container as open for multiplayer logic purposes
|
Mark this container as open for multiplayer logic purposes
|
||||||
*/
|
*/
|
||||||
mwmp::Main::get().getCellController()->openContainer(container, loot);
|
mwmp::Main::get().getCellController()->openContainer(container);
|
||||||
/*
|
/*
|
||||||
End of tes3mp addition
|
End of tes3mp addition
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -338,14 +338,14 @@ bool CellController::isSameCell(const ESM::Cell& cell, const ESM::Cell& otherCel
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void CellController::openContainer(const MWWorld::Ptr &container, bool loot)
|
void CellController::openContainer(const MWWorld::Ptr &container)
|
||||||
{
|
{
|
||||||
// Record this as the player's current open container
|
// Record this as the player's current open container
|
||||||
Main::get().getLocalPlayer()->storeCurrentContainer(container, loot);
|
Main::get().getLocalPlayer()->storeCurrentContainer(container);
|
||||||
|
|
||||||
const auto &cellRef = container.getCellRef();
|
const auto &cellRef = container.getCellRef();
|
||||||
LOG_MESSAGE_SIMPLE(Log::LOG_VERBOSE, "Container \"%s\" (%d) is opened. Loot: %s",
|
LOG_MESSAGE_SIMPLE(Log::LOG_VERBOSE, "Container \"%s\" (%d) is opened",
|
||||||
cellRef.getRefId().c_str(), cellRef.getRefNum().mIndex, loot ? "true" : "false");
|
cellRef.getRefId().c_str(), cellRef.getRefNum().mIndex);
|
||||||
|
|
||||||
for (const auto &ptr : container.getClass().getContainerStore(container))
|
for (const auto &ptr : container.getClass().getContainerStore(container))
|
||||||
{
|
{
|
||||||
|
|
|
@ -59,7 +59,7 @@ namespace mwmp
|
||||||
|
|
||||||
bool isSameCell(const ESM::Cell& cell, const ESM::Cell& otherCell);
|
bool isSameCell(const ESM::Cell& cell, const ESM::Cell& otherCell);
|
||||||
|
|
||||||
void openContainer(const MWWorld::Ptr& container, bool loot);
|
void openContainer(const MWWorld::Ptr& container);
|
||||||
void closeContainer(const MWWorld::Ptr& container);
|
void closeContainer(const MWWorld::Ptr& container);
|
||||||
|
|
||||||
int getCellSize() const;
|
int getCellSize() const;
|
||||||
|
|
|
@ -46,7 +46,7 @@ namespace mwmp
|
||||||
delay = 3; // 3 sec.
|
delay = 3; // 3 sec.
|
||||||
}
|
}
|
||||||
|
|
||||||
void GUIChat::open()
|
void GUIChat::onOpen()
|
||||||
{
|
{
|
||||||
// Give keyboard focus to the combo box whenever the console is
|
// Give keyboard focus to the combo box whenever the console is
|
||||||
// turned on
|
// turned on
|
||||||
|
@ -54,7 +54,7 @@ namespace mwmp
|
||||||
windowState = CHAT_ENABLED;
|
windowState = CHAT_ENABLED;
|
||||||
}
|
}
|
||||||
|
|
||||||
void GUIChat::close()
|
void GUIChat::onClose()
|
||||||
{
|
{
|
||||||
// Apparently, hidden widgets can retain key focus
|
// Apparently, hidden widgets can retain key focus
|
||||||
// Remove for MyGUI 3.2.2
|
// Remove for MyGUI 3.2.2
|
||||||
|
@ -62,9 +62,10 @@ namespace mwmp
|
||||||
SetEditState(0);
|
SetEditState(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
void GUIChat::exit()
|
bool GUIChat::exit()
|
||||||
{
|
{
|
||||||
//WindowBase::exit();
|
//WindowBase::exit();
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void GUIChat::acceptCommand(MyGUI::EditBox *_sender)
|
void GUIChat::acceptCommand(MyGUI::EditBox *_sender)
|
||||||
|
|
|
@ -43,11 +43,10 @@ namespace mwmp
|
||||||
|
|
||||||
void Update(float dt);
|
void Update(float dt);
|
||||||
|
|
||||||
|
virtual void onOpen();
|
||||||
|
virtual void onClose();
|
||||||
|
|
||||||
virtual void open();
|
virtual bool exit();
|
||||||
virtual void close();
|
|
||||||
|
|
||||||
virtual void exit();
|
|
||||||
|
|
||||||
void setFont(const std::string &fntName);
|
void setFont(const std::string &fntName);
|
||||||
|
|
||||||
|
|
|
@ -55,9 +55,9 @@ namespace mwmp
|
||||||
setText("TextNote", note);
|
setText("TextNote", note);
|
||||||
}
|
}
|
||||||
|
|
||||||
void TextInputDialog::open()
|
void TextInputDialog::onOpen()
|
||||||
{
|
{
|
||||||
WindowModal::open();
|
WindowModal::onOpen();
|
||||||
// Make sure the edit box has focus
|
// Make sure the edit box has focus
|
||||||
MWBase::Environment::get().getWindowManager()->setKeyFocusWidget(mTextEdit);
|
MWBase::Environment::get().getWindowManager()->setKeyFocusWidget(mTextEdit);
|
||||||
}
|
}
|
||||||
|
|
|
@ -29,7 +29,7 @@ namespace mwmp
|
||||||
|
|
||||||
void setEditPassword(bool value);
|
void setEditPassword(bool value);
|
||||||
|
|
||||||
virtual void open();
|
virtual void onOpen();
|
||||||
|
|
||||||
/** Event : Dialog finished, OK button clicked.\n
|
/** Event : Dialog finished, OK button clicked.\n
|
||||||
signature : void method()\n
|
signature : void method()\n
|
||||||
|
|
|
@ -719,7 +719,7 @@ void LocalPlayer::addTopics()
|
||||||
env.getDialogueManager()->addTopic(topicId);
|
env.getDialogueManager()->addTopic(topicId);
|
||||||
|
|
||||||
if (env.getWindowManager()->containsMode(MWGui::GM_Dialogue))
|
if (env.getWindowManager()->containsMode(MWGui::GM_Dialogue))
|
||||||
env.getDialogueManager()->updateTopics();
|
env.getDialogueManager()->updateActorKnownTopics();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1369,10 +1369,9 @@ void LocalPlayer::storeCellState(ESM::Cell cell, int stateType)
|
||||||
cellStateChanges.cellStates.push_back(cellState);
|
cellStateChanges.cellStates.push_back(cellState);
|
||||||
}
|
}
|
||||||
|
|
||||||
void LocalPlayer::storeCurrentContainer(const MWWorld::Ptr &container, bool loot)
|
void LocalPlayer::storeCurrentContainer(const MWWorld::Ptr &container)
|
||||||
{
|
{
|
||||||
currentContainer.refId = container.getCellRef().getRefId();
|
currentContainer.refId = container.getCellRef().getRefId();
|
||||||
currentContainer.refNumIndex = container.getCellRef().getRefNum().mIndex;
|
currentContainer.refNumIndex = container.getCellRef().getRefNum().mIndex;
|
||||||
currentContainer.mpNum = container.getCellRef().getMpNum();
|
currentContainer.mpNum = container.getCellRef().getMpNum();
|
||||||
currentContainer.loot = loot;
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -86,7 +86,7 @@ namespace mwmp
|
||||||
void clearCurrentContainer();
|
void clearCurrentContainer();
|
||||||
|
|
||||||
void storeCellState(ESM::Cell cell, int stateType);
|
void storeCellState(ESM::Cell cell, int stateType);
|
||||||
void storeCurrentContainer(const MWWorld::Ptr& container, bool loot);
|
void storeCurrentContainer(const MWWorld::Ptr& container);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
Networking *getNetworking();
|
Networking *getNetworking();
|
||||||
|
|
|
@ -142,7 +142,7 @@ void WorldEvent::editContainers(MWWorld::CellStore* cellStore)
|
||||||
currentContainer->mpNum == ptrFound.getCellRef().getMpNum())
|
currentContainer->mpNum == ptrFound.getCellRef().getMpNum())
|
||||||
{
|
{
|
||||||
MWBase::Environment::get().getWindowManager()->removeGuiMode(MWGui::GM_Container);
|
MWBase::Environment::get().getWindowManager()->removeGuiMode(MWGui::GM_Container);
|
||||||
MWBase::Environment::get().getWindowManager()->openContainer(ptrFound, currentContainer->loot);
|
MWBase::Environment::get().getWindowManager()->pushGuiMode(MWGui::GM_Container, ptrFound);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue