Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'release/scripts/startup/bl_ui')
-rw-r--r--release/scripts/startup/bl_ui/space_topbar.py9
-rw-r--r--release/scripts/startup/bl_ui/space_userpref.py11
2 files changed, 18 insertions, 2 deletions
diff --git a/release/scripts/startup/bl_ui/space_topbar.py b/release/scripts/startup/bl_ui/space_topbar.py
index b1ddd2c611d..3320e1e24a7 100644
--- a/release/scripts/startup/bl_ui/space_topbar.py
+++ b/release/scripts/startup/bl_ui/space_topbar.py
@@ -411,9 +411,16 @@ class TOPBAR_MT_file_defaults(Menu):
app_template, has_ext=False))
layout.operator("wm.save_homefile")
- props = layout.operator("wm.read_factory_settings")
if app_template:
+ display_name = bpy.path.display_name(iface_(app_template))
+ props = layout.operator("wm.read_factory_settings", text="Load Factory Blender Settings")
props.app_template = app_template
+ props = layout.operator("wm.read_factory_settings", text="Load Factory %s Settings" % display_name)
+ props.app_template = app_template
+ props.use_factory_startup_app_template_only = True
+ del display_name
+ else:
+ layout.operator("wm.read_factory_settings")
# Include technical operators here which would otherwise have no way for users to access.
diff --git a/release/scripts/startup/bl_ui/space_userpref.py b/release/scripts/startup/bl_ui/space_userpref.py
index 441babefd60..a9736feb057 100644
--- a/release/scripts/startup/bl_ui/space_userpref.py
+++ b/release/scripts/startup/bl_ui/space_userpref.py
@@ -109,7 +109,16 @@ class USERPREF_MT_save_load(Menu):
sub_revert.operator("wm.read_userpref", text="Revert to Saved Preferences")
layout.operator_context = 'INVOKE_AREA'
- layout.operator("wm.read_factory_userpref", text="Load Factory Preferences")
+
+ app_template = prefs.app_template
+ if app_template:
+ display_name = bpy.path.display_name(iface_(app_template))
+ layout.operator("wm.read_factory_userpref", text="Load Factory Blender Preferences")
+ props = layout.operator("wm.read_factory_userpref", text="Load Factory %s Preferences" % display_name)
+ props.use_factory_startup_app_template_only = True
+ del display_name
+ else:
+ layout.operator("wm.read_factory_userpref", text="Load Factory Preferences")
class USERPREF_PT_save_preferences(Panel):