Skip to content
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

Make gui.MainFrame.popupSettingsDialog part of the public API #15121

Merged
merged 3 commits into from
Jul 14, 2023

Conversation

seanbudd
Copy link
Member

@seanbudd seanbudd commented Jul 11, 2023

Link to issue number:

Fixes #15120

Summary of the issue:

If add-ons want to provide a gesture or similar to open their config dialogs, they currently have two choices:

  • Call gui.mainFrame._popupSettingsDialog, which is a private method and could thus change signature or mechanism at any moment without breakage warning. Several add-ons currently live on the edge by using this approach, including one of mine.
  • Replicate the internals of gui.MainFrame._popupSettingsDialog to achieve the same thing, which involves some imports and careful management of parents and exceptions.

Description of user facing changes

None

Description of development approach

Mark API as public

Update AddonStore command to use the function

Testing strategy:

Tested opening and closing add-on store

Known issues with pull request:

None

Change log entries:

N/A

Code Review Checklist:

  • Pull Request description:
    • description is up to date
    • change log entries
  • Testing:
    • Unit tests
    • System (end to end) tests
    • Manual testing
  • API is compatible with existing add-ons.
  • Documentation:
    • User Documentation
    • Developer / Technical Documentation
    • Context sensitive help for GUI changes
  • UX of all users considered:
    • Speech
    • Braille
    • Low Vision
    • Different web browsers
    • Localization in other languages / culture than English
  • Security precautions taken.

@seanbudd seanbudd requested a review from a team as a code owner July 11, 2023 06:24
@seanbudd seanbudd requested a review from michaelDCurran July 11, 2023 06:24
Copy link
Collaborator

@XLTechie XLTechie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @seanbudd! I suggest a note in the changes for developers that this has become public.

@AppVeyorBot
Copy link

See test results for failed build of commit 3aca986134

@seanbudd seanbudd requested a review from michaelDCurran July 12, 2023 01:36
@seanbudd
Copy link
Member Author

@michaelDCurran - re-requesting review as the lint fix was non-trivial

@XLTechie
Copy link
Collaborator

XLTechie commented Jul 12, 2023 via email

@seanbudd seanbudd merged commit a8b79c7 into master Jul 14, 2023
@seanbudd seanbudd deleted the fixuUpPopupSettingsDialog branch July 14, 2023 07:13
@nvaccessAuto nvaccessAuto added this to the 2023.2 milestone Jul 14, 2023
@jmdaweb
Copy link

jmdaweb commented Jul 15, 2023

Hi,
Since the add-ons mailing list is not the right place to discuss these things (as stated by the moderator), I suggest adding an alias for this method to keep compatibility until NVDA 2024.1. Although the function was not public, many add-ons make use of it and will break on 2023.2. This is the relevant thread: https://nvda-addons.groups.io/g/nvda-addons/topic/100136959
Regards.

@nvdaes
Copy link
Collaborator

nvdaes commented Jul 15, 2023

Hello: Seems that this PR has been merged even wrongly. When I see the log, this appears:

commit a8b79c7
Author: Sean Budd [email protected]
Date: Fri Jul 14 17:13:13 2023 +1000

Make gui.MainFrame.popupSettingsDialog part of the public API (#15121)

Fixes #15096

Summary of the issue:
When an active profile has the synthesizer set to silence, and a user switches profiles to a synthesizer which fails to load, NVDA fails back to the silence synthesizer.

Also, as mentioned in issue #15141 , this breaks compatibility with add-ons. Additionally, in issue #15142 , vision provided are broken.
I think it maybe better to revert this and, since it's not urgent, and NVDA 2023.2 is almost complete, and we need to test relevant things like support for localizations in the store, I think this maybe reverted and set the milestone to 2024.1.

Author: Sean Budd [email protected]
Date: Fri Jul 14 17:13:13 2023 +1000

Make gui.MainFrame.popupSettingsDialog part of the public API (#15121)

Fixes #15096

Summary of the issue:
When an active profile has the synthesizer set to silence, and a user switches profiles to a synthesizer which fails to load, NVDA fails back to the silence synthesizer.

@XLTechie
Copy link
Collaborator

XLTechie commented Jul 15, 2023 via email

@ABuffEr
Copy link
Contributor

ABuffEr commented Jul 15, 2023

I think it maybe better to revert this and, since it's not urgent, and NVDA 2023.2 is almost complete, and we need to test relevant things like support for localizations in the store, I think this maybe reverted and set the milestone to 2024.1.

I completely agree with this proposal.

XLTechie pushed a commit to XLTechie/xlnvda that referenced this pull request Jul 15, 2023
…nvaccess#15121)"

This reverts commit a8b79c7.

The commit text referenced the solution to an unrelated issue.
The lint changes necessary for nvaccess#15121, appear to have broken NVDA's vision settings and possibly more.
The base change from nvaccess#15120 itself, having no alias, apparently breaks 30 plus add-ons, according to a prominent add-on developer.
XLTechie pushed a commit to XLTechie/xlnvda that referenced this pull request Jul 15, 2023
…nvaccess#15121)"

This reverts commit a8b79c7.

The commit text referenced the solution to an unrelated issue.
The lint changes necessary for nvaccess#15121, appear to have broken NVDA's vision settings, OCR, and possibly more.
seanbudd added a commit that referenced this pull request Jul 17, 2023
@seanbudd seanbudd mentioned this pull request Jul 17, 2023
6 tasks
seanbudd added a commit that referenced this pull request Jul 17, 2023
Follow up to #15121

Fixes #15142
Fixes #15141
Fixes #15148
Fixes #15147

Summary of the issue:
PR #15121 to fix #15120 had various unexpected side effects.
This is due to symbols that were previously star imported into gui/__init__.py being removed.
Add-ons and the vision enhancements core module relied on these symbols being imported.
While there was no API breaking changes, these changes affected over 30 add-ons

Description of user facing changes
Fix up issue with vision enhancement providers, such as opening the relevant settings panels.

Description of development approach
Add aliases for SettingsPanel, AutoSettingsMixin, _popupSettingsDialog in gui
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
8 participants