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 3,000 Lines • ▼ Show 20 Lines | static const EnumPropertyItem display_mode_items[] = { | ||||
| {SO_ID_ORPHANS, | {SO_ID_ORPHANS, | ||||
| "ORPHAN_DATA", | "ORPHAN_DATA", | ||||
| ICON_ORPHAN_DATA, | ICON_ORPHAN_DATA, | ||||
| "Orphan Data", | "Orphan Data", | ||||
| "Display data-blocks which are unused and/or will be lost when the file is reloaded"}, | "Display data-blocks which are unused and/or will be lost when the file is reloaded"}, | ||||
| {0, NULL, 0, NULL, NULL}, | {0, NULL, 0, NULL, NULL}, | ||||
| }; | }; | ||||
| static const EnumPropertyItem sort_method_items[] = { | |||||
| {SO_SORT_CUSTOM, "CUSTOM", 0, "Custom", "Sort objects and collections manually"}, | |||||
Severin: Maybe "Custom" is a better name? Also, please use the same name for the DNA define. Better not… | |||||
| {SO_SORT_ALPHA, "ALPHA", 0, "Name", "Sort objects and collections by name alphabetically"}, | |||||
| {SO_SORT_TYPE, "TYPE", 0, "Type", "Sort objects by type"}, | |||||
| {0, NULL, 0, NULL, NULL}, | |||||
| }; | |||||
| static const EnumPropertyItem filter_state_items[] = { | static const EnumPropertyItem filter_state_items[] = { | ||||
| {SO_FILTER_OB_ALL, "ALL", 0, "All", "Show all objects in the view layer"}, | {SO_FILTER_OB_ALL, "ALL", 0, "All", "Show all objects in the view layer"}, | ||||
| {SO_FILTER_OB_VISIBLE, "VISIBLE", 0, "Visible", "Show visible objects"}, | {SO_FILTER_OB_VISIBLE, "VISIBLE", 0, "Visible", "Show visible objects"}, | ||||
| {SO_FILTER_OB_HIDDEN, "HIDDEN", 0, "Hidden", "Show hidden objects"}, | {SO_FILTER_OB_HIDDEN, "HIDDEN", 0, "Hidden", "Show hidden objects"}, | ||||
| {SO_FILTER_OB_SELECTED, "SELECTED", 0, "Selected", "Show selected objects"}, | {SO_FILTER_OB_SELECTED, "SELECTED", 0, "Selected", "Show selected objects"}, | ||||
| {SO_FILTER_OB_ACTIVE, "ACTIVE", 0, "Active", "Show only the active object"}, | {SO_FILTER_OB_ACTIVE, "ACTIVE", 0, "Active", "Show only the active object"}, | ||||
| {0, NULL, 0, NULL, NULL}, | {0, NULL, 0, NULL, NULL}, | ||||
| }; | }; | ||||
| Show All 21 Lines | static void rna_def_space_outliner(BlenderRNA *brna) | ||||
| RNA_def_property_update(prop, NC_SPACE | ND_SPACE_OUTLINER, NULL); | RNA_def_property_update(prop, NC_SPACE | ND_SPACE_OUTLINER, NULL); | ||||
| prop = RNA_def_property(srna, "use_filter_complete", PROP_BOOLEAN, PROP_NONE); | prop = RNA_def_property(srna, "use_filter_complete", PROP_BOOLEAN, PROP_NONE); | ||||
| RNA_def_property_boolean_sdna(prop, NULL, "search_flags", SO_FIND_COMPLETE); | RNA_def_property_boolean_sdna(prop, NULL, "search_flags", SO_FIND_COMPLETE); | ||||
| RNA_def_property_ui_text( | RNA_def_property_ui_text( | ||||
| prop, "Complete Matches Only", "Only use complete matches of search string"); | prop, "Complete Matches Only", "Only use complete matches of search string"); | ||||
| RNA_def_property_update(prop, NC_SPACE | ND_SPACE_OUTLINER, NULL); | RNA_def_property_update(prop, NC_SPACE | ND_SPACE_OUTLINER, NULL); | ||||
| prop = RNA_def_property(srna, "use_sort_alpha", PROP_BOOLEAN, PROP_NONE); | prop = RNA_def_property(srna, "sort_method", PROP_ENUM, PROP_NONE); | ||||
| RNA_def_property_boolean_negative_sdna(prop, NULL, "flag", SO_SKIP_SORT_ALPHA); | RNA_def_property_enum_sdna(prop, NULL, "sort_method"); | ||||
| RNA_def_property_ui_text(prop, "Sort Alphabetically", ""); | RNA_def_property_enum_items(prop, sort_method_items); | ||||
| RNA_def_property_ui_text(prop, "Sort Type", "Outliner sort method"); | |||||
| RNA_def_property_update(prop, NC_SPACE | ND_SPACE_OUTLINER, NULL); | RNA_def_property_update(prop, NC_SPACE | ND_SPACE_OUTLINER, NULL); | ||||
| prop = RNA_def_property(srna, "use_sync_select", PROP_BOOLEAN, PROP_NONE); | prop = RNA_def_property(srna, "use_sync_select", PROP_BOOLEAN, PROP_NONE); | ||||
| RNA_def_property_boolean_sdna(prop, NULL, "flag", SO_SYNC_SELECT); | RNA_def_property_boolean_sdna(prop, NULL, "flag", SO_SYNC_SELECT); | ||||
| RNA_def_property_ui_text( | RNA_def_property_ui_text( | ||||
| prop, "Sync Outliner Selection", "Sync outliner selection with other editors"); | prop, "Sync Outliner Selection", "Sync outliner selection with other editors"); | ||||
| RNA_def_property_update(prop, NC_SPACE | ND_SPACE_OUTLINER, NULL); | RNA_def_property_update(prop, NC_SPACE | ND_SPACE_OUTLINER, NULL); | ||||
| ▲ Show 20 Lines • Show All 3,615 Lines • Show Last 20 Lines | |||||
Maybe "Custom" is a better name? Also, please use the same name for the DNA define. Better not to introduce discrepancies in new code, we already have enough in old code.