Changeset 7689 for code/trunk/data/gui/scripts/SettingsMenu.lua
- Timestamp:
- Dec 1, 2010, 3:00:19 PM (14 years ago)
- Location:
- code/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk
- Property svn:mergeinfo changed
/code/branches/menu merged: 7587-7588,7594,7607-7608,7649,7663,7670-7671,7687
- Property svn:mergeinfo changed
-
code/trunk/data/gui/scripts/SettingsMenu.lua
r7163 r7689 3 3 local P = createMenuSheet("SettingsMenu") 4 4 P.loadAlong = { "ControlsMenu", "AudioMenu", "GraphicsMenu" } 5 6 P.buttonList = {} 7 8 function P.onLoad() 9 --"Gameplay" and "Multiplayer Options" are not integrated in the list 10 --buttons are arranged in a 4x2 matrix. The lower-right element is not in the matrix! 11 local item = { 12 ["button"] = winMgr:getWindow("orxonox/SettingsMenu/GraphicsButton"), 13 ["function"] = P.SettingsGraphicsButton_clicked 14 } 15 P.buttonList[2] = item 16 17 local item = { 18 ["button"] = winMgr:getWindow("orxonox/SettingsMenu/AudioButton"), 19 ["function"] = P.SettingsAudioButton_clicked 20 } 21 P.buttonList[4] = item 22 23 24 local item = { 25 ["button"] = winMgr:getWindow("orxonox/SettingsMenu/ControlsButton"), 26 ["function"] = P.SettingsControlsButton_clicked 27 } 28 P.buttonList[5] = item 29 30 local item = { 31 ["button"] = winMgr:getWindow("orxonox/SettingsMenu/MiscellaneousButton"), 32 ["function"] = P.SettingsMiscellaneousButton_clicked 33 } 34 P.buttonList[6] = item 35 36 local item = { 37 ["button"] = winMgr:getWindow("orxonox/SettingsMenu/SettingsBackButton"), 38 ["function"] = P.SettingsBackButton_clicked 39 } 40 P.buttonList[7] = item 41 42 end 43 44 function P.onShow() 45 --indices to iterate through buttonlist 46 P.oldindex = 3 47 P.index = 2 48 end 5 49 6 50 function P.SettingsGameplayButton_clicked(e) … … 32 76 end 33 77 78 function P.onKeyPressed() 79 buttonIteratorHelper(P.buttonList, code, P, 4, 2) 80 end 81 34 82 return P 35 83
Note: See TracChangeset
for help on using the changeset viewer.