51 bGPdata **gpd_ptr =
nullptr, *new_gpd =
nullptr;
107 undo_node->
gpd->
adt =
nullptr;
127 undo_node = next_node;
145 if (
steps >=
U.undosteps) {
151 undo_node = prev_node;
156 undo_node = MEM_cnew<bGPundonode>(
"gpencil undo node");
170 undo_node = undo_node->
next;
void BKE_gpencil_free_data(struct bGPdata *gpd, bool free_all)
struct bGPdata * BKE_gpencil_data_duplicate(struct Main *bmain, const struct bGPdata *gpd, bool internal_copy)
struct bGPDlayer * BKE_gpencil_layer_duplicate(const struct bGPDlayer *gpl_src, bool dup_frames, bool dup_strokes)
void BKE_gpencil_free_layers(struct ListBase *list)
BLI_INLINE bool BLI_listbase_is_empty(const struct ListBase *lb)
#define LISTBASE_FOREACH(type, var, list)
void BLI_freelinkN(struct ListBase *listbase, void *vlink) ATTR_NONNULL(1)
BLI_INLINE void BLI_listbase_clear(struct ListBase *lb)
void void BLI_freelistN(struct ListBase *listbase) ATTR_NONNULL(1)
void BLI_addtail(struct ListBase *listbase, void *vlink) ATTR_NONNULL(1)
void DEG_id_tag_update(ID *id, unsigned int flags)
These structs are the foundation for all linked lists in the library system.
Object is a sort of wrapper for general info.
Read Guarded memory(de)allocation.
void gpencil_undo_push(bGPdata *gpd)
void gpencil_undo_init(bGPdata *gpd)
static void gpencil_undo_free_node(bGPundonode *undo_node)
int ED_undo_gpencil_step(bContext *C, const int step)
void gpencil_undo_finish()
int ED_gpencil_session_active()
static ListBase undo_nodes
static bGPundonode * cur_node
bGPdata ** ED_gpencil_data_get_pointers(const bContext *C, PointerRNA *r_ptr)
void MEM_freeN(void *vmemh)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)