summaryrefslogtreecommitdiff
path: root/catbird/node-2d.scm
diff options
context:
space:
mode:
Diffstat (limited to 'catbird/node-2d.scm')
-rw-r--r--catbird/node-2d.scm11
1 files changed, 7 insertions, 4 deletions
diff --git a/catbird/node-2d.scm b/catbird/node-2d.scm
index 6e7eb41..41f82db 100644
--- a/catbird/node-2d.scm
+++ b/catbird/node-2d.scm
@@ -455,10 +455,13 @@
(next-method))
(define-method (resize (node <node-2d>) w h)
- (set! (width node) w)
- (set! (height node) h)
- (expire-local-bounding-box node)
- (on-child-resize (parent node) node))
+ ;; No-op if the size is the same.
+ (unless (and (= (width node) w)
+ (= (height node) h))
+ (set! (width node) w)
+ (set! (height node) h)
+ (expire-local-bounding-box node)
+ (on-child-resize (parent node) node)))
;;;