Changeset View
Changeset View
Standalone View
Standalone View
source/blender/blenkernel/intern/workspace.c
| Show First 20 Lines • Show All 529 Lines • ▼ Show 20 Lines | if (view_layer) { | ||||
| BLI_assert(BKE_object_is_in_editmode(obedit)); | BLI_assert(BKE_object_is_in_editmode(obedit)); | ||||
| return obedit; | return obedit; | ||||
| } | } | ||||
| } | } | ||||
| } | } | ||||
| return NULL; | return NULL; | ||||
| } | } | ||||
| bool BKE_workspace_ui_tags_check( | |||||
| const WorkSpace *workspace, const char *ui_tag) | |||||
| { | |||||
| if ((*ui_tag == '\0') || | |||||
| ((workspace->flags & WORKSPACE_USE_UI_TAGS) == 0)) | |||||
| { | |||||
| return true; | |||||
| } | |||||
| else { | |||||
| /* we could use hash lookup, for now this list is highly under < ~16 items. */ | |||||
| return BLI_findstring(&workspace->ui_tags, ui_tag, offsetof(WorkSpaceUITag, name)) != NULL; | |||||
| } | |||||
| } | |||||