Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/branches/presentation2/data/gui/scripts/InfoPopup.lua @ 6292

Last change on this file since 6292 was 6283, checked in by dafrick, 15 years ago

Some enhancements in KeyBindMenu.lua and InfoPopup, clear doesn't work, yet.

File size: 796 bytes
Line 
1-- InfoPopup.lua
2
3BasicGUI = require("BasicGUI")
4local P = BasicGUI:new() --inherit everything from the gui package
5if _REQUIREDNAME == nil then
6    InfoPopup = P
7else
8    _G[_REQUIREDNAME] = P
9end
10
11P.filename = "InfoPopup"
12P.layoutString = "InfoPopup.layout"
13
14function P:init()
15end
16
17function P.execute(functionPtr)
18    if functionPtr ~= nil then
19        functionPtr()
20    end
21end
22
23function P.setText( text )
24    winMgr:getWindow("orxonox/InfoPopup_text"):setText( text )
25end
26
27function P.setCloseButton(closeButton)
28    close = winMgr:getWindow("orxonox/InfoPopup_close")
29    close:setVisible(closeButton)
30    if(not closeButton) then
31        close:deactivate();
32    else
33        close:activate();
34    end
35end
36
37-- events for ingamemenu
38function P.close(e)
39    hideGUI("InfoPopup")
40end
41
42return P
43
Note: See TracBrowser for help on using the repository browser.