|
1 | 1 | # -*- coding: UTF-8 -*- |
2 | 2 | # A part of NonVisual Desktop Access (NVDA) |
3 | 3 | # Copyright (C) 2006-2023 NV Access Limited, Peter Vágner, Aleksey Sadovoy, Mesar Hameed, Joseph Lee, |
4 | | -# Thomas Stivers, Babbage B.V., Accessolutions, Julien Cochuyt, Cyrille Bougot |
| 4 | +# Thomas Stivers, Babbage B.V., Accessolutions, Julien Cochuyt, Cyrille Bougot, Luke Davis |
5 | 5 | # This file is covered by the GNU General Public License. |
6 | 6 | # See the file COPYING for more details. |
7 | 7 |
|
@@ -484,10 +484,22 @@ def __init__(self, frame: MainFrame): |
484 | 484 | self.Bind(wx.EVT_MENU, lambda evt: os.startfile("http://www.nvda-project.org/"), item) |
485 | 485 | # Translators: The label for the menu item to view NVDA License document. |
486 | 486 | item = menu_help.Append(wx.ID_ANY, _("L&icense")) |
487 | | - self.Bind(wx.EVT_MENU, lambda evt: os.startfile(getDocFilePath("copying.txt", False)), item) |
| 487 | + # Using operation="edit" to os.startfile below, to work around a Windows 11 related |
| 488 | + # bug in Python 3.7's os.startfile. (#14725) Test reverting to original behavior after Python upgrade. |
| 489 | + self.Bind( |
| 490 | + wx.EVT_MENU, |
| 491 | + lambda evt: os.startfile(getDocFilePath("copying.txt", False), operation="edit"), |
| 492 | + item |
| 493 | + ) |
488 | 494 | # Translators: The label for the menu item to view NVDA Contributors list document. |
489 | 495 | item = menu_help.Append(wx.ID_ANY, _("C&ontributors")) |
490 | | - self.Bind(wx.EVT_MENU, lambda evt: os.startfile(getDocFilePath("contributors.txt", False)), item) |
| 496 | + # Using operation="edit" to os.startfile below, to work around a Windows 11 related |
| 497 | + # bug in Python 3.7's os.startfile. (#14725) Test reverting to original behavior after Python upgrade. |
| 498 | + self.Bind( |
| 499 | + wx.EVT_MENU, |
| 500 | + lambda evt: os.startfile(getDocFilePath("contributors.txt", False), operation="edit"), |
| 501 | + item |
| 502 | + ) |
491 | 503 | # Translators: The label for the menu item to open NVDA Welcome Dialog. |
492 | 504 | item = menu_help.Append(wx.ID_ANY, _("We&lcome dialog...")) |
493 | 505 | self.Bind(wx.EVT_MENU, lambda evt: WelcomeDialog.run(), item) |
|
0 commit comments