Android Question Telegram theme change animation

AmirMK82

Member
Licensed User
Hello ,
I have an question about theme changing with animation

like telegram:

how can we make like this in B4A?!

thanks
 

AmirMK82

Member
Licensed User
You need to implement it yourself. I would have done it with BitmapCreator and a loop with a call to Sleep.

due to your answer
I tried to make it
and the result is this:


Now I have an question:
- How can I make it more quickly? (I used: Sleep(0))
Thanks
 
Upvote 0

AmirMK82

Member
Licensed User
Test it in Release...

I have tested it(not worked), And this is my code :

B4X:
Sub drawWithAnimatoin
  
    Dim bc As BitmapCreator
    Dim brush As BCBrush
  
    bc.Initialize(100%x, 100%y)
    Dim bmp As B4XBitmap = Root.Snapshot
    brush = bc.CreateBrushFromBitmap(bmp)
    Root.Color = Colors.White
  
    For i=0 To Panel1.Height
      
        bc.DrawCircle2(200dip, 200dip, DipToCurrent(i), brush, True, 10dip)
      
        Panel1.SetBackgroundImage(bc.Bitmap)
      
        Sleep(0)
    Next
  
  
End Sub
 
Upvote 0
Cookies are required to use this site. You must accept them to continue using the site. Learn more…