2007-08-25 Don Allingham <don@gramps-project.org>

* src/Config/_GrampsConfigKeys.py; Add EXPORT_NO_PRIVATE and
	EXPORT_RESTRICT
	* src/Config/_GrampsIniKeys.py: properly handle False values
	* src/ExportOptions.py: replace deprecated OptionMenu with ComboBox



svn: r8867
This commit is contained in:
Don Allingham
2007-08-25 15:34:13 +00:00
parent 39eee89295
commit 342f60a78f
4 changed files with 36 additions and 9 deletions

View File

@@ -46,7 +46,8 @@ Then add the variable to the default_value map at the end of the
file, and provide a default value according to the value's type.
"""
EXPORT_NO_PRIVATE = ('export', 'no-private', 0)
EXPORT_RESTRICT = ('export', 'restrict-living', 0)
DEFAULT_SOURCE = ('preferences', 'default-source', 0)
RELATION_SHADE = ('preferences', 'relation-shade', 0)
ONLINE_MAPS = ('preferences', 'online-maps', 0)
@@ -250,4 +251,6 @@ default_value = {
REPO_REF_HEIGHT : 450,
REPO_REF_WIDTH : 600,
OWNER_WARN : False,
EXPORT_NO_PRIVATE : True,
EXPORT_RESTRICT : True,
}

View File

@@ -210,7 +210,7 @@ def get(key):
val = get_int(key)
else:
val = get_string(key)
if not val:
if val == None:
val = default_value[key]
return val
@@ -219,7 +219,7 @@ def get_bool(key):
val = client.get_bool(key)
except KeyError:
val = None
if val in (True,False):
if val in (True, False):
return val
elif key in default_value:
return default_value[key]