60 lines
1.5 KiB
C++
60 lines
1.5 KiB
C++
|
/* This file was generated by Maki Compiler, do not edit manually */
|
||
|
|
||
|
#include <precomp.h>
|
||
|
#include <api/api.h>
|
||
|
#include "c_tabsheet.h"
|
||
|
#include <api/script/objcontroller.h>
|
||
|
|
||
|
C_TabSheet::C_TabSheet(ScriptObject *object) : C_GuiObject(object) {
|
||
|
inited = 0;
|
||
|
obj = NULL;
|
||
|
C_hook(object);
|
||
|
}
|
||
|
|
||
|
C_TabSheet::C_TabSheet() {
|
||
|
inited = 0;
|
||
|
obj = NULL;
|
||
|
}
|
||
|
|
||
|
void C_TabSheet::C_hook(ScriptObject *object) {
|
||
|
ASSERT(!inited);
|
||
|
ScriptObjectController *controller = object->vcpu_getController();
|
||
|
obj = controller->cast(object, tabSheetGuid);
|
||
|
if (obj != object && obj != NULL)
|
||
|
controller = obj->vcpu_getController();
|
||
|
else
|
||
|
obj = NULL;
|
||
|
|
||
|
int iter = WASABI_API_APP->app_getInitCount();
|
||
|
if (!loaded || loaded != iter) {
|
||
|
loaded = iter;
|
||
|
getcurpage_id = WASABI_API_MAKI->maki_addDlfRef(controller, L"getCurPage", this);
|
||
|
setcurpage_id = WASABI_API_MAKI->maki_addDlfRef(controller, L"setCurPage", this);
|
||
|
}
|
||
|
inited = 1;
|
||
|
}
|
||
|
|
||
|
C_TabSheet::~C_TabSheet() {
|
||
|
}
|
||
|
|
||
|
ScriptObject *C_TabSheet::getScriptObject() {
|
||
|
if (obj != NULL) return obj;
|
||
|
return C_TABSHEET_PARENT::getScriptObject();
|
||
|
}
|
||
|
|
||
|
int C_TabSheet::getCurPage() {
|
||
|
ASSERT(inited);
|
||
|
return GET_SCRIPT_INT(WASABI_API_MAKI->maki_callFunction(getScriptObject(), getcurpage_id, NULL));
|
||
|
}
|
||
|
|
||
|
void C_TabSheet::setCurPage(int a) {
|
||
|
ASSERT(inited);
|
||
|
scriptVar a = MAKE_SCRIPT_INT(a);
|
||
|
scriptVar *params[1] = {&a};
|
||
|
WASABI_API_MAKI->maki_callFunction(getScriptObject(), setcurpage_id, params);
|
||
|
}
|
||
|
|
||
|
int C_TabSheet::loaded=0;
|
||
|
int C_TabSheet::getcurpage_id=0;
|
||
|
int C_TabSheet::setcurpage_id=0;
|