[orca] Move the braille EOL indicator and cell delimiter strings to object_properties.py



commit 9f43823b199fcc4810ed79db0bb8c28d6fcf1621
Author: Joanmarie Diggs <jdiggs igalia com>
Date:   Tue Jun 3 18:45:05 2014 -0400

    Move the braille EOL indicator and cell delimiter strings to object_properties.py

 src/orca/formatting.py                             |    4 ++--
 src/orca/generator.py                              |    3 ++-
 src/orca/object_properties.py                      |    3 +++
 src/orca/scripts/apps/soffice/braille_generator.py |   11 +++++------
 src/orca/settings.py                               |    3 ---
 5 files changed, 12 insertions(+), 12 deletions(-)
---
diff --git a/src/orca/formatting.py b/src/orca/formatting.py
index 08604aa..85a6500 100644
--- a/src/orca/formatting.py
+++ b/src/orca/formatting.py
@@ -29,8 +29,8 @@ import copy
 
 import pyatspi
 
-from . import settings
 from . import object_properties
+from . import settings
 
 # pylint: disable-msg=C0301
 
@@ -66,7 +66,7 @@ formatting = {
             'groupindex': object_properties.GROUP_INDEX_SPEECH,
         },
         'braille': {
-            'eol': settings.brailleEOLIndicator,
+            'eol': object_properties.EOL_INDICATOR_BRAILLE,
             'required': object_properties.STATE_REQUIRED_BRAILLE,
             'readonly': object_properties.STATE_READ_ONLY_BRAILLE,
             'insensitive': object_properties.STATE_INSENSITIVE_BRAILLE,
diff --git a/src/orca/generator.py b/src/orca/generator.py
index d109213..7254e4b 100644
--- a/src/orca/generator.py
+++ b/src/orca/generator.py
@@ -34,6 +34,7 @@ import pyatspi
 from . import braille
 from . import debug
 from . import messages
+from . import object_properties
 from . import settings
 
 from .orca_i18n import _         # for gettext support
@@ -913,7 +914,7 @@ class Generator:
                         cellResult = self._generateRealTableCell(cell, **args)
                         if cellResult and result and self._mode == 'braille':
                             result.append(braille.Region(
-                                    settings.brailleTableCellDelimiter))
+                                object_properties.TABLE_CELL_DELIMITER_BRAILLE))
                         result.extend(cellResult)
             else:
                 result.extend(self._generateRealTableCell(obj, **args))
diff --git a/src/orca/object_properties.py b/src/orca/object_properties.py
index a8b4662..5d24faa 100644
--- a/src/orca/object_properties.py
+++ b/src/orca/object_properties.py
@@ -175,3 +175,6 @@ CHECK_BOX_INDICATORS_BRAILLE     = ["< >", "<x>", "<->"]
 EXPANSION_INDICATORS_BRAILLE     = [STATE_COLLAPSED, STATE_EXPANDED]
 RADIO_BUTTON_INDICATORS_BRAILLE  = ["& y", "&=y"]
 TOGGLE_BUTTON_INDICATORS_BRAILLE = ["& y", "&=y"]
+
+TABLE_CELL_DELIMITER_BRAILLE = " "
+EOL_INDICATOR_BRAILLE = " $l"
diff --git a/src/orca/scripts/apps/soffice/braille_generator.py 
b/src/orca/scripts/apps/soffice/braille_generator.py
index 7622493..34fddc2 100644
--- a/src/orca/scripts/apps/soffice/braille_generator.py
+++ b/src/orca/scripts/apps/soffice/braille_generator.py
@@ -29,6 +29,7 @@ import pyatspi
 
 import orca.braille as braille
 import orca.braille_generator as braille_generator
+import orca.object_properties as object_properties
 import orca.settings_manager as settings_manager
 
 _settingsManager = settings_manager.getManager()
@@ -123,9 +124,8 @@ class BrailleGenerator(braille_generator.BrailleGenerator):
                 for child in obj:
                     cellResult = self._generateRealTableCell(child, **args)
                     if cellResult and result and self._mode == 'braille':
-                        delimiter = _settingsManager.getSetting(
-                            'brailleTableCellDelimiter')
-                        result.append(braille.Region(delimiter))
+                        result.append(braille.Region(
+                            object_properties.TABLE_CELL_DELIMITER_BRAILLE))
                     result.extend(cellResult)
         return result
 
@@ -178,9 +178,8 @@ class BrailleGenerator(braille_generator.BrailleGenerator):
                                                                      **args)
                             if cellResult and result \
                                and self._mode == 'braille':
-                                delimiter = _settingsManager.getSetting(
-                                    'brailleTableCellDelimiter')
-                                result.append(braille.Region(delimiter))
+                                result.append(braille.Region(
+                                    object_properties.TABLE_CELL_DELIMITER_BRAILLE))
                             result.extend(cellResult)
                 else:
                     result.extend(self._generateRealTableCell(obj, **args))
diff --git a/src/orca/settings.py b/src/orca/settings.py
index 93c56cc..33fa71e 100644
--- a/src/orca/settings.py
+++ b/src/orca/settings.py
@@ -59,7 +59,6 @@ userCustomizableSettings = [
     "enableBraille",
     "enableBrailleContext",
     "disableBrailleEOL",
-    "brailleEOLIndicator",
     "brailleVerbosityLevel",
     "brailleRolenameStyle",
     "brailleSelectorIndicator",
@@ -221,8 +220,6 @@ flashIsPersistent              = False
 enableContractedBraille        = False
 brailleContractionTable        = ''
 disableBrailleEOL              = False
-brailleEOLIndicator            = " $l"
-brailleTableCellDelimiter      = " "
 brailleRolenameStyle           = BRAILLE_ROLENAME_STYLE_LONG
 brailleSelectorIndicator       = BRAILLE_UNDERLINE_BOTH
 brailleLinkIndicator           = BRAILLE_UNDERLINE_BOTH


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]