Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8484


Ignore:
Timestamp:
May 14, 2011, 5:30:26 PM (14 years ago)
Author:
dafrick
Message:

Turns out my pervious fix actually induced a bug, this fix should take care of both problems.

Location:
code/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/data/gui/scripts/SheetManager.lua

    r8482 r8484  
    55local activeMenuSheets = {size = 0, topSheetTuple = nil}
    66local menuSheetsRoot = guiMgr:getMenuRootWindow()
     7local bInGameConsoleClosed = false
    78local mainMenuLoaded = false
    89orxonox.GUIManager:subscribeEventHelper(menuSheetsRoot, "KeyDown", "keyPressed")
     
    218219    -- Count the number of sheets that don't need input till the first that does.
    219220    local counter = noInputSheetIndex()
     221   
     222    -- If the InGameConsole is active, ignore the ESC command.
     223    if bInGameConsoleClosed == true then
     224        bInGameConsoleClosed = false
     225        if counter > 0 then
     226            return
     227        end
     228    end
    220229
    221230    -- If the first sheet that needs input is the MainMenu.
     
    288297end
    289298
     299function inGameConsoleClosed()
     300    bInGameConsoleClosed = not bInGameConsoleClosed;
     301end
     302
    290303function getGUIFirstActive(name, bHidePrevious, bNoInput)
    291304    local sheet = activeMenuSheets.topSheetTuple
  • code/trunk/src/orxonox/overlays/InGameConsole.cc

    r8482 r8484  
    534534        {
    535535            this->bActive_ = false;
     536            GUIManager::getInstance().getLuaState()->doString("inGameConsoleClosed()"); // Notify the SheetManager in lua, that the console has been closed.
    536537            InputManager::getInstance().leaveState("console");
    537538            this->shell_->unregisterListener(this);
Note: See TracChangeset for help on using the changeset viewer.