Holger Posted October 26, 2004 Posted October 26, 2004 @JPM/CyberSlug: we have now a "conflict-situation" in this flickering-solution:http://www.autoitscript.com/forum/index.php?showtopic=5693So, @CyberSlug: did you change your script?Otherwise @JPM, I would say before changing the GUICtrlSetPos-function the functionality was right and CyberSlugs scripts definitly bug'ed!Yeah, it's logical: a holding mouse button produces messages over messages and if I call a 'repainting'-function on every such mouse event/message then there has to be a flickering.So you should only save one hold mouse button message and do a GUICtrlSetPos only if there is a change to the position i.e.That is my opinion to this whole story...So long...Holger Old project:GUI/Tray menu with icons and colors Other old stuff:IconFileScanner, TriState/ThreeState GUI TreeView, GUI ContextMenu created out of a TreeView
CyberSlug Posted October 27, 2004 Author Posted October 27, 2004 Otherwise @JPM, I would say before changing the GUICtrlSetPos-function the functionality was right and CyberSlugs scripts definitly bug'ed!<{POST_SNAPBACK}>Hmm... The way my day has been going, I'm not surprized Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!
Holger Posted October 27, 2004 Posted October 27, 2004 @CyberSlug: sorry, don't want to make your day more worse then it is... I just wanted to show you that there is a bug in your sample script. Here is what I mean: GUICreate("flickering") $label = GUICtrlCreateLabel("Extrem",10,50,200,80) GUICtrlSetFont(-1,40,1000) $countinfo = GUICtrlCreateLabel("0",0,0,40,16) $count = 0 GUISetState() Do $i = GUIGetCursorInfo() If $i[2] = 1 Then $count = $count + 1 GUICtrlSetData($label,"Extrem") GUICtrlSetData($countinfo,$count) EndIf Until GUIGetMsg() = -3 GUIDelete() Exit Like in your script a function will be called ever and ever. Here it is "GUICtrlSetData". But we cannot change the function to something... The function is doing right but the script is wrong. Old project:GUI/Tray menu with icons and colors Other old stuff:IconFileScanner, TriState/ThreeState GUI TreeView, GUI ContextMenu created out of a TreeView
CyberSlug Posted October 27, 2004 Author Posted October 27, 2004 I could check the previous state of the mouse and only update the control if the mouse was/is not down: GUICreate("flickering") $label = GUICtrlCreateLabel("Extrem",10,50,200,80) GUICtrlSetFont(-1,40,1000) $countinfo = GUICtrlCreateLabel("0",0,0,40,16) $count = 0 $previous = 0 GUISetState() Do $i = GUIGetCursorInfo() If $previous = 0 And $i[2] = 1 Then $count = $count + 1 GUICtrlSetData($label,"Extrem") GUICtrlSetData($countinfo,$count) $previous = 1 ElseIf $previous = 1 And $i[2] = 0 Then $previous = 0 EndIf Until GUIGetMsg() = -3 GUIDelete() Exit Use Mozilla | Take a look at My Disorganized AutoIt stuff | Very very old: AutoBuilder 11 Jan 2005 prototype I need to update my sig!
jpm Posted October 27, 2004 Posted October 27, 2004 @JPM/CyberSlug: we have now a "conflict-situation" in this flickering-solution:http://www.autoitscript.com/forum/index.php?showtopic=5693So, @CyberSlug: did you change your script?Otherwise @JPM, I would say before changing the GUICtrlSetPos-function the functionality was right and CyberSlugs scripts definitly bug'ed!Yeah, it's logical: a holding mouse button produces messages over messages and if I call a 'repainting'-function on every such mouse event/message then there has to be a flickering.So you should only save one hold mouse button message and do a GUICtrlSetPos only if there is a change to the position i.e.That is my opinion to this whole story...So long...Holger<{POST_SNAPBACK}>I am for sure the mention script was not working with the Oct 12 version.The problem come from the fact that an icon control cannot be resized. the refresh is a wrong refresh from the fact that the first CtrlsetPos set a size which is used with the CtrlSetImage . The second CtrlsetPos is not needed.I will search more if there is a way to resize a icon control without reloading the image.
jpm Posted October 27, 2004 Posted October 27, 2004 I get a solution for the CtrlsetPos I will upload it to JON
Josbe Posted October 27, 2004 Posted October 27, 2004 I get a solution for the CtrlsetPos I will upload it to JON <{POST_SNAPBACK}> AUTOIT > AutoIt docs / Beta folder - AutoIt latest beta
Holger Posted October 27, 2004 Posted October 27, 2004 @jpm: I understand ... but great that you have found a solution for the different things Regards Holger Old project:GUI/Tray menu with icons and colors Other old stuff:IconFileScanner, TriState/ThreeState GUI TreeView, GUI ContextMenu created out of a TreeView
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now