package qt /* #include "gen_qabstractstate.h" #include */ import "C" import ( "runtime/cgo" "unsafe" ) type QAbstractState struct { h *C.QAbstractState *QObject } func (this *QAbstractState) cPointer() *C.QAbstractState { if this == nil { return nil } return this.h } func newQAbstractState(h *C.QAbstractState) *QAbstractState { if h == nil { return nil } return &QAbstractState{h: h, QObject: newQObject_U(unsafe.Pointer(h))} } func newQAbstractState_U(h unsafe.Pointer) *QAbstractState { return newQAbstractState((*C.QAbstractState)(h)) } func (this *QAbstractState) MetaObject() *QMetaObject { ret := C.QAbstractState_MetaObject(this.h) return newQMetaObject_U(unsafe.Pointer(ret)) } func QAbstractState_Tr(s string) string { s_Cstring := C.CString(s) defer C.free(unsafe.Pointer(s_Cstring)) var _out *C.char = nil var _out_Strlen C.int = 0 C.QAbstractState_Tr(s_Cstring, &_out, &_out_Strlen) ret := C.GoStringN(_out, _out_Strlen) C.free(unsafe.Pointer(_out)) return ret } func QAbstractState_TrUtf8(s string) string { s_Cstring := C.CString(s) defer C.free(unsafe.Pointer(s_Cstring)) var _out *C.char = nil var _out_Strlen C.int = 0 C.QAbstractState_TrUtf8(s_Cstring, &_out, &_out_Strlen) ret := C.GoStringN(_out, _out_Strlen) C.free(unsafe.Pointer(_out)) return ret } func (this *QAbstractState) ParentState() *QState { ret := C.QAbstractState_ParentState(this.h) return newQState_U(unsafe.Pointer(ret)) } func (this *QAbstractState) Machine() *QStateMachine { ret := C.QAbstractState_Machine(this.h) return newQStateMachine_U(unsafe.Pointer(ret)) } func (this *QAbstractState) Active() bool { ret := C.QAbstractState_Active(this.h) return (bool)(ret) } func (this *QAbstractState) ActiveChanged(active bool) { C.QAbstractState_ActiveChanged(this.h, (C.bool)(active)) } func (this *QAbstractState) OnActiveChanged(slot func()) { var slotWrapper miqtCallbackFunc = func(argc C.int, args *C.void) { slot() } C.QAbstractState_connect_ActiveChanged(this.h, unsafe.Pointer(uintptr(cgo.NewHandle(slotWrapper)))) } func QAbstractState_Tr2(s string, c string) string { s_Cstring := C.CString(s) defer C.free(unsafe.Pointer(s_Cstring)) c_Cstring := C.CString(c) defer C.free(unsafe.Pointer(c_Cstring)) var _out *C.char = nil var _out_Strlen C.int = 0 C.QAbstractState_Tr2(s_Cstring, c_Cstring, &_out, &_out_Strlen) ret := C.GoStringN(_out, _out_Strlen) C.free(unsafe.Pointer(_out)) return ret } func QAbstractState_Tr3(s string, c string, n int) string { s_Cstring := C.CString(s) defer C.free(unsafe.Pointer(s_Cstring)) c_Cstring := C.CString(c) defer C.free(unsafe.Pointer(c_Cstring)) var _out *C.char = nil var _out_Strlen C.int = 0 C.QAbstractState_Tr3(s_Cstring, c_Cstring, (C.int)(n), &_out, &_out_Strlen) ret := C.GoStringN(_out, _out_Strlen) C.free(unsafe.Pointer(_out)) return ret } func QAbstractState_TrUtf82(s string, c string) string { s_Cstring := C.CString(s) defer C.free(unsafe.Pointer(s_Cstring)) c_Cstring := C.CString(c) defer C.free(unsafe.Pointer(c_Cstring)) var _out *C.char = nil var _out_Strlen C.int = 0 C.QAbstractState_TrUtf82(s_Cstring, c_Cstring, &_out, &_out_Strlen) ret := C.GoStringN(_out, _out_Strlen) C.free(unsafe.Pointer(_out)) return ret } func QAbstractState_TrUtf83(s string, c string, n int) string { s_Cstring := C.CString(s) defer C.free(unsafe.Pointer(s_Cstring)) c_Cstring := C.CString(c) defer C.free(unsafe.Pointer(c_Cstring)) var _out *C.char = nil var _out_Strlen C.int = 0 C.QAbstractState_TrUtf83(s_Cstring, c_Cstring, (C.int)(n), &_out, &_out_Strlen) ret := C.GoStringN(_out, _out_Strlen) C.free(unsafe.Pointer(_out)) return ret } func (this *QAbstractState) Delete() { C.QAbstractState_Delete(this.h) }