Private Sub B4XPage_Created (Root1 As B4XView)
Root = Root1
B4XPages.GetNativeParent(Me).AddView(Root, 0, 0, 100%x, 100%y) '<----------
Root.Visible = False
Root.LoadLayout("MainPage")
MP = B4XPages.MainPage
btnJumpToParis.Enabled = False
If gmap.IsInitialized = False Then
Wait For (InitializeMap) Complete (Success As Boolean)
MapReady = Success
If MapReady Then
Log("map ready")
btnJumpToParis.Enabled = True
gmap.AddMarker(0, 0, "Center")
End If
End If
End Sub
Private Sub B4XPage_Appear
Root.Visible = True
End Sub