Blender V5.3
blender::ed::outliner::TreeElementOverridesProperty Class Reference

#include <tree_element_overrides.hh>

Inherits blender::ed::outliner::AbstractTreeElement.

Inherited by blender::ed::outliner::TreeElementOverridesPropertyOperation.

Public Member Functions

std::optional< BIFIconID > get_icon () const override
Public Member Functions inherited from blender::ed::outliner::AbstractTreeElement
virtual ~AbstractTreeElement ()=default
virtual bool expand_poll (const SpaceOutliner &) const
TreeElement & get_legacy_element ()
void print_path ()

Public Attributes

PointerRNA override_rna_ptr
PropertyRNA & override_rna_prop
StringRefNull rna_path
bool is_rna_path_valid

Static Public Attributes

static constexpr eTreeStoreElemType element_type = TSE_LIBRARY_OVERRIDE

Overridden Property

Represents an RNA property that was overridden.

 TreeElementOverridesProperty (TreeElement &legacy_te, TreeElementOverridesData &override_data)
StringRefNull get_warning () const override
IDOverrideLibraryProperty * get_override_property_from_id (ID &id) const
static ID * owner_id (TreeElementOverridesData &override_data)

Additional Inherited Members

Static Public Member Functions inherited from blender::ed::outliner::AbstractTreeElement
static void uncollapse_by_default (TreeElement *legacy_te)
Protected Member Functions inherited from blender::ed::outliner::AbstractTreeElement
 AbstractTreeElement (TreeElement &legacy_te)
virtual void expand (SpaceOutliner &) const
template<typename ElementType, typename... Args>
TreeElement * add_element (const TreeElementAddParams &params, Args &&...args) const
TreeElement * add_id_element (const TreeElementAddParams &params, ID *id) const
Protected Attributes inherited from blender::ed::outliner::AbstractTreeElement
TreeElement & legacy_te_
AbstractTreeDisplay * display_

Detailed Description

Represent a single overridden property. Collection properties may support multiple override operations, e.g. to insert/remove multiple collection items. For these multiple operation cases, use TreeElementOverridesPropertyOperation.

Definition at line 66 of file tree_element_overrides.hh.

Constructor & Destructor Documentation

◆ TreeElementOverridesProperty()

Member Function Documentation

◆ get_icon()

std::optional< BIFIconID > blender::ed::outliner::TreeElementOverridesProperty::get_icon ( ) const
inlineoverridevirtual

Define the icon to be displayed for this element. If this returns an icon, this will be displayed. Otherwise, tree_element_get_icon() may still determine an icon. By default no value is returned (#std::nullopt).

All elements should be ported to use this over tree_element_get_icon().

Reimplemented from blender::ed::outliner::AbstractTreeElement.

Reimplemented in blender::ed::outliner::TreeElementOverridesPropertyOperation.

Definition at line 84 of file tree_element_overrides.hh.

◆ get_override_property_from_id()

IDOverrideLibraryProperty * blender::ed::outliner::TreeElementOverridesProperty::get_override_property_from_id ( ID & id) const

Return the liboverride property matching this tree element, for the given ID.

Definition at line 205 of file tree_element_overrides.cc.

References blender::BKE_lib_override_library_property_find(), blender::BLI_assert(), blender::StringRefNull::c_str(), ID_IS_OVERRIDE_LIBRARY_REAL, and rna_path.

◆ get_warning()

StringRefNull blender::ed::outliner::TreeElementOverridesProperty::get_warning ( ) const
overridevirtual

By letting this return a warning message, the tree element will display a warning icon with the message in the tooltip.

Reimplemented from blender::ed::outliner::AbstractTreeElement.

Definition at line 194 of file tree_element_overrides.cc.

References is_rna_path_valid, and RPT_.

◆ owner_id()

ID * blender::ed::outliner::TreeElementOverridesProperty::owner_id ( TreeElementOverridesData & override_data)
static

The ID identifying this element in the tree-store, see #AbstractTreeDisplay::add_element().

Definition at line 170 of file tree_element_overrides.cc.

References blender::ed::outliner::TreeElementOverridesData::id.

Member Data Documentation

◆ element_type

eTreeStoreElemType blender::ed::outliner::TreeElementOverridesProperty::element_type = TSE_LIBRARY_OVERRIDE
staticconstexpr

Definition at line 74 of file tree_element_overrides.hh.

◆ is_rna_path_valid

bool blender::ed::outliner::TreeElementOverridesProperty::is_rna_path_valid

◆ override_rna_prop

◆ override_rna_ptr

PointerRNA blender::ed::outliner::TreeElementOverridesProperty::override_rna_ptr

◆ rna_path

StringRefNull blender::ed::outliner::TreeElementOverridesProperty::rna_path

The documentation for this class was generated from the following files: