Fix a message box issue

pull/16/head
scrawl 12 years ago
parent b16c92c2f5
commit 4fd7891d2c

@ -18,7 +18,6 @@ namespace MWGui
ToolTips::ToolTips() :
Layout("openmw_tooltips.layout")
, mGameMode(true)
, mFullHelp(false)
, mEnabled(true)
, mFocusToolTipX(0.0)
@ -73,7 +72,9 @@ namespace MWGui
return;
}
if (!mGameMode)
bool gameMode = MWBase::Environment::get().getWindowManager()->isGuiMode();
if (gameMode)
{
const MyGUI::IntPoint& mousePos = MyGUI::InputManager::getInstance().getMousePosition();
@ -297,16 +298,6 @@ namespace MWGui
}
}
void ToolTips::enterGameMode()
{
mGameMode = true;
}
void ToolTips::enterGuiMode()
{
mGameMode = false;
}
void ToolTips::setFocusObject(const MWWorld::Ptr& focus)
{
mFocusObject = focus;

@ -43,9 +43,6 @@ namespace MWGui
void onFrame(float frameDuration);
void enterGameMode();
void enterGuiMode();
void setEnabled(bool enabled);
void toggleFullHelp(); ///< show extra info in item tooltips (owner, script)
@ -104,8 +101,6 @@ namespace MWGui
int mLastMouseX;
int mLastMouseY;
bool mGameMode;
bool mEnabled;
bool mFullHelp;

@ -356,11 +356,6 @@ namespace MWGui
mInputBlocker->setVisible (gameMode);
setCursorVisible(!gameMode);
if (gameMode)
mToolTips->enterGameMode();
else
mToolTips->enterGuiMode();
if (gameMode)
setKeyFocusWidget (NULL);

@ -408,6 +408,7 @@ namespace MWInput
mMouseLookEnabled = !guiMode;
if (guiMode)
mWindows.showCrosshair(false);
mWindows.setCursorVisible(guiMode);
// if not in gui mode, the camera decides whether to show crosshair or not.
}
@ -470,7 +471,6 @@ namespace MWInput
bool InputManager::keyPressed( const SDL_KeyboardEvent &arg )
{
mInputBinder->keyPressed (arg);
unsigned int text = arg.keysym.unicode;
if(arg.keysym.sym == SDLK_RETURN
&& MWBase::Environment::get().getWindowManager()->isGuiMode())

Loading…
Cancel
Save