Use a shorter/simpler license convention, stops the header taking so much space. Follow the SPDX license specification: https://spdx.org/licenses - C/C++/objc/objc++ - Python - Shell Scripts - CMake, GNUmakefile While most of the source tree has been included - `./extern/` was left out. - `./intern/cycles` & `./intern/atomic` are also excluded because they use different header conventions. doc/license/SPDX-license-identifiers.txt has been added to list SPDX all used identifiers. See P2788 for the script that automated these edits. Reviewed By: brecht, mont29, sergey Ref D14069
42 lines
1.0 KiB
C++
42 lines
1.0 KiB
C++
/* SPDX-License-Identifier: GPL-2.0-or-later
|
|
* Copyright 2013 Blender Foundation. All rights reserved. */
|
|
|
|
/** \file
|
|
* \ingroup depsgraph
|
|
*/
|
|
|
|
#include "intern/depsgraph_update.h"
|
|
|
|
#include "DEG_depsgraph.h"
|
|
|
|
#include "intern/depsgraph_type.h"
|
|
|
|
namespace deg = blender::deg;
|
|
|
|
namespace blender::deg {
|
|
|
|
static DEG_EditorUpdateIDCb deg_editor_update_id_cb = nullptr;
|
|
static DEG_EditorUpdateSceneCb deg_editor_update_scene_cb = nullptr;
|
|
|
|
void deg_editors_id_update(const DEGEditorUpdateContext *update_ctx, ID *id)
|
|
{
|
|
if (deg_editor_update_id_cb != nullptr) {
|
|
deg_editor_update_id_cb(update_ctx, id);
|
|
}
|
|
}
|
|
|
|
void deg_editors_scene_update(const DEGEditorUpdateContext *update_ctx, bool updated)
|
|
{
|
|
if (deg_editor_update_scene_cb != nullptr) {
|
|
deg_editor_update_scene_cb(update_ctx, updated);
|
|
}
|
|
}
|
|
|
|
} // namespace blender::deg
|
|
|
|
void DEG_editors_set_update_cb(DEG_EditorUpdateIDCb id_func, DEG_EditorUpdateSceneCb scene_func)
|
|
{
|
|
deg::deg_editor_update_id_cb = id_func;
|
|
deg::deg_editor_update_scene_cb = scene_func;
|
|
}
|