Skip to content

Commit

Permalink
Merge branch 'guillembartrina/purr-data-feature-dirtyvisualmarkings'
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonathan Wilkes committed Sep 9, 2020
2 parents 0d4f1d9 + 60e47d1 commit db34c00
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 7 deletions.
5 changes: 0 additions & 5 deletions pd/src/g_editor.c
Original file line number Diff line number Diff line change
Expand Up @@ -1288,7 +1288,6 @@ void canvas_undo_paste(t_canvas *x, void *z, int action)
}
}

void canvas_dirtyclimb(t_canvas *x, int n);
int clone_match(t_pd *z, t_symbol *name, t_symbol *dir);

/* recursively check for abstractions to reload as result of a save.
Expand All @@ -1315,10 +1314,6 @@ static void glist_doreload(t_glist *gl, t_symbol *name, t_symbol *dir,
((t_canvas *)g)->gl_name == name &&
canvas_getdir((t_canvas *)g) == dir);

/* remove dirtiness visual markings */
if(remakeit && ((t_canvas *)g)->gl_dirty)
canvas_dirtyclimb((t_canvas *)g, 0);

/* also remake it if it's a "clone" with that name */
if (pd_class(&g->g_pd) == clone_class &&
clone_match(&g->g_pd, name, dir))
Expand Down
3 changes: 3 additions & 0 deletions pd/src/g_graph.c
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,9 @@ void glist_delete(t_glist *x, t_gobj *y)
/* if we are a group, let's call ourselves a drawcommand */
if (((t_canvas *)y)->gl_svg)
drawcommand = 1;

if(((t_canvas *)y)->gl_dirty)
canvas_dirtyclimb((t_canvas *)y, 0);
}

wasdeleting = canvas_setdeleting(canvas, 1);
Expand Down
4 changes: 2 additions & 2 deletions pd/src/g_text.c
Original file line number Diff line number Diff line change
Expand Up @@ -2248,9 +2248,9 @@ static void text_vis(t_gobj *z, t_glist *glist, int vis)
if(pd_class(&x->te_pd) == canvas_class)
{
if (((t_canvas *)x)->gl_dirty)
gobj_dirty(x, glist, 1);
gobj_dirty(&x->te_g, glist, 1);
else if (((t_canvas *)x)->gl_subdirties)
gobj_dirty(x, glist, 2);
gobj_dirty(&x->te_g, glist, 2);
}
}
}
Expand Down

0 comments on commit db34c00

Please sign in to comment.