Private Sub Button1_Click
Dim iv As ImageView
iv.Initialize("")
Dim xiv As B4XView = iv
XUIViewsUtils.SetBitmapAndFill(xiv, xui.LoadBitmap(File.DirAssets, "Ball-4-icon.png"))
Dim w = 50dip, h = 50dip As Int
Root.AddView(iv, Root.Width / 2 - w / 2, Root.Height / 2 - h / 2, w, h)
w = 100dip
h = 100dip
xiv.SetLayoutAnimated(300, Root.Width / 2 - w / 2, Root.Height / 2 - h / 2, w, h)
Sleep(300)
Dim tx = 50dip, ty = 50dip As Int
xiv.SetLayoutAnimated(300, tx - w / 2,ty - h / 2, w, h)
Sleep(500)
w = 50dip
h = 50dip
xiv.SetLayoutAnimated(300, tx - w / 2,ty - h / 2, w, h)
End Sub