XinLu Posted April 7, 2008 Share Posted April 7, 2008 let me make it simple, so I wish you can understand what I am talking about. I created a few buttons, for example, they have Control IDs from 1 to 5 (hint: these control IDs could be retrieved by using GUIGetCursorInfo, the $Array[4] holds the IDs) The same GUI, I also created a Listview. I added some line items (more than 5). Now, items' indices are 0, 1, 2, 3, 4, 5, ...... Now, the problem is: When I click (highlight) on the item with index 1, button A with control ID 1 is activated, meaning it is clicked as well. Same as button B, C, D... Each of these button has a control ID, and this ID matches with a listview index. As long I select the item in the listview, if the index matches with one Control ID, the button will be activated (clicked) I've seen this problem since I started to use listview. Three of my programs got the exactly same problems. My temporary solution for this is to use GUIGetCursoInfo for a double check (if curson is not on top of the button, don't execute functions...) Hope you guys understand what I am saying. Is this a bug or what? How am I going to fix it besides using GUIGetCursoInfo for a double check? Thanks a lot!! Link to comment Share on other sites More sharing options...
AdmiralAlkex Posted April 7, 2008 Share Posted April 7, 2008 This is a bug in the stable version, but it has been fixed in the beta, download that .Some of my scripts: ShiftER, Codec-Control, Resolution switcher for HTC ShiftSome of my UDFs: SDL UDF, SetDefaultDllDirectories, Converting GDI+ Bitmap/Image to SDL Surface Link to comment Share on other sites More sharing options...
weaponx Posted April 7, 2008 Share Posted April 7, 2008 When you click a listviewitem, GuiGetMsg() should return the control id of your entire list, then in your GuiGetMsg() loop you use GUICtrlRead(GUICtrlRead($listview)) to get the contents. Maybe you can post a reproducer script for further diagnosis. Link to comment Share on other sites More sharing options...
XinLu Posted April 7, 2008 Author Share Posted April 7, 2008 Thank you for your quick reply. The beta works! It is a bug. However, the beta brought me a new problem. $BS_MULTILINE for GUI Buttons becomes UNKOWN variable. Has this been removed in beta? To weaponx, thank you as well. But I am not trying to read the content in listview, I just want to select something without activating other buttons. The beta fixed the bug. Thank you all. Link to comment Share on other sites More sharing options...
AdmiralAlkex Posted April 7, 2008 Share Posted April 7, 2008 Thank you for your quick reply. The beta works! It is a bug.However, the beta brought me a new problem. $BS_MULTILINE for GUI Buttons becomes UNKOWN variable. Has this been removed in beta?In the future (the beta) GUIConstants.au3 has changed to not include all the other constants like previous versions. To use $BS_MULTILINE you must include ButtonConstants.au3 .Some of my scripts: ShiftER, Codec-Control, Resolution switcher for HTC ShiftSome of my UDFs: SDL UDF, SetDefaultDllDirectories, Converting GDI+ Bitmap/Image to SDL Surface Link to comment Share on other sites More sharing options...
XinLu Posted April 7, 2008 Author Share Posted April 7, 2008 In the future (the beta) GUIConstants.au3 has changed to not include all the other constants like previous versions. To use $BS_MULTILINE you must include ButtonConstants.au3Thanks a lot!I am learning the change logs for beta. Hope it won't cause me a lot of trouble. Link to comment Share on other sites More sharing options...
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