New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CustomTreeCtrl edit label remains stuck forever sometimes #1235
Comments
When you left-click on a label, a TreeEditTimer is started. After If you are already editing the label this shouldn't happen, but the TreeTextCtrl doesn't fully cover the label area. So if you click just outside the TreeTextCtrl, the When you change the selection, only the most recent TreeTextCtrl is Destroyed and the old one is left orphaned in the tree. Could be fixed in
if |
@cbeytas Thank you for looking into this! It means a lot to me. Based on your explanation, I added a condition for checking
That seems to have been enough to fix the issue. In wxDemo you can see that the edit event is triggered multiple times, but a new TreeTextCtrl is not created. |
This issue has been mentioned on Discuss wxPython. There might be relevant details there: https://discuss.wxpython.org/t/wxpython-4-1-0-released/34564/1 |
Windows 10 (or Windows 7)
wxPython 4.0.6 (pip)
Python 3.7.3 [32bit]
From what I can tell, it seems that I'm able to somehow select the label from behind the TextCtrl and trigger a second edit label instance that can't be closed.
Or maybe KillFocus doesn't trigger correctly? I dunno.
Here's me reproducing it with the example from wxDemo:

Another example (from another GUI):

The text was updated successfully, but these errors were encountered: