API:ComboBoxSetDisabledFlag
From RoR Wiki
UI Lua API · ComboBox functions
Version: WAR 1.4.8
Enables or disables a ComboBox.
ComboBoxSetDisabledFlag(comboBoxName, disabled)
Arguments
- comboBoxName
string– Name of the ComboBox.- disabled
boolean–trueto disable the ComboBox,falseto enable it.
Returns
Nothing.
Details
- The flag is also applied to the ComboBox's selected-item button and to every menu item button.
- A disabled ComboBox does not open its menu, also not through ComboBoxExternalOpenMenu.
- A menu that is already open is not closed by this call.
disabledmust be a real boolean. Passingnilor a number raises an Invalid Parameters error.- The function needs at least two arguments and only reads the last two. Any extra arguments placed in front of them are ignored.
Errors
Error in function call 'ComboBoxSetDisabledFlag': Window %s does not existError in function call 'ComboBoxSetDisabledFlag': Window %s is not a ComboBox
Example
From default/ea_openpartywindow/source/openpartywindowtabmanage.lua:
ComboBoxSetDisabledFlag( PARENT_WINDOW.."LootModeCombo", GameData.Player.isGroupLeader == false )
