Changeset View
Changeset View
Standalone View
Standalone View
source/blender/makesrna/intern/rna_space.c
- This file is larger than 256 KB, so syntax highlighting is disabled by default.
| Show First 20 Lines • Show All 524 Lines • ▼ Show 20 Lines | static const EnumPropertyItem rna_enum_curve_display_handle_items[] = { | ||||
| {CURVE_HANDLE_NONE, "NONE", 0, "None", ""}, | {CURVE_HANDLE_NONE, "NONE", 0, "None", ""}, | ||||
| {CURVE_HANDLE_SELECTED, "SELECTED", 0, "Selected", ""}, | {CURVE_HANDLE_SELECTED, "SELECTED", 0, "Selected", ""}, | ||||
| {CURVE_HANDLE_ALL, "ALL", 0, "All", ""}, | {CURVE_HANDLE_ALL, "ALL", 0, "All", ""}, | ||||
| {0, NULL, 0, NULL, NULL}, | {0, NULL, 0, NULL, NULL}, | ||||
| }; | }; | ||||
| #ifdef RNA_RUNTIME | #ifdef RNA_RUNTIME | ||||
| # include "AS_asset_representation.h" | |||||
| # include "DNA_anim_types.h" | # include "DNA_anim_types.h" | ||||
| # include "DNA_asset_types.h" | # include "DNA_asset_types.h" | ||||
| # include "DNA_scene_types.h" | # include "DNA_scene_types.h" | ||||
| # include "DNA_screen_types.h" | # include "DNA_screen_types.h" | ||||
| # include "DNA_userdef_types.h" | # include "DNA_userdef_types.h" | ||||
| # include "BLI_path_util.h" | # include "BLI_path_util.h" | ||||
| # include "BLI_string.h" | # include "BLI_string.h" | ||||
| # include "BKE_anim_data.h" | # include "BKE_anim_data.h" | ||||
| # include "BKE_asset.h" | |||||
| # include "BKE_brush.h" | # include "BKE_brush.h" | ||||
| # include "BKE_colortools.h" | # include "BKE_colortools.h" | ||||
| # include "BKE_context.h" | # include "BKE_context.h" | ||||
| # include "BKE_global.h" | # include "BKE_global.h" | ||||
| # include "BKE_icons.h" | # include "BKE_icons.h" | ||||
| # include "BKE_idprop.h" | # include "BKE_idprop.h" | ||||
| # include "BKE_layer.h" | # include "BKE_layer.h" | ||||
| # include "BKE_nla.h" | # include "BKE_nla.h" | ||||
| ▲ Show 20 Lines • Show All 2,209 Lines • ▼ Show 20 Lines | |||||
| static PointerRNA rna_FileBrowser_FileSelectEntry_asset_data_get(PointerRNA *ptr) | static PointerRNA rna_FileBrowser_FileSelectEntry_asset_data_get(PointerRNA *ptr) | ||||
| { | { | ||||
| const FileDirEntry *entry = ptr->data; | const FileDirEntry *entry = ptr->data; | ||||
| if (!entry->asset) { | if (!entry->asset) { | ||||
| return PointerRNA_NULL; | return PointerRNA_NULL; | ||||
| } | } | ||||
| AssetMetaData *asset_data = BKE_asset_representation_metadata_get(entry->asset); | AssetMetaData *asset_data = AS_asset_representation_metadata_get(entry->asset); | ||||
| /* Note that the owning ID of the RNA pointer (`ptr->owner_id`) has to be set carefully: | /* Note that the owning ID of the RNA pointer (`ptr->owner_id`) has to be set carefully: | ||||
| * Local IDs (`entry->id`) own their asset metadata themselves. Asset metadata from other blend | * Local IDs (`entry->id`) own their asset metadata themselves. Asset metadata from other blend | ||||
| * files are owned by the file browser (`entry`). Only if this is set correctly, we can tell from | * files are owned by the file browser (`entry`). Only if this is set correctly, we can tell from | ||||
| * the metadata RNA pointer if the metadata is stored locally and can thus be edited or not. */ | * the metadata RNA pointer if the metadata is stored locally and can thus be edited or not. */ | ||||
| if (BKE_asset_representation_is_local_id(entry->asset)) { | if (AS_asset_representation_is_local_id(entry->asset)) { | ||||
| PointerRNA id_ptr; | PointerRNA id_ptr; | ||||
| RNA_id_pointer_create(entry->id, &id_ptr); | RNA_id_pointer_create(entry->id, &id_ptr); | ||||
| return rna_pointer_inherit_refine(&id_ptr, &RNA_AssetMetaData, asset_data); | return rna_pointer_inherit_refine(&id_ptr, &RNA_AssetMetaData, asset_data); | ||||
| } | } | ||||
| return rna_pointer_inherit_refine(ptr, &RNA_AssetMetaData, asset_data); | return rna_pointer_inherit_refine(ptr, &RNA_AssetMetaData, asset_data); | ||||
| } | } | ||||
| ▲ Show 20 Lines • Show All 5,310 Lines • Show Last 20 Lines | |||||