diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-03-16 20:23:51 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2010-03-16 20:23:51 +0300 |
commit | 74fc6a07c028fbe7c3863fcddb6683e94470a445 (patch) | |
tree | 9be162df4348ef2fb3ed08b908f5ca1315a16b60 /source/blender/editors | |
parent | 63a368ceaa747271d417c98c607a61374e3cfb68 (diff) |
library data selector, respect hide dot data, unless the user enters a '.'
(commit 27435 by Campbell from render25 branch)
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/interface/interface_templates.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/source/blender/editors/interface/interface_templates.c b/source/blender/editors/interface/interface_templates.c index efd741a12f6..b7761da76c0 100644 --- a/source/blender/editors/interface/interface_templates.c +++ b/source/blender/editors/interface/interface_templates.c @@ -31,6 +31,7 @@ #include "DNA_color_types.h" #include "DNA_scene_types.h" #include "DNA_screen_types.h" +#include "DNA_userdef_types.h" #include "BLI_string.h" @@ -164,9 +165,15 @@ static void id_search_cb(const bContext *C, void *arg_template, char *str, uiSea /* ID listbase */ for(id= lb->first; id; id= id->next) { if(!((flag & PROP_ID_SELF_CHECK) && id == id_from)) { + + /* hide dot-datablocks */ + if(U.uiflag & USER_HIDE_DOT) + if ((id->name[2]=='.') && (str[0] != '.')) + continue; + if(BLI_strcasestr(id->name+2, str)) { iconid= ui_id_icon_get((bContext*)C, id, 0); - + if(!uiSearchItemAdd(items, id->name+2, id, iconid)) break; } |