Title: [96615] trunk/Source/WebCore
Revision
96615
Author
[email protected]
Date
2011-10-04 11:12:58 -0700 (Tue, 04 Oct 2011)

Log Message

Inset focus ring (Skia on Mac)
https://bugs.webkit.org/show_bug.cgi?id=69166
http://code.google.com/p/chromium/issues/detail?id=97956

This focus ring was drawn too large and was left tracks
in subsequent invalidations. Make it more closely match
the CG version.

Reviewed by Adam Barth.

No new tests. This platform is not enabled.

* platform/graphics/skia/GraphicsContextSkia.cpp:
(WebCore::getFocusRingOutset):
(WebCore::GraphicsContext::drawFocusRing):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (96614 => 96615)


--- trunk/Source/WebCore/ChangeLog	2011-10-04 18:11:55 UTC (rev 96614)
+++ trunk/Source/WebCore/ChangeLog	2011-10-04 18:12:58 UTC (rev 96615)
@@ -1,3 +1,21 @@
+2011-10-04  Cary Clark  <[email protected]>
+
+        Inset focus ring (Skia on Mac)
+        https://bugs.webkit.org/show_bug.cgi?id=69166
+        http://code.google.com/p/chromium/issues/detail?id=97956
+
+        This focus ring was drawn too large and was left tracks
+        in subsequent invalidations. Make it more closely match
+        the CG version.
+
+        Reviewed by Adam Barth.
+
+        No new tests. This platform is not enabled.
+
+        * platform/graphics/skia/GraphicsContextSkia.cpp:
+        (WebCore::getFocusRingOutset):
+        (WebCore::GraphicsContext::drawFocusRing):
+
 2011-10-03  Jon Lee  <[email protected]>
 
         Extend DOM WheelEvent to differentiate between physical and logical scroll directions

Modified: trunk/Source/WebCore/platform/graphics/skia/GraphicsContextSkia.cpp (96614 => 96615)


--- trunk/Source/WebCore/platform/graphics/skia/GraphicsContextSkia.cpp	2011-10-04 18:11:55 UTC (rev 96614)
+++ trunk/Source/WebCore/platform/graphics/skia/GraphicsContextSkia.cpp	2011-10-04 18:12:58 UTC (rev 96615)
@@ -538,10 +538,10 @@
 #endif
 }
 
-static inline SkScalar getFocusRingOutset(int width)
+static inline SkScalar getFocusRingOutset()
 {
 #if PLATFORM(CHROMIUM) && OS(DARWIN)
-    return (width * 0.5f) + 0.25f;
+    return 0.75f;
 #else
     return 0.5f;
 #endif
@@ -557,7 +557,7 @@
         return;
 
     SkRegion focusRingRegion;
-    const SkScalar focusRingOutset = getFocusRingOutset(width);
+    const SkScalar focusRingOutset = getFocusRingOutset();
     for (unsigned i = 0; i < rectCount; i++) {
         SkIRect r = rects[i];
         r.inset(-focusRingOutset, -focusRingOutset);
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to