-
Notifications
You must be signed in to change notification settings - Fork 0
/
timer.go
141 lines (106 loc) · 2.77 KB
/
timer.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
//----------------------------------------
// 代码由GenlibVcl工具自动生成。
// Copyright © ying32. All Rights Reserved.
//
//----------------------------------------
package vcl
import (
. "gitee.com/ying32/govcl/vcl/api"
)
type TTimer struct {
IComponent
instance uintptr
}
func NewTimer(owner IComponent) *TTimer {
t := new(TTimer)
t.instance = Timer_Create(CheckPtr(owner))
return t
}
func TimerFromInst(inst uintptr) *TTimer {
t := new(TTimer)
t.instance = inst
return t
}
func TimerFromObj(obj IObject) *TTimer {
t := new(TTimer)
t.instance = CheckPtr(obj)
return t
}
func (t *TTimer) Free() {
if t.instance != 0 {
Timer_Free(t.instance)
t.instance = 0
}
}
func (t *TTimer) Instance() uintptr {
return t.instance
}
func (t *TTimer) IsValid() bool {
return t.instance != 0
}
func (t *TTimer) FindComponent(AName string) *TComponent {
return ComponentFromInst(Timer_FindComponent(t.instance, AName))
}
func (t *TTimer) GetNamePath() string {
return Timer_GetNamePath(t.instance)
}
func (t *TTimer) HasParent() bool {
return Timer_HasParent(t.instance)
}
func (t *TTimer) Assign(Source IObject) {
Timer_Assign(t.instance, CheckPtr(Source))
}
func (t *TTimer) ClassName() string {
return Timer_ClassName(t.instance)
}
func (t *TTimer) Equals(Obj IObject) bool {
return Timer_Equals(t.instance, CheckPtr(Obj))
}
func (t *TTimer) GetHashCode() int32 {
return Timer_GetHashCode(t.instance)
}
func (t *TTimer) ToString() string {
return Timer_ToString(t.instance)
}
func (t *TTimer) Enabled() bool {
return Timer_GetEnabled(t.instance)
}
func (t *TTimer) SetEnabled(value bool) {
Timer_SetEnabled(t.instance, value)
}
func (t *TTimer) Interval() uint32 {
return Timer_GetInterval(t.instance)
}
func (t *TTimer) SetInterval(value uint32) {
Timer_SetInterval(t.instance, value)
}
func (t *TTimer) SetOnTimer(fn TNotifyEvent) {
Timer_SetOnTimer(t.instance, fn)
}
func (t *TTimer) ComponentCount() int32 {
return Timer_GetComponentCount(t.instance)
}
func (t *TTimer) ComponentIndex() int32 {
return Timer_GetComponentIndex(t.instance)
}
func (t *TTimer) SetComponentIndex(value int32) {
Timer_SetComponentIndex(t.instance, value)
}
func (t *TTimer) Owner() *TComponent {
return ComponentFromInst(Timer_GetOwner(t.instance))
}
func (t *TTimer) Name() string {
return Timer_GetName(t.instance)
}
func (t *TTimer) SetName(value string) {
Timer_SetName(t.instance, value)
}
func (t *TTimer) Tag() int {
return Timer_GetTag(t.instance)
}
func (t *TTimer) SetTag(value int) {
Timer_SetTag(t.instance, value)
}
func (t *TTimer) Components(AIndex int32) *TComponent {
return ComponentFromInst(Timer_GetComponents(t.instance, AIndex))
}