Jump to content
Sign in to follow this  
Lecdev

Set Image Flicker Help

Recommended Posts

Lecdev

If anybody has a bright idea (aside from slowing down the image update) on how to stop the intermittent flickering on this little bit of test gui code i'd love to hear it, my icon dll (icl) is attached

 

GUICreate("Preloader Test", 296, 296)
Global $sFile = "Preloader.dll"
Global $nCounter = 1
Global $sIconName = "image" & String($nCounter)
Global $hIcon = GUICtrlCreateIcon($sFile,$sIconName,20,20,256,256)
GUISetState(@SW_SHOW)
Local $gMsg

AdlibRegister ( "_SpinPreloader", 50)
Do
    Sleep(10)
    ; do loop searching/loading
Until GUIGetMsg() = -3
AdlibUnRegister("_SpinPreloader")
Exit

Func _SpinPreloader()
    $nCounter += 1
    If $nCounter = 9 Then $nCounter = 1
    $sIconName = "image" & String($nCounter)
    GUICtrlSetImage($hIcon,$sFile,$sIconName)
EndFunc

Preloader.dll

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this  

×