Private Sub Base_Resize (Width As Double, Height As Double)
#if B4i
Dim scale As Float = GetDeviceLayoutValues.NonnormalizedScale
#else
Dim scale As Float = 1
#end if
If bc.IsInitialized = False Or bc.mWidth <> Width * scale Then
bc.Initialize(Width * scale, 20dip * scale)
r = 5dip * scale
gap = 15dip * scale
Transparent = bc.CreateBrushFromColor(xui.Color_Transparent)
ActiveBrush = bc.CreateBrushFromColor(clr)
InactiveBrush = bc.CreateBrushFromColor(Bit.Or(0x55000000, Bit.And(0x00FFFFFF, clr)))
End If
iv.SetLayoutAnimated(0, 0, 0, Width, bc.mHeight)
Draw
End Sub