|
2011-03-19
| ||
| 09:04 | • Closed ticket [3223850fff]: Button remains stuck when disabled as depressed on XP plus 7 other changes artifact: f50fbf4712 user: patthoyts | |
| 08:28 | • Ticket [3223850fff]: 4 changes artifact: 9af44a1c1b user: patthoyts | |
|
2011-03-18
| ||
| 21:53 | • New ticket [3223850fff]. artifact: ff2540421c user: thomasmenez | |
| Ticket UUID: | 3223850 | |||
| Title: | Button remains stuck when disabled as depressed on XP | |||
| Type: | Bug | Version: | obsolete: 8.6b1.1 | |
| Submitter: | thomasmenez | Created on: | 2011-03-18 21:53:40 | |
| Subsystem: | 03. [*button] and [label] | Assigned To: | hobbs | |
| Priority: | 5 Medium | Severity: | ||
| Status: | Closed | Last Modified: | 2011-03-19 09:04:54 | |
| Resolution: | Fixed | Closed By: | patthoyts | |
| Closed on: | 2011-03-19 02:04:54 | |||
| Description: |
Problem reproduced on Win XP SP3, unable to reproduce on Ubutnu 8.04. Activestate 8.5.7. The problem arises when left mouse button is depressed over a ttk::button (setting the button in the 'depressed' state), and then an event disables this button, while the mouse button is still depressed. Then the mouse button is released.When the button is re enabled later, it remains visually depressed. Another std click on this button set it back to normal state. Unsure fact (to be verified) : It seems that not moving the mouse pointer during these operations makes it more reproducible. | |||
| User Comments: |
patthoyts added on 2011-03-19 09:04:54:
allow_comments - 1 Applied this fix to core-8-5-branch and trunk. patthoyts added on 2011-03-19 08:28:27: When you press the button you set its state to {pressed active}. You then force an additional disabled on there via an event. When the ButtonRelease-1 event fires it checks the state and only removes the pressed when not disabled. The Leave event removes the {active} state.
We can fix this by changing the event as follows:
bind TButton <ButtonRelease-1> {%W instate {pressed} {%W state !pressed; %W instate !disabled {%W invoke}}}
This wil always remove the pressed state and then only calls invoke is the window was not disabled.
This should be the same on unix - the event handling is cross platform - just the look of the button for pressed !disabled may be different.
| |||