[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
yael.aharon at nokia.com
yael.aharon at nokia.com
Wed Dec 22 16:10:13 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit d081a97ab56edb81e04c8330fec021776a9f51f1
Author: yael.aharon at nokia.com <yael.aharon at nokia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Fri Nov 19 10:31:26 2010 +0000
2010-11-19 Yael Aharon <yael.aharon at nokia.com>
Reviewed by Antonio Gomes.
[Qt] Focus ring does not show for image maps
https://bugs.webkit.org/show_bug.cgi?id=49615
* platform/qt/fast/images/imagemap-focus-ring-expected.checksum: Added.
* platform/qt/fast/images/imagemap-focus-ring-expected.png: Added.
* platform/qt/fast/images/imagemap-focus-ring-expected.txt: Added.
2010-11-19 Yael Aharon <yael.aharon at nokia.com>
Reviewed by Antonio Gomes.
[Qt] Focus ring does not show for image maps
https://bugs.webkit.org/show_bug.cgi?id=49615
Draw a focus ring for the paths surrounding the focus ring of image map area.
Provide Qt specific results for the test fast/images/imagemap-focus-ring.html.
* platform/graphics/qt/GraphicsContextQt.cpp:
(WebCore::GraphicsContext::drawFocusRing):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@72371 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 6b69e9c..fad7d3c 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,14 @@
+2010-11-19 Yael Aharon <yael.aharon at nokia.com>
+
+ Reviewed by Antonio Gomes.
+
+ [Qt] Focus ring does not show for image maps
+ https://bugs.webkit.org/show_bug.cgi?id=49615
+
+ * platform/qt/fast/images/imagemap-focus-ring-expected.checksum: Added.
+ * platform/qt/fast/images/imagemap-focus-ring-expected.png: Added.
+ * platform/qt/fast/images/imagemap-focus-ring-expected.txt: Added.
+
2010-11-18 David Levin <levin at chromium.org>
[chromium] Update/Add baselines for r72362 and r72355.
diff --git a/LayoutTests/platform/qt/fast/images/imagemap-focus-ring-expected.checksum b/LayoutTests/platform/qt/fast/images/imagemap-focus-ring-expected.checksum
new file mode 100644
index 0000000..7cc785e
--- /dev/null
+++ b/LayoutTests/platform/qt/fast/images/imagemap-focus-ring-expected.checksum
@@ -0,0 +1 @@
+8dde1dc86444be23b879a85cc6c9fa39
\ No newline at end of file
diff --git a/LayoutTests/platform/qt/fast/images/imagemap-focus-ring-expected.png b/LayoutTests/platform/qt/fast/images/imagemap-focus-ring-expected.png
new file mode 100644
index 0000000..9534b52
Binary files /dev/null and b/LayoutTests/platform/qt/fast/images/imagemap-focus-ring-expected.png differ
diff --git a/LayoutTests/platform/qt/fast/images/imagemap-focus-ring-expected.txt b/LayoutTests/platform/qt/fast/images/imagemap-focus-ring-expected.txt
new file mode 100644
index 0000000..929bd4d
--- /dev/null
+++ b/LayoutTests/platform/qt/fast/images/imagemap-focus-ring-expected.txt
@@ -0,0 +1,16 @@
+layer at (0,0) size 800x600
+ RenderView at (0,0) size 800x600
+layer at (0,0) size 800x600
+ RenderBlock {HTML} at (0,0) size 800x600
+ RenderBody {BODY} at (8,8) size 784x584
+ RenderBlock {P} at (0,0) size 784x42
+ RenderText {#text} at (0,0) size 777x42
+ text run at (0,0) width 777: "Assuming the port-specific theme draws focus rings, this test can be used to ensure that a focus ring is drawn for an"
+ text run at (0,21) width 666: "imagemap. This test PASSED if a focus ring is drawn around the <area> in the imagemap (below)."
+ RenderBlock (anonymous) at (0,58) size 784x128
+ RenderInline {MAP} at (0,0) size 0x0
+ RenderText {#text} at (0,0) size 0x0
+ RenderText {#text} at (0,0) size 0x0
+ RenderText {#text} at (0,0) size 0x0
+ RenderImage {IMG} at (0,0) size 128x128
+ RenderText {#text} at (0,0) size 0x0
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 9aef4ce..0ae4318 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,16 @@
+2010-11-19 Yael Aharon <yael.aharon at nokia.com>
+
+ Reviewed by Antonio Gomes.
+
+ [Qt] Focus ring does not show for image maps
+ https://bugs.webkit.org/show_bug.cgi?id=49615
+
+ Draw a focus ring for the paths surrounding the focus ring of image map area.
+ Provide Qt specific results for the test fast/images/imagemap-focus-ring.html.
+
+ * platform/graphics/qt/GraphicsContextQt.cpp:
+ (WebCore::GraphicsContext::drawFocusRing):
+
2010-11-01 MORITA Hajime <morrita at google.com>
Reviewed by David Hyatt.
diff --git a/WebCore/platform/graphics/qt/GraphicsContextQt.cpp b/WebCore/platform/graphics/qt/GraphicsContextQt.cpp
index 06e1e1c..87e3b50 100644
--- a/WebCore/platform/graphics/qt/GraphicsContextQt.cpp
+++ b/WebCore/platform/graphics/qt/GraphicsContextQt.cpp
@@ -815,13 +815,43 @@ void GraphicsContext::clipPath(WindRule clipRule)
void GraphicsContext::drawFocusRing(const Vector<Path>& paths, int width, int offset, const Color& color)
{
- // FIXME: implement
+ if (paintingDisabled() || !color.isValid())
+ return;
+
+ unsigned pathCount = paths.size();
+
+ if (!pathCount)
+ return;
+
+ QPainter* p = m_data->p();
+ const bool antiAlias = p->testRenderHint(QPainter::Antialiasing);
+ p->setRenderHint(QPainter::Antialiasing, m_data->antiAliasingForRectsAndLines);
+
+ const QPen oldPen = p->pen();
+ const QBrush oldBrush = p->brush();
+
+ QPen nPen = p->pen();
+ nPen.setColor(color);
+ p->setBrush(Qt::NoBrush);
+ nPen.setStyle(Qt::DotLine);
+ p->setPen(nPen);
+
+ QPainterPath path;
+ for (int i = 0; i < pathCount; ++i)
+ path.addPath(paths[i].platformPath());
+ QPainterPathStroker stroker;
+ QPainterPath newPath = stroker.createStroke(path);
+ p->strokePath(newPath, nPen);
+ p->setPen(oldPen);
+ p->setBrush(oldBrush);
+
+ p->setRenderHint(QPainter::Antialiasing, antiAlias);
}
/**
- * Focus ring handling is not handled here. Qt style in
+ * Focus ring handling for form controls is not handled here. Qt style in
* RenderTheme handles drawing focus on widgets which
- * need it.
+ * need it. It is still handled here for links.
*/
void GraphicsContext::drawFocusRing(const Vector<IntRect>& rects, int /* width */, int /* offset */, const Color& color)
{
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list