111 ID *
id = *id_pointer;
113 bool do_stop_iter =
true;
117 if (ob_self->
data ==
id) {
119 if (ob_self->
pose !=
nullptr) {
127 do_stop_iter =
false;
169 bool use_old_bmain_data =
true;
172 use_old_bmain_data =
false;
180 use_old_bmain_data =
false;
192 if (us_next !=
nullptr) {
194 use_old_bmain_data =
false;
201 GHash *depsgraphs =
nullptr;
202 if (use_old_bmain_data) {
218 us_iter->is_applied =
false;
220 for (
UndoStep *us_iter = us_p; us_iter; us_iter = us_iter->
prev) {
224 us_iter->is_applied =
true;
231 if (use_old_bmain_data) {
258 if (scene->
runtime->sequencer.depsgraph) {
275 if (recalc_flags != 0) {
280 if (nodetree !=
nullptr) {
285 if (recalc_flags != 0) {
296 if (recalc_flags != 0) {
315 id->recalc_after_undo_push = 0;
317 if (nodetree !=
nullptr) {
346 if (us_p->
next !=
nullptr) {
348 if (us_next_p !=
nullptr) {
359 ut->
name =
"Global Undo";
406 if (mem_chunk->id_session_uid == id->
session_uid) {
407 mem_chunk->is_identical_future =
false;
bool BKE_memfile_undo_decode(MemFileUndoData *mfu, eUndoStepDir undo_direction, bool use_old_bmain_data, bContext *C)
MemFileUndoData * BKE_memfile_undo_encode(Main *bmain, MemFileUndoData *mfu_prev)
void BKE_memfile_undo_free(MemFileUndoData *mfu)
Scene * CTX_data_scene(const bContext *C)
Main * CTX_data_main(const bContext *C)
wmWindowManager * CTX_wm_manager(const bContext *C)
void BKE_library_foreach_ID_link(Main *bmain, ID *id, blender::FunctionRef< LibraryIDLinkCallback > callback, void *user_data, LibraryForeachIDFlag flag)
#define FOREACH_MAIN_ID_END
#define FOREACH_MAIN_ID_BEGIN(_bmain, _id)
PreviewImage * BKE_previewimg_id_get(const ID *id)
bool BKE_previewimg_is_finished(const PreviewImage *prv, int size)
void BKE_scene_undo_depsgraphs_restore(Main *bmain, GHash *depsgraph_extract)
GHash * BKE_scene_undo_depsgraphs_extract(Main *bmain)
UndoStep * BKE_undosys_step_find_by_type(UndoStack *ustack, const UndoType *ut)
UndoStep * BKE_undosys_step_same_type_next(UndoStep *us)
const UndoType * BKE_UNDOSYS_TYPE_MEMFILE
#define BKE_UNDOSYS_TYPE_IS_MEMFILE_SKIP(ty)
#define LISTBASE_FOREACH(type, var, list)
#define UNUSED_VARS_NDEBUG(...)
void BLO_memfile_merge(MemFile *first, MemFile *second)
void DEG_graph_free(Depsgraph *graph)
ID and Library types, which are fundamental for SDNA.
@ ID_TAG_UNDO_OLD_ID_REUSED_UNCHANGED
@ ID_TAG_UNDO_OLD_ID_REUSED_NOUNDO
@ ID_TAG_UNDO_OLD_ID_REREAD_IN_PLACE
#define ID_IS_LINKED(_id)
Object groups, one object can be in many groups at once.
Object is a sort of wrapper for general info.
#define USER_DEVELOPER_TOOL_TEST(userdef, member)
void ED_preview_restart_queue_add(ID *id, enum eIconSizes size)
void ED_preview_kill_jobs(wmWindowManager *wm, Main *bmain)
UndoStack * ED_undo_stack_get()
bool ED_undo_is_memfile_compatible(const bContext *C)
void ED_editors_exit(Main *bmain, bool do_undo_system)
void ED_editors_init_for_undo(Main *bmain)
bool ED_editors_flush_edits_ex(Main *bmain, bool for_render, bool check_needs_flush)
Depsgraph * preview_depsgraph
DEG_id_tag_update_ex(cb_data->bmain, cb_data->owner_id, ID_RECALC_TAG_FOR_UNDO|ID_RECALC_SYNC_TO_EVAL)
static MemFile * ed_undosys_step_get_memfile(UndoStep *us_p)
void ED_undosys_stack_memfile_id_changed_tag(UndoStack *ustack, ID *id)
static void memfile_undosys_step_free(UndoStep *us_p)
MemFile * ED_undosys_stack_memfile_get_if_active(UndoStack *ustack)
static int memfile_undosys_step_id_reused_cb(LibraryIDLinkCallbackData *cb_data)
static void memfile_undosys_step_decode(bContext *C, Main *bmain, UndoStep *us_p, const eUndoStepDir undo_direction, bool)
static bool memfile_undosys_poll(bContext *C)
static bool memfile_undosys_step_encode(bContext *, Main *bmain, UndoStep *us_p)
void ED_memfile_undosys_type(UndoType *ut)
static void memfile_undosys_unfinished_id_previews_restart(ID *id)
bNodeTree * node_tree_from_id(ID *id)
unsigned int recalc_after_undo_push
bool is_memfile_undo_flush_needed
bool use_memfile_full_barrier
struct Collection * master_collection
SceneRuntimeHandle * runtime
struct bNodeTree * compositing_node_group
void(* step_free)(UndoStep *us)
bool(* poll)(struct bContext *C)
void(* step_decode)(bContext *C, Main *bmain, UndoStep *us, eUndoStepDir dir, bool is_final)
bool(* step_encode)(bContext *C, Main *bmain, UndoStep *us)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)