Blender
V4.3
source
blender
editors
space_outliner
tree
tree_element_id_library.cc
Go to the documentation of this file.
1
/* SPDX-FileCopyrightText: 2023 Blender Authors
2
*
3
* SPDX-License-Identifier: GPL-2.0-or-later */
4
9
#include "
BLT_translation.hh
"
10
11
#include "
DNA_ID.h
"
12
#include "
DNA_listBase.h
"
13
14
#include "
../outliner_intern.hh
"
15
16
#include "
tree_element_id_library.hh
"
17
18
namespace
blender::ed::outliner
{
19
20
TreeElementIDLibrary::TreeElementIDLibrary
(
TreeElement
&legacy_te,
Library
&library)
21
:
TreeElementID
(legacy_te, library.id)
22
{
23
legacy_te.
name
= library.
filepath
;
24
}
25
26
StringRefNull
TreeElementIDLibrary::get_warning
()
const
27
{
28
Library
&library =
reinterpret_cast<
Library
&
>
(
id_
);
29
30
if
(library.
runtime
.
tag
&
LIBRARY_TAG_RESYNC_REQUIRED
) {
31
return
RPT_
(
32
"Contains linked library overrides that need to be resynced, updating the library is "
33
"recommended"
);
34
}
35
36
if
(library.
id
.
tag
&
ID_TAG_MISSING
) {
37
return
RPT_
(
"Missing library"
);
38
}
39
40
return
{};
41
}
42
43
}
// namespace blender::ed::outliner
BLT_translation.hh
RPT_
#define RPT_(msgid)
Definition
BLT_translation.hh:43
DNA_ID.h
ID and Library types, which are fundamental for SDNA.
ID_TAG_MISSING
@ ID_TAG_MISSING
Definition
DNA_ID.h:813
LIBRARY_TAG_RESYNC_REQUIRED
@ LIBRARY_TAG_RESYNC_REQUIRED
Definition
DNA_ID.h:541
DNA_listBase.h
These structs are the foundation for all linked lists in the library system.
blender::StringRefNull
Definition
BLI_string_ref.hh:111
blender::ed::outliner::TreeElementIDLibrary::TreeElementIDLibrary
TreeElementIDLibrary(TreeElement &legacy_te, Library &library)
Definition
tree_element_id_library.cc:20
blender::ed::outliner::TreeElementIDLibrary::get_warning
blender::StringRefNull get_warning() const override
Definition
tree_element_id_library.cc:26
blender::ed::outliner::TreeElementID
Definition
tree_element_id.hh:20
blender::ed::outliner::TreeElementID::id_
ID & id_
Definition
tree_element_id.hh:22
blender::ed::outliner
Definition
outliner_collections.cc:42
outliner_intern.hh
ID::tag
int tag
Definition
DNA_ID.h:434
Library_Runtime::tag
ushort tag
Definition
DNA_ID.h:515
Library
Definition
DNA_ID.h:528
Library::filepath
char filepath[1024]
Definition
DNA_ID.h:531
Library::runtime
struct Library_Runtime runtime
Definition
DNA_ID.h:535
Library::id
ID id
Definition
DNA_ID.h:529
blender::ed::outliner::TreeElement
Definition
outliner_intern.hh:84
blender::ed::outliner::TreeElement::name
const char * name
Definition
outliner_intern.hh:102
tree_element_id_library.hh
Generated on Thu Feb 6 2025 07:36:39 for Blender by
doxygen
1.11.0