diff options
author | Hans Goudey <h.goudey@me.com> | 2020-11-17 18:17:00 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2020-11-17 18:17:00 +0300 |
commit | d952d1792ab167b2b3cc9fdde26d70a5ec9641b0 (patch) | |
tree | 0f902d2a7df4adf930fc4e6596205b32a1e5005d /source | |
parent | fd78f8699e034d52d5d0921a7b4c722f68b213cc (diff) | |
parent | cc0b8cb3599f50012bd90a0c41462290007f3328 (diff) |
Merge branch 'blender-v2.91-release'
Diffstat (limited to 'source')
6 files changed, 18 insertions, 1 deletions
diff --git a/source/blender/blenkernel/BKE_screen.h b/source/blender/blenkernel/BKE_screen.h index 8e370ed27c5..68c341692c2 100644 --- a/source/blender/blenkernel/BKE_screen.h +++ b/source/blender/blenkernel/BKE_screen.h @@ -289,6 +289,8 @@ enum { PANEL_TYPE_INSTANCED = (1 << 4), /** Draw panel like a box widget. */ PANEL_TYPE_DRAW_BOX = (1 << 6), + /** Don't search panels with this type during property search. */ + PANEL_TYPE_NO_SEARCH = (1 << 7), }; /* uilist types */ diff --git a/source/blender/draw/engines/eevee/shaders/closure_lit_lib.glsl b/source/blender/draw/engines/eevee/shaders/closure_lit_lib.glsl index 613b48ff9b8..30ce60f3ec0 100644 --- a/source/blender/draw/engines/eevee/shaders/closure_lit_lib.glsl +++ b/source/blender/draw/engines/eevee/shaders/closure_lit_lib.glsl @@ -464,6 +464,9 @@ void CLOSURE_NAME(vec3 N float btdf = get_btdf_lut(NV, roughness, ior); out_refr += refr_accum.rgb * btdf; + + /* Global toggle for lightprobe baking. */ + out_refr *= float(specToggle); # endif # ifdef CLOSURE_CLEARCOAT diff --git a/source/blender/editors/interface/interface_layout.c b/source/blender/editors/interface/interface_layout.c index df7fd3dee0e..6267681bb4d 100644 --- a/source/blender/editors/interface/interface_layout.c +++ b/source/blender/editors/interface/interface_layout.c @@ -5169,6 +5169,10 @@ bool UI_block_apply_search_filter(uiBlock *block, const char *search_filter) return false; } + if (block->panel && block->panel->type && block->panel->type->flag & PANEL_TYPE_NO_SEARCH) { + return false; + } + const bool panel_label_matches = block_search_panel_label_matches(block, search_filter); const bool has_result = (panel_label_matches) ? diff --git a/source/blender/editors/screen/area.c b/source/blender/editors/screen/area.c index 690d6c8055a..73e11328af6 100644 --- a/source/blender/editors/screen/area.c +++ b/source/blender/editors/screen/area.c @@ -3089,6 +3089,11 @@ static bool panel_property_search(const bContext *C, uiBlock *block = UI_block_begin(C, region, panel_type->idname, UI_EMBOSS); UI_block_set_search_only(block, true); + /* Skip panels that give meaningless search results. */ + if (panel_type->flag & PANEL_TYPE_NO_SEARCH) { + return false; + } + if (panel == NULL) { bool open; /* Dummy variable. */ panel = UI_panel_begin(region, ®ion->panels, block, panel_type, panel, &open); diff --git a/source/blender/editors/space_buttons/buttons_context.c b/source/blender/editors/space_buttons/buttons_context.c index 922ef8dde99..553782e2c0f 100644 --- a/source/blender/editors/space_buttons/buttons_context.c +++ b/source/blender/editors/space_buttons/buttons_context.c @@ -1216,7 +1216,7 @@ void buttons_context_register(ARegionType *art) strcpy(pt->translation_context, BLT_I18NCONTEXT_DEFAULT_BPYRNA); pt->poll = buttons_panel_context_poll; pt->draw = buttons_panel_context_draw; - pt->flag = PANEL_TYPE_NO_HEADER; + pt->flag = PANEL_TYPE_NO_HEADER | PANEL_TYPE_NO_SEARCH; BLI_addtail(&art->paneltypes, pt); } diff --git a/source/blender/editors/space_buttons/space_buttons.c b/source/blender/editors/space_buttons/space_buttons.c index 3c4a1fee69c..e50ca2ec92b 100644 --- a/source/blender/editors/space_buttons/space_buttons.c +++ b/source/blender/editors/space_buttons/space_buttons.c @@ -402,6 +402,9 @@ static void property_search_all_tabs(const bContext *C, ScrArea *area_original = CTX_wm_area(C); ScrArea area_copy = *area_original; ARegion *region_copy = BKE_area_region_copy(area_copy.type, region_original); + /* Set the region visible field. Otherwise some layout code thinks we're drawing in a popup. + * This likely isn't necessary, but it's nice to emulate a "real" region where possible. */ + region_copy->visible = true; CTX_wm_area_set((bContext *)C, &area_copy); CTX_wm_region_set((bContext *)C, region_copy); |