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
Don't use UnidentifiedEdit for windows with empty windowText #11966
Don't use UnidentifiedEdit for windows with empty windowText #11966
Conversation
@lukaszgo1 Can you please give a bit more explanation as to the exact issue with edit fields in MCS Electronics IDE? If we suppress these windows from being classed as an unidentified edit, what does the user then experience? How is it "once again readable"? |
@michaelDCurran wrote:
When we're not using |
See test results for failed build of commit f5db84962c |
…vaccess#11966)" This reverts commit 4288882.
…11966)" (#12429) This reverts commit 4288882. PR #11966 started using DisplayModelEditableText for edit fields with empty window text to improve access to IDE's by MCS Electronic - this unfortunately broke access to some edit fields in Excel as they were forcibly using DisplayModelEditableText and now they were getting this class twice in the MRO. When trying to come up with a fix I've found another problems with the approach from #11966 namely edit fields which require UnidentifiedEdit weren't getting it in the MRO when they are initially empty. Since we're quite close to the release it makes sense to revert #11966 for now and investigate another approach - the program for which the original fix was needed is quite niche and therefore I don't consider this to be a big loss. I'll try to come up with something better for the next release.
Link to issue number:
None, regression from PR #8165
Summary of the issue:
PR #8165 started using
UnidentifiedEdit
for windows which contain a caret and for whichEM_LINELENGTH
returns 1 or more. Unfortunately I've seen cases in the wild in whichEM_LINELENGTH
returns count of lines in the edit field yet it'swindowText
is empty andUnidentifiedEdit
relies onwindowText
being correct to retrieve content.Description of how this pull request fixes the issue:
If the given window responds to
EM_LINELENGTH
with a positive value before addingUnidentifiedEdit
to its MRO we're now checking if it windowText is not empty.Testing performed:
Ensured that main editor in BASCOM_AVR from MCS Electronics is once again readable.
Known issues with pull request:
It's theoretically possible that getting windowtext before adding
UnidentifiedEdit
can cause performance problems. I'm reluctant to use an appModule based approach here because using class which requires windowText to be correct for windows for which windowText is empty makes no sense.Change log entry:
Section: Bug fixes
Fixed access to edit fields in MCS Electronics IDE's