diff options
author | Matt Ebb <matt@mke3.net> | 2010-03-30 08:27:13 +0400 |
---|---|---|
committer | Matt Ebb <matt@mke3.net> | 2010-03-30 08:27:13 +0400 |
commit | 1f8cd5707342c6f490909baac2ca941a9651f381 (patch) | |
tree | 9e2f9dbe99a21d9ee32bea21bcd9301296812987 /release | |
parent | f20427ffbee1a1b1fdfcc070975952171bfd2e66 (diff) |
Fix [#20115] Some theme settings are not saved
Theme colours were getting overwritten on startup with defaults (as in 2.4
system). Changed this to allow changing the default theme, and added a
'Reset to defaults' operator in user prefs. Perhaps next step to look into the
py presets system for themes too (nice and easy to share).
If you're using a custom B.blend you may get some strange theme colours on
startup if they weren't saved properly before. 'Reset to default' button in theme
preferences should fix it back to defaults.
Diffstat (limited to 'release')
-rw-r--r-- | release/scripts/ui/space_userpref.py | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/release/scripts/ui/space_userpref.py b/release/scripts/ui/space_userpref.py index 4ee1f119f53..da4247078e3 100644 --- a/release/scripts/ui/space_userpref.py +++ b/release/scripts/ui/space_userpref.py @@ -164,17 +164,19 @@ class USERPREF_HT_header(bpy.types.Header): layout.operator_context = 'EXEC_AREA' layout.operator("wm.save_homefile", text="Save As Default") - + + layout.operator_context = 'INVOKE_DEFAULT' + if userpref.active_section == 'INPUT': - layout.operator_context = 'INVOKE_DEFAULT' - op = layout.operator("wm.keyconfig_export", "Export Key Configuration...") + op = layout.operator("wm.keyconfig_export") op.path = "keymap.py" - op = layout.operator("wm.keyconfig_import", "Import Key Configuration...") + op = layout.operator("wm.keyconfig_import") op.path = "keymap.py" elif userpref.active_section == 'ADDONS': - layout.operator_context = 'INVOKE_DEFAULT' - op = layout.operator("wm.addon_install", "Install Add-On...") + op = layout.operator("wm.addon_install") op.path = "*.py" + elif userpref.active_section == 'THEMES': + op = layout.operator("ui.reset_default_theme") class USERPREF_PT_tabs(bpy.types.Panel): @@ -1593,7 +1595,7 @@ class WM_OT_addon_disable(bpy.types.Operator): class WM_OT_addon_install(bpy.types.Operator): "Install an addon" bl_idname = "wm.addon_install" - bl_label = "Install Add-On" + bl_label = "Install Add-On..." module = StringProperty(name="Module", description="Module name of the addon to disable") |