From 19d233a3a269d2dbd403d17d660d05f07c180ab9 Mon Sep 17 00:00:00 2001 From: Harley Acheson Date: Wed, 27 Sep 2023 15:07:08 -0700 Subject: [PATCH] Updating, rebasing, incorporating changes from Pablo --- scripts/startup/bl_operators/wm.py | 63 ++++++++++++++++-------------- 1 file changed, 33 insertions(+), 30 deletions(-) diff --git a/scripts/startup/bl_operators/wm.py b/scripts/startup/bl_operators/wm.py index 2ec4dcc5d74..6612c1aa89e 100644 --- a/scripts/startup/bl_operators/wm.py +++ b/scripts/startup/bl_operators/wm.py @@ -3183,14 +3183,37 @@ class WM_MT_splash_quick_setup(Menu): layout = self.layout layout.operator_context = 'EXEC_DEFAULT' - layout.label(text="Quick Setup") + old_version = bpy.types.PREFERENCES_OT_copy_prev.previous_version() + can_import = bpy.types.PREFERENCES_OT_copy_prev.poll(context) and old_version - split = layout.split(factor=0.14) # Left margin. + if can_import: + layout.label(text="Import Existing Settings") + split = layout.split(factor=0.20) # Left margin. + split.label() + + split = split.split(factor=0.73) # Content width. + col = split.column() + col.operator( + "preferences.copy_prev", + text=iface_( + "Load Blender %d.%d Settings", + "Operator") % + old_version, icon='DUPLICATE', + translate=False) + col.operator( + "wm.url_open", text="See What's New...", icon='URL' + ).url = "https://wiki.blender.org/wiki/Reference/Release_Notes/4.0" + col.separator(factor=2.0) + + if can_import: + layout.label(text="Create New Settings") + else: + layout.label(text="Quick Setup") + + split = layout.split(factor=0.20) # Left margin. split.label() split = split.split(factor=0.73) # Content width. - col = split.column() - col.use_property_split = True col.use_property_decorate = False @@ -3219,42 +3242,22 @@ class WM_MT_splash_quick_setup(Menu): if has_spacebar_action: col.row().prop(kc_prefs, "spacebar_action", text="Spacebar") - col.separator() - # Themes. + col.separator() sub = col.column(heading="Theme") label = bpy.types.USERPREF_MT_interface_theme_presets.bl_label if label == "Presets": label = "Blender Dark" sub.menu("USERPREF_MT_interface_theme_presets", text=label) - # Keep height constant. - if not has_select_mouse: - col.label() - if not has_spacebar_action: - col.label() - - layout.separator(factor=2.0) - - # Save settings buttons. - sub = layout.row() - - old_version = bpy.types.PREFERENCES_OT_copy_prev.previous_version() - if bpy.types.PREFERENCES_OT_copy_prev.poll(context) and old_version: - sub.operator( - "preferences.copy_prev", - text=iface_( - "Load %d.%d Settings", - "Operator") % - old_version, - translate=False) - sub.operator("wm.save_userpref", text="Save New Settings") + if can_import: + sub.label() + sub.operator("wm.save_userpref", text="Save New Settings", icon='CHECKMARK') else: sub.label() - sub.label() - sub.operator("wm.save_userpref", text="Next") + sub.operator("wm.save_userpref", text="Continue") - layout.separator(factor=2.4) + layout.separator(factor=2.0) class WM_MT_splash(Menu): -- 2.30.2