Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
Dim ClickTimer As Timer
End Sub
Sub Globals
'These global variables will be redeclared each time the activity is created.
'These variables can only be accessed from this module.
Private Button1 As Button
End Sub
Sub Activity_Create(FirstTime As Boolean)
'Do not forget to load the layout file created with the visual designer. For example:
Activity.LoadLayout("1") 'Layout just contains Button1
ClickTimer.Initialize("ClickTimer",1000)
End Sub
Sub Activity_Resume
End Sub
Sub Activity_Pause (UserClosed As Boolean)
ClickTimer.Enabled = False
End Sub
Private Sub Button1_Click
If ClickTimer.Enabled Then
Log("Click Ignored")
Return
End If
ClickTimer.Enabled = True
Log("Process click")
End Sub
Private Sub ClickTimer_Tick
ClickTimer.Enabled = False
End Sub