101 ID *
id = *id_pointer;
103 bool do_stop_iter =
true;
107 if (ob_self->
data ==
id) {
109 if (ob_self->
pose !=
nullptr) {
117 do_stop_iter =
false;
159 bool use_old_bmain_data =
true;
162 use_old_bmain_data =
false;
170 use_old_bmain_data =
false;
182 if (us_next !=
nullptr) {
184 use_old_bmain_data =
false;
191 GHash *depsgraphs =
nullptr;
192 if (use_old_bmain_data) {
208 us_iter->is_applied =
false;
210 for (
UndoStep *us_iter = us_p; us_iter; us_iter = us_iter->
prev) {
214 us_iter->is_applied =
true;
221 if (use_old_bmain_data) {
243 if (recalc_flags != 0) {
248 if (nodetree !=
nullptr) {
253 if (recalc_flags != 0) {
264 if (recalc_flags != 0) {
283 id->recalc_after_undo_push = 0;
285 if (nodetree !=
nullptr) {
303 Mesh *mesh =
static_cast<Mesh *
>(
object->data);
328 if (us_p->
next !=
nullptr) {
330 if (us_next_p !=
nullptr) {
341 ut->
name =
"Global Undo";
388 if (mem_chunk->id_session_uid == id->
session_uid) {
389 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)
void BLO_memfile_merge(MemFile *first, MemFile *second)
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
Object groups, one object can be in many groups at once.
Object is a sort of wrapper for general info.
#define USER_EXPERIMENTAL_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)
#define ID_IS_LINKED(_id)
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
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)