Changeset 88015 in webkit
- Timestamp:
- Jun 3, 2011 7:39:52 AM (13 years ago)
- Location:
- trunk/Tools
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Tools/ChangeLog
r88013 r88015 1 2011-06-03 Cary Clark <caryclark@google.com> 2 3 Reviewed by Eric Seidel. 4 5 Draw DRT scroll bar thumb with CG when WebKit renders with Skia 6 https://bugs.webkit.org/show_bug.cgi?id=61534 7 8 Skia on Mac uses Skia to render WebKit, and CG 9 to render UI elements. The CG elements need a 10 transcribed graphics context that preserves the 11 canvas matrix, and the canvas clip. 12 13 The SkiaBitLocker utility class sets up a CGContext 14 from the SkCanvas, locks the bitmap's bits, and 15 releases the lock when the class goes out of scope. 16 17 The SkiaBitLocker implementation is described by 18 this patch: 19 http://codereview.chromium.org/7031006/ 20 21 When WebKit uses Skia for rendering, the WebCanvas 22 is an SkCanvas. Create an equivalent CGContext to 23 draw the scrollbar thumb. 24 25 As the Chrome Mac port does not yet use Skia, this 26 patch has no effect and requires no tests. 27 28 * DumpRenderTree/chromium/WebThemeEngineDRTMac.mm: 29 (WebThemeEngineDRTMac::paintHIThemeScrollbarThumb): 30 1 31 2011-06-03 Andras Becsi <abecsi@webkit.org> 2 32 -
trunk/Tools/DumpRenderTree/chromium/WebThemeEngineDRTMac.mm
r75918 r88015 38 38 #import <AppKit/NSWindow.h> 39 39 #include <Carbon/Carbon.h> 40 41 #if WEBKIT_USING_SKIA 42 #include "skia/ext/skia_utils_mac.h" 43 #endif 40 44 41 45 using WebKit::WebCanvas; … … 141 145 state == WebThemeEngine::StatePressed ? kThemeThumbPressed : 0; 142 146 trackInfo.attributes |= (kThemeTrackShowThumb | kThemeTrackHideTrack); 143 HIThemeDrawTrack(&trackInfo, 0, canvas, kHIThemeOrientationNormal); 147 #if WEBKIT_USING_SKIA 148 gfx::SkiaBitLocker bitLocker(canvas); 149 CGContextRef cgContext = bitLocker.cgContext(); 150 #else 151 CGContextRef cgContext = canvas; 152 #endif 153 HIThemeDrawTrack(&trackInfo, 0, cgContext, kHIThemeOrientationNormal); 144 154 } 145 155
Note: See TracChangeset
for help on using the changeset viewer.