]> granicus.if.org Git - transmission/commitdiff
when drawing gradients in the status and filter bar, always draw the full height
authorMitchell Livingston <livings124@transmissionbt.com>
Wed, 14 Sep 2011 03:15:58 +0000 (03:15 +0000)
committerMitchell Livingston <livings124@transmissionbt.com>
Wed, 14 Sep 2011 03:15:58 +0000 (03:15 +0000)
macosx/FilterBarView.m
macosx/StatusBarView.m

index 62fdb1506248e36f5b2ef031cb97de1772de92e4..5da8ed28e8b922f82c0f767c36e7cf86a92616d4 100644 (file)
@@ -82,7 +82,8 @@
     
     NSRectFillListWithColors(gridRects, colorRects, count);
     
-    [fGradient drawInRect: rect angle: 270.0];
+    const NSRect gradientRect = NSMakeRect(NSMinX(rect), 1.0, NSWidth(rect), NSHeight([self bounds]) - 1.0 - 1.0); //proper gradient requires the full height of the bar
+    [fGradient drawInRect: gradientRect angle: 270.0];
 }
 
 @end
index dc512e215fdb8309074b2a68f3e432c5d0a4aaf6..04d07f82f221a0ecc38e91c0eb84ecd9a9bfb0cf 100644 (file)
     }
     
     if (active)
-        [fGradient drawInRect: rect angle: 270.0];
+    {
+        const NSRect gradientRect = NSMakeRect(NSMinX(rect), 1.0, NSWidth(rect), NSHeight([self bounds]) - 1.0 - 1.0); //proper gradient requires the full height of the bar
+        [fGradient drawInRect: gradientRect angle: 270.0];
+    }
     else
     {
         gridRects[count] = rect;