Skip to content

Commit

Permalink
don't rely on star imports from synthDriverHandler (nvaccess#12172)
Browse files Browse the repository at this point in the history
* synthDriverHandler: Remove unused imports, standardize copyright header

* sayAllHandler: Remove unused import of synthDriverHandler

* settingsDialog: don't rely on star imports from synthDriverHandler

* globalCommands: don't rely onn star imports from synthDriverHandler, remove unused imports

* update changes.t2t

Co-authored-by: buddsean <[email protected]>
  • Loading branch information
lukaszgo1 and seanbudd authored Mar 17, 2021
1 parent 3dcba91 commit 04849b0
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 13 deletions.
5 changes: 1 addition & 4 deletions source/globalCommands.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,9 @@
# Leonard de Ruijter, Derek Riemer, Babbage B.V., Davy Kager, Ethan Holliger, Łukasz Golonka, Accessolutions,
# Julien Cochuyt

import time
import itertools
from typing import Optional

import tones
import audioDucking
import touchHandler
import keyboardHandler
Expand All @@ -25,7 +23,6 @@
from NVDAObjects import NVDAObject, NVDAObjectTextInfo
import globalVars
from logHandler import log
from synthDriverHandler import *
import gui
import wx
import config
Expand All @@ -34,13 +31,13 @@
import winKernel
import treeInterceptorHandler
import browseMode
import languageHandler
import scriptHandler
from scriptHandler import script
import ui
import braille
import brailleInput
import inputCore
import virtualBuffers
import characterProcessing
from baseObject import ScriptableObject
import core
Expand Down
6 changes: 3 additions & 3 deletions source/gui/settingsDialogs.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@
# This file is covered by the GNU General Public License.
# See the file COPYING for more details.
import logging
from abc import ABCMeta
from abc import ABCMeta, abstractmethod
import copy
import os

import wx
from vision.providerBase import VisionEnhancementProviderSettings
Expand All @@ -17,8 +18,7 @@
import winUser
import logHandler
import installer
from synthDriverHandler import *
from synthDriverHandler import SynthDriver, getSynth
from synthDriverHandler import changeVoice, getSynth, getSynthList, setSynth, SynthDriver
import config
import languageHandler
import speech
Expand Down
1 change: 0 additions & 1 deletion source/sayAllHandler.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
import weakref
import garbageHandler
import speech
import synthDriverHandler
from logHandler import log
import config
import controlTypes
Expand Down
5 changes: 0 additions & 5 deletions source/synthDriverHandler.py
Original file line number Diff line number Diff line change
@@ -1,19 +1,15 @@
# -*- coding: UTF-8 -*-
# synthDriverHandler.py
# A part of NonVisual Desktop Access (NVDA)
# This file is covered by the GNU General Public License.
# See the file COPYING for more details.
# Copyright (C) 2006-2019 NV Access Limited, Peter Vágner, Aleksey Sadovoy,
# Joseph Lee, Arnold Loubriat, Leonard de Ruijter

import os
import pkgutil
import importlib
from typing import Optional
from locale import strxfrm

import config
import baseObject
import winVersion
import globalVars
from logHandler import log
Expand All @@ -23,7 +19,6 @@
import extensionPoints
import synthDrivers
import driverHandler
from driverHandler import StringParameterInfo # noqa: F401 # Backwards compatibility
from abc import abstractmethod


Expand Down
1 change: 1 addition & 0 deletions user_docs/en/changes.t2t
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ What's New in NVDA
- `speech.getSpeechForSpelling` has been removed - use `speech.getSpellingSpeech` (#12145)
- Commands cannot be directly imported from speech as `import speech; speech.ExampleCommand()` or `import speech.manager; speech.manager.ExampleCommand()` - use `from speech.commands import ExampleCommand` instead (#12126)
- `speakTextInfo` will no longer send speech through `speakWithoutPauses` if reason is `SAYALL`, as `sayAllhandler` does this manually now. (#12150)
- The `synthDriverHandler` module is no longer star imported into `globalCommands` and `gui.settingsDialogs` - use `from synthDriverHandler import synthFunctionExample` instead. (#12172)
- `ROLE_EQUATION` has been removed from controlTypes - use `ROLE_MATH`` instead. (#12164)


Expand Down

0 comments on commit 04849b0

Please sign in to comment.