MCPcopy Create free account
hub / github.com/OpenRCT2/OpenRCT2 / tabIndex_set

Method tabIndex_set

src/openrct2-ui/scripting/ScWindow.cpp:323–333  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

321 return JS_NewInt32(ctx, 0);
322 }
323 JSValue ScWindow::tabIndex_set(JSContext* ctx, JSValue thisVal, JSValue tab)
324 {
325 JS_UNPACK_INT32(tabNumber, ctx, tab);
326
327 auto w = GetWindow(thisVal);
328 if (w != nullptr && w->classification == WindowClass::custom)
329 {
330 UpdateWindowTab(w, tabNumber);
331 }
332 return JS_UNDEFINED;
333 }
334
335 JSValue ScWindow::close(JSContext* ctx, JSValue thisVal, int argc, JSValue* argv)
336 {

Callers

nothing calls this directly

Calls 2

GetWindowFunction · 0.85
UpdateWindowTabFunction · 0.85

Tested by

no test coverage detected