Sub Process_Globals
'These global variables will be declared once when the application starts.
'These variables can be accessed from all modules.
Private xui As XUI
End Sub
Sub Globals
'These global variables will be redeclared each time the activity is created.
Private WebView1 As WebView
Private Button1 As B4XView
Private uri As String
Dim in As Intent
End Sub
Sub Activity_Create(FirstTime As Boolean)
If FirstTime= True Then
Activity.LoadLayout("Layout")
If uri="" Then uri="https://kleinersonnenschein.eu/forum/forums/"
WebView1.LoadUrl(uri)
End If
End Sub
Sub Activity_Resume
Activity.LoadLayout("Layout")
in = Activity.GetStartingIntent 'GetIntent1
If in.Action = in.ACTION_VIEW Then
uri=in.GetData
Log (uri)
End If
If uri="" Then uri="https://kleinersonnenschein.eu/forum/forums/"
WebView1.LoadUrl(uri)
End Sub
Sub Activity_Pause (UserClosed As Boolean)
End Sub
Sub Button1_Click
Log ("load :"&uri)
WebView1.LoadUrl(uri)
End Sub
Sub WebView1_PageFinished (url As String)
Log ("page loaded")
End Sub
Sub WebView1_OverrideUrl (url As String) As Boolean
Log (url)
End Sub