'Activity module
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 Edit1 As EditText
Dim Edit2 As EditText
Dim CurrentEdit As EditText
End Sub
Sub Activity_Create(FirstTime As Boolean)
Edit1.Initialize ("edit")
Edit1.InputType = Edit1.INPUT_TYPE_NONE
Edit2.Initialize ("edit")
Edit2.InputType = Edit2.INPUT_TYPE_NONE
CurrentEdit = Edit2 ' Is this the offender? Remove it and things work as expected
Activity.AddView (Edit1,10%x, 10%y, 80%x, 15%y)
Activity.AddView (Edit2,10%x, 40%y, 80%x, 15%y)
End Sub
Sub Activity_Resume
End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub
Sub edit_FocusChanged (HasFocus As Boolean)
If HasFocus Then CurrentEdit = Sender
End Sub