forked from AuroraMiddleware/gtk
stylechange: Do the right thing when old and new style are equal
We don't need to compare all their CSS values to figure out that nothing changed. We know that.
This commit is contained in:
parent
c904efef53
commit
6e6cbd7316
@ -33,6 +33,10 @@ gtk_css_style_change_init (GtkCssStyleChange *change,
|
|||||||
|
|
||||||
change->affects = 0;
|
change->affects = 0;
|
||||||
change->changes = _gtk_bitmask_new ();
|
change->changes = _gtk_bitmask_new ();
|
||||||
|
|
||||||
|
/* Make sure we don't do extra work if old and new are equal. */
|
||||||
|
if (old_style == new_style)
|
||||||
|
change->n_compared = GTK_CSS_PROPERTY_N_PROPERTIES;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
|
Loading…
Reference in New Issue
Block a user