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:
authorSybren A. Stüvel <sybren@blender.org>2019-08-15 11:21:04 +0300
committerSybren A. Stüvel <sybren@blender.org>2019-08-16 16:02:09 +0300
commit078d02f55743cd34c51c4dd7ca710b22441a12da (patch)
treed615010391448947904fb44d47e7defb666709ef /release/scripts/startup/bl_operators/userpref.py
parentecc3b033a7d2bc71f3c75cd8152a647d18457ba1 (diff)
User Preferences: Added "Enabled add-ons only" preference
This checkbox replaces the "Disabled" and "Enabled" entries in the filter drop-down. As a result, it now takes a single click to limit the shown entries to enabled add-ons only. This is also an actual flag in the preferences, and thus its state is saved between runs on Blender (in contrast to the filter, which is always reset to "All"). Reviewed by: brecht, billreynish
Diffstat (limited to 'release/scripts/startup/bl_operators/userpref.py')
-rw-r--r--release/scripts/startup/bl_operators/userpref.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/release/scripts/startup/bl_operators/userpref.py b/release/scripts/startup/bl_operators/userpref.py
index 034aa9fff6c..6ec6855296c 100644
--- a/release/scripts/startup/bl_operators/userpref.py
+++ b/release/scripts/startup/bl_operators/userpref.py
@@ -667,6 +667,7 @@ class PREFERENCES_OT_addon_install(Operator):
info = addon_utils.module_bl_info(mod)
# show the newly installed addon.
+ context.preferences.view.show_addons_enabled_only = False
context.window_manager.addon_filter = 'All'
context.window_manager.addon_search = info["name"]
break
@@ -796,6 +797,7 @@ class PREFERENCES_OT_addon_show(Operator):
info["show_expanded"] = True
context.preferences.active_section = 'ADDONS'
+ context.preferences.view.show_addons_enabled_only = False
context.window_manager.addon_filter = 'All'
context.window_manager.addon_search = info["name"]
bpy.ops.screen.userpref_show('INVOKE_DEFAULT')