# HG changeset patch # User Mikhail Kryshen <mikhail@kryshen.net> # Date 1291654642 -10800 # Node ID f87363889015d4d613e12190fbe0135d551a49ba # Parent dd7b8dbb20bcc8fa324cfe2da0b0eae3192fc7b0 Fixed calculation of the highlight bounds in viewport-miniature. diff -r dd7b8dbb20bc -r f87363889015 src/net/kryshen/indyvon/layers.clj --- a/src/net/kryshen/indyvon/layers.clj Sun Nov 28 03:46:59 2010 +0300 +++ b/src/net/kryshen/indyvon/layers.clj Mon Dec 06 19:57:22 2010 +0300 @@ -294,8 +294,8 @@ (let [size (layer-size (:content viewport)) s (scaling (:width size) (:height size) width height) [x y w h] (viewport-visible-bounds viewport) - x (* x s) - y (* y s) + x (* (+ x (align-x (:width size) (/ width s) :center)) s) + y (* (+ y (align-y (:height size) (/ height s) :center)) s) w (* w s) h (* h s)] (with-color :alt-back-color