API:WindowSetId
From RoR Wiki
UI Lua API · Window functions
Version: WAR 1.4.8
Stores a number on a window as its id.
WindowSetId(windowName, id)
Arguments
- windowName
string– Name of the window.- id
number– The id to store.
Returns
Nothing.
Details
- The id is a free number for the UI's own use; the client only stores it. Read it back with WindowGetId.
idis truncated towards zero to a whole number.- There is no lock check in this function.
- The function needs at least two arguments and only reads the last two.
Errors
Error in function call 'WindowSetId': Window %s does not exist
Example
From easystem_dialogmanager/source/dialogmanager.lua:
local warningButton = "TwoButtonDlg"..dlg.."BoxNeverWarnButton"; -- ... WindowSetId (warningButton, dlg + DialogManager.NEVER_WARN_ID_OFFSET);
