Page 1 of 1

[SOLVED]; PB5.31; Win7; scrollbar; async repaint of box

Posted: Fri May 22, 2015 12:38 pm
by HanPBF
Hello!

I have a horizontal scrollbar bound to an owner made repeater box having some gadgets.
The horizontal scrollbar does allow to move the box left/right.

I bound the scrollbar event with BindGadgetEvent which fires immediately; which is what it should do.

Now, I have the problem that the box is too often redrawn and moving the scrollbar fast gives an annoying flickering.

Any idea how I could prevent repaint for some ms?
Do I have to use AddWindowTimer to async the update of the box?
Is there a better solution?
Is there a timer callback like in JS (setTimeout()) which can be given a callback?
Any other hint I'd appreciate a lot!


Thanks a lot in advance!

PB5.31; Win7; scrollbar; async repaint of box; flickering

Posted: Fri May 22, 2015 1:31 pm
by HanPBF
solved...

Code: Select all

;in scrollbar handler
;...
LockWindowUpdate_(WindowID(EventWindow()))		
updateListGadget(*LG)
LockWindowUpdate_(0)
;...