cleanup: pep8
also remove empty class parenthesis
This commit is contained in:
@@ -62,6 +62,7 @@ def _gen_check_ctxt(settings):
|
||||
"spell_errors": {},
|
||||
}
|
||||
|
||||
|
||||
def _diff_check_ctxt(check_ctxt, minus_check_ctxt):
|
||||
"""Returns check_ctxt - minus_check_ctxt"""
|
||||
for key in check_ctxt:
|
||||
@@ -74,6 +75,7 @@ def _diff_check_ctxt(check_ctxt, minus_check_ctxt):
|
||||
if warning in check_ctxt[key]:
|
||||
del check_ctxt[key][warning]
|
||||
|
||||
|
||||
def _gen_reports(check_ctxt):
|
||||
return {
|
||||
"check_ctxt": check_ctxt,
|
||||
@@ -473,7 +475,6 @@ def dump_py_messages_from_files(msgs, reports, files, settings):
|
||||
|
||||
return [_extract_string_merge(estr_ls, nds_ls) for estr_ls, nds_ls in bag]
|
||||
|
||||
|
||||
i18n_ctxt_ids = {v for v in bpy.app.translations.contexts_C_to_py.values()}
|
||||
def _ctxt_to_ctxt(node):
|
||||
# We must try, to some extend, to get contexts from vars instead of only literal strings...
|
||||
|
||||
@@ -473,6 +473,7 @@ for p in set(INTERN_PY_SYS_PATHS.split(";")):
|
||||
def _do_get(ref, path):
|
||||
return os.path.normpath(os.path.join(ref, path))
|
||||
|
||||
|
||||
def _do_set(ref, path):
|
||||
path = os.path.normpath(path)
|
||||
# If given path is absolute, make it relative to current ref one (else we consider it is already the case!)
|
||||
@@ -484,6 +485,7 @@ def _do_set(ref, path):
|
||||
pass
|
||||
return path
|
||||
|
||||
|
||||
def _gen_get_set_path(ref, name):
|
||||
def _get(self):
|
||||
return _do_get(getattr(self, ref), getattr(self, name))
|
||||
@@ -491,6 +493,7 @@ def _gen_get_set_path(ref, name):
|
||||
setattr(self, name, _do_set(getattr(self, ref), value))
|
||||
return _get, _set
|
||||
|
||||
|
||||
def _gen_get_set_paths(ref, name):
|
||||
def _get(self):
|
||||
return [_do_get(getattr(self, ref), p) for p in getattr(self, name)]
|
||||
@@ -498,6 +501,7 @@ def _gen_get_set_paths(ref, name):
|
||||
setattr(self, name, [_do_set(getattr(self, ref), p) for p in value])
|
||||
return _get, _set
|
||||
|
||||
|
||||
class I18nSettings:
|
||||
"""
|
||||
Class allowing persistence of our settings!
|
||||
|
||||
@@ -24,7 +24,7 @@ import pickle
|
||||
import re
|
||||
|
||||
|
||||
class SpellChecker():
|
||||
class SpellChecker:
|
||||
"""
|
||||
A basic spell checker.
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user