| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc.
All rights reserved. | 2 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc.
All rights reserved. |
| 3 * Copyright (C) 2008, 2010 Nokia Corporation and/or its subsidiary(-ies) | 3 * Copyright (C) 2008, 2010 Nokia Corporation and/or its subsidiary(-ies) |
| 4 * Copyright (C) 2007 Alp Toker <alp@atoker.com> | 4 * Copyright (C) 2007 Alp Toker <alp@atoker.com> |
| 5 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> | 5 * Copyright (C) 2008 Eric Seidel <eric@webkit.org> |
| 6 * Copyright (C) 2008 Dirk Schulze <krit@webkit.org> | 6 * Copyright (C) 2008 Dirk Schulze <krit@webkit.org> |
| 7 * Copyright (C) 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserved. | 7 * Copyright (C) 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserved. |
| 8 * Copyright (C) 2012, 2013 Intel Corporation. All rights reserved. | 8 * Copyright (C) 2012, 2013 Intel Corporation. All rights reserved. |
| 9 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. | 9 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. |
| 10 * | 10 * |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 | 114 |
| 115 CanvasRenderingContext2D::~CanvasRenderingContext2D() | 115 CanvasRenderingContext2D::~CanvasRenderingContext2D() |
| 116 { | 116 { |
| 117 #if !ASSERT_DISABLED | 117 #if !ASSERT_DISABLED |
| 118 unwindStateStack(); | 118 unwindStateStack(); |
| 119 #endif | 119 #endif |
| 120 } | 120 } |
| 121 | 121 |
| 122 bool CanvasRenderingContext2D::isAccelerated() const | 122 bool CanvasRenderingContext2D::isAccelerated() const |
| 123 { | 123 { |
| 124 if (!canvas()->hasCreatedImageBuffer()) | 124 if (!canvas()->existingDrawingContext()) |
| 125 return false; | 125 return false; |
| 126 GraphicsContext* context = drawingContext(); | 126 GraphicsContext* context = drawingContext(); |
| 127 return context && context->isAccelerated(); | 127 return context && context->isAccelerated(); |
| 128 } | 128 } |
| 129 | 129 |
| 130 void CanvasRenderingContext2D::reset() | 130 void CanvasRenderingContext2D::reset() |
| 131 { | 131 { |
| 132 unwindStateStack(); | 132 unwindStateStack(); |
| 133 m_stateStack.resize(1); | 133 m_stateStack.resize(1); |
| 134 m_stateStack.first() = State(); | 134 m_stateStack.first() = State(); |
| (...skipping 2297 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2432 const int focusRingWidth = 5; | 2432 const int focusRingWidth = 5; |
| 2433 const int focusRingOutline = 0; | 2433 const int focusRingOutline = 0; |
| 2434 c->drawFocusRing(path, focusRingWidth, focusRingOutline, focusRingColor); | 2434 c->drawFocusRing(path, focusRingWidth, focusRingOutline, focusRingColor); |
| 2435 | 2435 |
| 2436 c->restore(); | 2436 c->restore(); |
| 2437 | 2437 |
| 2438 didDraw(dirtyRect); | 2438 didDraw(dirtyRect); |
| 2439 } | 2439 } |
| 2440 | 2440 |
| 2441 } // namespace WebCore | 2441 } // namespace WebCore |
| OLD | NEW |