D
Deleted member 103
Guest
Hi,
I load a layout in a root panel (because of iPhone-X), but it always takes different amounts of time.
How can I wait until a layout is completely loaded?
I use this code, but sometimes 100 ms are sufficient and sometimes 500ms are necessary.
I load a layout in a root panel (because of iPhone-X), but it always takes different amounts of time.
How can I wait until a layout is completely loaded?
I use this code, but sometimes 100 ms are sufficient and sometimes 500ms are necessary.
B4X:
Private Sub Page1_Resize(Width As Int, Height As Int)
Log("Page1_Resize")
If pnlRoot.IsInitialized Then
Dim r As Rect = Page1.SafeAreaInsets
pnlRoot.SetLayoutAnimated(0, 1, r.Left, r.Top, Width - r.Right - r.Left, Height - r.Bottom - r.Top)
Sleep(100)
End If
...
End Sub