Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(89)

Side by Side Diff: third_party/WebKit/Source/platform/scroll/ScrollbarThemeMacNonOverlayAPI.mm

Issue 1331533002: [poc] curve-filter Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Fix CanvasRenderingContext2D::createPattern crash for #40 Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after
141 tickmarkTrackRect.inflateY(-tickmarkTrackRect.width()); 141 tickmarkTrackRect.inflateY(-tickmarkTrackRect.width());
142 // Inset a bit. 142 // Inset a bit.
143 tickmarkTrackRect.setX(tickmarkTrackRect.x() + 2); 143 tickmarkTrackRect.setX(tickmarkTrackRect.x() + 2);
144 tickmarkTrackRect.setWidth(tickmarkTrackRect.width() - 5); 144 tickmarkTrackRect.setWidth(tickmarkTrackRect.width() - 5);
145 paintGivenTickmarks(drawingCanvas, scrollbar, tickmarkTrackRect, tickmarks); 145 paintGivenTickmarks(drawingCanvas, scrollbar, tickmarkTrackRect, tickmarks);
146 146
147 if (!canDrawDirectly) { 147 if (!canDrawDirectly) {
148 ASSERT(imageBuffer); 148 ASSERT(imageBuffer);
149 if (!context.contextDisabled()) { 149 if (!context.contextDisabled()) {
150 imageBuffer->draw(context, FloatRect(scrollbar.frameRect().location( ), FloatSize(imageBuffer->size())), 150 imageBuffer->draw(context, FloatRect(scrollbar.frameRect().location( ), FloatSize(imageBuffer->size())),
151 nullptr, SkXfermode::kSrcOver_Mode); 151 nullptr, SkXfermode::kSrcOver_Mode, nullptr); // FIXME: not colo r corrrect.
152 } 152 }
153 } 153 }
154 154
155 return true; 155 return true;
156 } 156 }
157 157
158 int ScrollbarThemeMacNonOverlayAPI::scrollbarThickness(ScrollbarControlSize cont rolSize) 158 int ScrollbarThemeMacNonOverlayAPI::scrollbarThickness(ScrollbarControlSize cont rolSize)
159 { 159 {
160 return cScrollbarThickness[controlSize]; 160 return cScrollbarThickness[controlSize];
161 } 161 }
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
309 return IntRect(scrollbar.x() + startWidth, scrollbar.y(), scrollbar.widt h() - totalWidth, thickness); 309 return IntRect(scrollbar.x() + startWidth, scrollbar.y(), scrollbar.widt h() - totalWidth, thickness);
310 return IntRect(scrollbar.x(), scrollbar.y() + startWidth, thickness, scrollb ar.height() - totalWidth); 310 return IntRect(scrollbar.x(), scrollbar.y() + startWidth, thickness, scrollb ar.height() - totalWidth);
311 } 311 }
312 312
313 int ScrollbarThemeMacNonOverlayAPI::minimumThumbLength(const ScrollbarThemeClien t& scrollbar) 313 int ScrollbarThemeMacNonOverlayAPI::minimumThumbLength(const ScrollbarThemeClien t& scrollbar)
314 { 314 {
315 return cThumbMinLength[scrollbar.controlSize()]; 315 return cThumbMinLength[scrollbar.controlSize()];
316 } 316 }
317 317
318 } 318 }
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/platform/scroll/Scrollbar.cpp ('k') | third_party/WebKit/Source/web/PageOverlay.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698