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 Intel Corporation. All rights reserved. | 8 * Copyright (C) 2012 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 1878 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1889 } | 1889 } |
1890 | 1890 |
1891 PassRefPtr<ImageData> CanvasRenderingContext2D::webkitGetImageDataHD(float sx, f
loat sy, float sw, float sh, ExceptionState& es) const | 1891 PassRefPtr<ImageData> CanvasRenderingContext2D::webkitGetImageDataHD(float sx, f
loat sy, float sw, float sh, ExceptionState& es) const |
1892 { | 1892 { |
1893 return getImageData(ImageBuffer::BackingStoreCoordinateSystem, sx, sy, sw, s
h, es); | 1893 return getImageData(ImageBuffer::BackingStoreCoordinateSystem, sx, sy, sw, s
h, es); |
1894 } | 1894 } |
1895 | 1895 |
1896 PassRefPtr<ImageData> CanvasRenderingContext2D::getImageData(ImageBuffer::Coordi
nateSystem coordinateSystem, float sx, float sy, float sw, float sh, ExceptionSt
ate& es) const | 1896 PassRefPtr<ImageData> CanvasRenderingContext2D::getImageData(ImageBuffer::Coordi
nateSystem coordinateSystem, float sx, float sy, float sw, float sh, ExceptionSt
ate& es) const |
1897 { | 1897 { |
1898 if (!canvas()->originClean()) { | 1898 if (!canvas()->originClean()) { |
1899 DEFINE_STATIC_LOCAL(String, consoleMessage, (ASCIILiteral("Unable to get
image data from canvas because the canvas has been tainted by cross-origin data
."))); | 1899 DEFINE_STATIC_LOCAL(String, consoleMessage, ("Unable to get image data f
rom canvas because the canvas has been tainted by cross-origin data.")); |
1900 canvas()->document()->addConsoleMessage(SecurityMessageSource, ErrorMess
ageLevel, consoleMessage); | 1900 canvas()->document()->addConsoleMessage(SecurityMessageSource, ErrorMess
ageLevel, consoleMessage); |
1901 es.throwDOMException(SecurityError); | 1901 es.throwDOMException(SecurityError); |
1902 return 0; | 1902 return 0; |
1903 } | 1903 } |
1904 | 1904 |
1905 if (!sw || !sh) { | 1905 if (!sw || !sh) { |
1906 es.throwDOMException(IndexSizeError); | 1906 es.throwDOMException(IndexSizeError); |
1907 return 0; | 1907 return 0; |
1908 } | 1908 } |
1909 if (!std::isfinite(sx) || !std::isfinite(sy) || !std::isfinite(sw) || !std::
isfinite(sh)) { | 1909 if (!std::isfinite(sx) || !std::isfinite(sy) || !std::isfinite(sw) || !std::
isfinite(sh)) { |
(...skipping 498 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2408 Color focusRingColor = RenderTheme::focusRingColor(); | 2408 Color focusRingColor = RenderTheme::focusRingColor(); |
2409 const int focusRingWidth = 5; | 2409 const int focusRingWidth = 5; |
2410 const int focusRingOutline = 0; | 2410 const int focusRingOutline = 0; |
2411 c->drawFocusRing(path, focusRingWidth, focusRingOutline, focusRingColor); | 2411 c->drawFocusRing(path, focusRingWidth, focusRingOutline, focusRingColor); |
2412 didDraw(path.boundingRect()); | 2412 didDraw(path.boundingRect()); |
2413 | 2413 |
2414 c->restore(); | 2414 c->restore(); |
2415 } | 2415 } |
2416 | 2416 |
2417 } // namespace WebCore | 2417 } // namespace WebCore |
OLD | NEW |