API:ButtonGetDisabledFlag
From RoR Wiki
UI Lua API · Button functions
Version: WAR 1.4.8
Returns whether a Button is disabled.
disabled = ButtonGetDisabledFlag(buttonName)
Arguments
- buttonName
string– Name of a Button window.
Returns
- disabled
boolean–trueif the button is disabled.
Details
- The flag is set with ButtonSetDisabledFlag.
- A disabled button is drawn in its disabled state, and clicks on it do not change its pressed flag.
Errors
Error in function call 'ButtonGetDisabledFlag': Window %s does not existError in function call 'ButtonGetDisabledFlag': Window %s is not a Button
Example
Ignoring clicks on a disabled button, from ea_backpackwindow/source/backpacklistview.lua:
if ButtonGetDisabledFlag( SystemData.ActiveWindow.name.."Button" ) then
return
end
