Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
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.
Dim fld_coords As EditText
Dim fingerTop As Float
Dim fingerLeft As Float
End Sub
Sub Activity_Create(FirstTime As Boolean)
Dim pnl_w1,pnl_w2,pnl_w3,pnl_w4,pnl_w5,pnl_w6 As Panel
Dim pnl_b1,pnl_b2,pnl_b3,pnl_b4,pnl_b5,pnl_b6 As Panel
Dim pnl_gk, pnl_ball As Panel
pnl_w1.Initialize ("panels")
pnl_w2.Initialize ("panels")
pnl_w3.Initialize ("panels")
pnl_w4.Initialize ("panels")
pnl_w5.Initialize ("panels")
pnl_w6.Initialize ("panels")
pnl_b1.Initialize ("panels")
pnl_b2.Initialize ("panels")
pnl_b3.Initialize ("panels")
pnl_b4.Initialize ("panels")
pnl_b5.Initialize ("panels")
pnl_b6.Initialize ("panels")
pnl_gk.Initialize ("panels")
pnl_ball.Initialize ("panels")
Activity.LoadLayout("frm_1")
End Sub
Sub Activity_Resume
End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub
Sub panels_Touch (Action As Int, X As Float, Y As Float)
Dim s As Panel
s = Sender
Select Action
Case 0 ' ACTION_DOWN
fingerTop= Y
fingerLeft= X
Case 2 ' ACTION_MOVE
s.Top = s.Top + Y - fingerTop
s.Left= s.Left + X - fingerLeft
Case 1 ' ACTION_UP
Log("ACTION_UP")
End Select
DoEvents
fld_coords.text= "Coords " & S.Tag & ": " & s.Left & "; " & s.Top
End Sub
'Sub pnl_w1_Touch (Action As Int, X As Float, Y As Float)
'Dim s As Panel
'
' s = Sender
' Select Action
' Case 0 ' ACTION_DOWN
' fingerTop= Y
' fingerLeft= X
' Case 2 ' ACTION_MOVE
' s.Top = s.Top + Y - fingerTop
' s.Left= s.Left + X - fingerLeft
' Case 1 ' ACTION_UP
' Log("ACTION_UP")
' End Select
'
' DoEvents
'
' fld_coords.text= "Coords " & S.Tag & ": " & s.Left & "; " & s.Top
'End Sub
'
'
'Sub pnl_w2_Touch (Action As Int, X As Float, Y As Float)
'Dim s As Panel
'
' s = Sender
' Select Action
' Case 0 ' ACTION_DOWN
' fingerTop= Y
' fingerLeft= X
' Case 2 ' ACTION_MOVE
' s.Top = s.Top + Y - fingerTop
' s.Left= s.Left + X - fingerLeft
' Case 1 ' ACTION_UP
' Log("ACTION_UP")
' End Select
'
' DoEvents
'
' fld_coords.text= "Coords " & S.Tag & ": " & s.Left & "; " & s.Top
'End Sub
'
'Sub pnl_w3_Touch (Action As Int, X As Float, Y As Float)
'Dim s As Panel
'
' s = Sender
' Select Action
' Case 0 ' ACTION_DOWN
' fingerTop= Y
' fingerLeft= X
' Case 2 ' ACTION_MOVE
' s.Top = s.Top + Y - fingerTop
' s.Left= s.Left + X - fingerLeft
' Case 1 ' ACTION_UP
' Log("ACTION_UP")
' End Select
'
' DoEvents
'
' fld_coords.text= "Coords " & S.Tag & ": " & s.Left & "; " & s.Top
'End Sub
'
'Sub pnl_w4_Touch (Action As Int, X As Float, Y As Float)
'Dim s As Panel
'
' s = Sender
' Select Action
' Case 0 ' ACTION_DOWN
' fingerTop= Y
' fingerLeft= X
' Case 2 ' ACTION_MOVE
' s.Top = s.Top + Y - fingerTop
' s.Left= s.Left + X - fingerLeft
' Case 1 ' ACTION_UP
' Log("ACTION_UP")
' End Select
'
' DoEvents
'
' fld_coords.text= "Coords " & S.Tag & ": " & s.Left & "; " & s.Top
'End Sub
'
'Sub pnl_w5_Touch (Action As Int, X As Float, Y As Float)
'Dim s As Panel
'
' s = Sender
' Select Action
' Case 0 ' ACTION_DOWN
' fingerTop= Y
' fingerLeft= X
' Case 2 ' ACTION_MOVE
' s.Top = s.Top + Y - fingerTop
' s.Left= s.Left + X - fingerLeft
' Case 1 ' ACTION_UP
' Log("ACTION_UP")
' End Select
'
' DoEvents
'
' fld_coords.text= "Coords " & S.Tag & ": " & s.Left & "; " & s.Top
'End Sub
'
'Sub pnl_w6_Touch (Action As Int, X As Float, Y As Float)
'Dim s As Panel
'
' s = Sender
' Select Action
' Case 0 ' ACTION_DOWN
' fingerTop= Y
' fingerLeft= X
' Case 2 ' ACTION_MOVE
' s.Top = s.Top + Y - fingerTop
' s.Left= s.Left + X - fingerLeft
' Case 1 ' ACTION_UP
' Log("ACTION_UP")
' End Select
'
' DoEvents
'
' fld_coords.text= "Coords " & S.Tag & ": " & s.Left & "; " & s.Top
'End Sub
'
'Sub pnl_b1_Touch (Action As Int, X As Float, Y As Float)
'Dim s As Panel
'
' s = Sender
' Select Action
' Case 0 ' ACTION_DOWN
' fingerTop= Y
' fingerLeft= X
' Case 2 ' ACTION_MOVE
' s.Top = s.Top + Y - fingerTop
' s.Left= s.Left + X - fingerLeft
' Case 1 ' ACTION_UP
' Log("ACTION_UP")
' End Select
'
' DoEvents
'
' fld_coords.text= "Coords " & S.Tag & ": " & s.Left & "; " & s.Top
'End Sub
'
'Sub pnl_b2_Touch (Action As Int, X As Float, Y As Float)
'Dim s As Panel
'
' s = Sender
' Select Action
' Case 0 ' ACTION_DOWN
' fingerTop= Y
' fingerLeft= X
' Case 2 ' ACTION_MOVE
' s.Top = s.Top + Y - fingerTop
' s.Left= s.Left + X - fingerLeft
' Case 1 ' ACTION_UP
' Log("ACTION_UP")
' End Select
'
' DoEvents
'
' fld_coords.text= "Coords " & S.Tag & ": " & s.Left & "; " & s.Top
'End Sub
'
'Sub pnl_b3_Touch (Action As Int, X As Float, Y As Float)
'Dim s As Panel
'
' s = Sender
' Select Action
' Case 0 ' ACTION_DOWN
' fingerTop= Y
' fingerLeft= X
' Case 2 ' ACTION_MOVE
' s.Top = s.Top + Y - fingerTop
' s.Left= s.Left + X - fingerLeft
' Case 1 ' ACTION_UP
' Log("ACTION_UP")
' End Select
'
' DoEvents
'
' fld_coords.text= "Coords " & S.Tag & ": " & s.Left & "; " & s.Top
'End Sub
'
'Sub pnl_b4_Touch (Action As Int, X As Float, Y As Float)
'Dim s As Panel
'
' s = Sender
' Select Action
' Case 0 ' ACTION_DOWN
' fingerTop= Y
' fingerLeft= X
' Case 2 ' ACTION_MOVE
' s.Top = s.Top + Y - fingerTop
' s.Left= s.Left + X - fingerLeft
' Case 1 ' ACTION_UP
' Log("ACTION_UP")
' End Select
'
' DoEvents
'
' fld_coords.text= "Coords " & S.Tag & ": " & s.Left & "; " & s.Top
'End Sub
.....