diff options
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/interface/interface_handlers.c | 3 | ||||
-rw-r--r-- | source/blender/editors/interface/interface_regions.c | 6 |
2 files changed, 9 insertions, 0 deletions
diff --git a/source/blender/editors/interface/interface_handlers.c b/source/blender/editors/interface/interface_handlers.c index 9818a593174..d3c889713fb 100644 --- a/source/blender/editors/interface/interface_handlers.c +++ b/source/blender/editors/interface/interface_handlers.c @@ -2491,6 +2491,9 @@ static void ui_textedit_end(bContext *C, uiBut *but, uiHandleButtonData *data) (ui_searchbox_find_index(data->searchbox, but->editstr) == -1)) { data->cancel = true; + + /* ensure menu (popup) too is closed! */ + data->escapecancel = true; } } diff --git a/source/blender/editors/interface/interface_regions.c b/source/blender/editors/interface/interface_regions.c index 291a9eb984f..9b450b8fdf4 100644 --- a/source/blender/editors/interface/interface_regions.c +++ b/source/blender/editors/interface/interface_regions.c @@ -888,6 +888,12 @@ bool ui_searchbox_apply(uiBut *but, ARegion *ar) return true; } + else if (but->type == SEARCH_MENU_UNLINK) { + /* It is valid for _UNLINK flavor to have no active element (it's a valid way to unlink). */ + but->editstr[0] = '\0'; + + return true; + } else { return false; } |