[Bf-blender-cvs] [37fc52cbc64] blender2.8: UI: Minor tweaks on User Preferences header.

Pablo Vazquez noreply at git.blender.org
Fri Nov 2 03:16:01 CET 2018


Commit: 37fc52cbc64f9bd00e619cd33daea49b5d51cce0
Author: Pablo Vazquez
Date:   Fri Nov 2 03:15:38 2018 +0100
Branches: blender2.8
https://developer.blender.org/rB37fc52cbc64f9bd00e619cd33daea49b5d51cce0

UI: Minor tweaks on User Preferences header.

* Move Save User Preferences to the right (matches file browser and quit prompt).
* Icons for Import/Export keyconfig
* Match order of install/reset of Themes section
* Rename "Install MatCap/HDRI" to "Add MatCap/HDRI"

===================================================================

M	release/scripts/startup/bl_ui/space_userpref.py

===================================================================

diff --git a/release/scripts/startup/bl_ui/space_userpref.py b/release/scripts/startup/bl_ui/space_userpref.py
index 88e173724ca..8a9bd133eb0 100644
--- a/release/scripts/startup/bl_ui/space_userpref.py
+++ b/release/scripts/startup/bl_ui/space_userpref.py
@@ -39,25 +39,25 @@ class USERPREF_HT_header(Header):
 
         userpref = context.user_preferences
 
-        layout.operator_context = 'EXEC_AREA'
-        layout.operator("wm.save_userpref")
-
-        layout.operator_context = 'INVOKE_DEFAULT'
-
         if userpref.active_section == 'INPUT':
-            layout.operator("wm.keyconfig_import")
-            layout.operator("wm.keyconfig_export")
+            layout.operator("wm.keyconfig_import", icon='IMPORT')
+            layout.operator("wm.keyconfig_export", icon='EXPORT')
         elif userpref.active_section == 'ADDONS':
             layout.operator("wm.addon_install", icon='FILEBROWSER')
             layout.operator("wm.addon_refresh", icon='FILE_REFRESH')
             layout.menu("USERPREF_MT_addons_online_resources")
         elif userpref.active_section == 'LIGHTS':
-            layout.operator('wm.studiolight_install', text="Install MatCap").orientation = 'MATCAP'
-            layout.operator('wm.studiolight_install', text="Install World HDRI").orientation = 'WORLD'
-            layout.operator('wm.studiolight_install', text="Install Camera HDRI").orientation = 'CAMERA'
+            layout.operator('wm.studiolight_install', text="Add MatCap").orientation = 'MATCAP'
+            layout.operator('wm.studiolight_install', text="Add World HDRI").orientation = 'WORLD'
+            layout.operator('wm.studiolight_install', text="Add Camera HDRI").orientation = 'CAMERA'
         elif userpref.active_section == 'THEMES':
-            layout.operator("ui.reset_default_theme")
-            layout.operator("wm.theme_install")
+            layout.operator("wm.theme_install", icon='FILEBROWSER')
+            layout.operator("ui.reset_default_theme", icon='LOOP_BACK')
+
+        layout.separator_spacer()
+
+        layout.operator_context = 'EXEC_AREA'
+        layout.operator("wm.save_userpref")
 
 
 class USERPREF_PT_tabs(Panel):



More information about the Bf-blender-cvs mailing list