| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2003, 2004, 2005, 2006, 2009 Apple Inc. All rights reserved. | 2 * Copyright (C) 2003, 2004, 2005, 2006, 2009 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2013 Google Inc. All rights reserved. | 3 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 1151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1162 SkPath& path = const_cast<SkPath&>(pathToClip.getSkPath()); | 1162 SkPath& path = const_cast<SkPath&>(pathToClip.getSkPath()); |
| 1163 path.toggleInverseFillType(); | 1163 path.toggleInverseFillType(); |
| 1164 clipPath(path, AntiAliased); | 1164 clipPath(path, AntiAliased); |
| 1165 path.toggleInverseFillType(); | 1165 path.toggleInverseFillType(); |
| 1166 } | 1166 } |
| 1167 | 1167 |
| 1168 void GraphicsContext::clipOutRoundedRect(const FloatRoundedRect& rect) { | 1168 void GraphicsContext::clipOutRoundedRect(const FloatRoundedRect& rect) { |
| 1169 if (contextDisabled()) | 1169 if (contextDisabled()) |
| 1170 return; | 1170 return; |
| 1171 | 1171 |
| 1172 clipRoundedRect(rect, kDifference_SkClipOp); | 1172 clipRoundedRect(rect, SkClipOp::kDifference); |
| 1173 } | 1173 } |
| 1174 | 1174 |
| 1175 void GraphicsContext::clipRect(const SkRect& rect, | 1175 void GraphicsContext::clipRect(const SkRect& rect, |
| 1176 AntiAliasingMode aa, | 1176 AntiAliasingMode aa, |
| 1177 SkClipOp op) { | 1177 SkClipOp op) { |
| 1178 if (contextDisabled()) | 1178 if (contextDisabled()) |
| 1179 return; | 1179 return; |
| 1180 ASSERT(m_canvas); | 1180 ASSERT(m_canvas); |
| 1181 | 1181 |
| 1182 m_canvas->clipRect(rect, op, aa == AntiAliased); | 1182 m_canvas->clipRect(rect, op, aa == AntiAliased); |
| (...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1414 static const SkPMColor colors[] = { | 1414 static const SkPMColor colors[] = { |
| 1415 SkPreMultiplyARGB(0x60, 0xFF, 0x00, 0x00), // More transparent red | 1415 SkPreMultiplyARGB(0x60, 0xFF, 0x00, 0x00), // More transparent red |
| 1416 SkPreMultiplyARGB(0x60, 0xC0, 0xC0, 0xC0) // More transparent gray | 1416 SkPreMultiplyARGB(0x60, 0xC0, 0xC0, 0xC0) // More transparent gray |
| 1417 }; | 1417 }; |
| 1418 | 1418 |
| 1419 return colors[index]; | 1419 return colors[index]; |
| 1420 } | 1420 } |
| 1421 #endif | 1421 #endif |
| 1422 | 1422 |
| 1423 } // namespace blink | 1423 } // namespace blink |
| OLD | NEW |