Title: [123867] trunk/Source/WebCore
- Revision
- 123867
- Author
- [email protected]
- Date
- 2012-07-27 05:27:47 -0700 (Fri, 27 Jul 2012)
Log Message
Replace ColorChooserClient::elementRectRelativeToWindow with elementRectRelativeToRootView
https://bugs.webkit.org/show_bug.cgi?id=92488
Reviewed by Kent Tamura.
Changing ColorChooserClient interface to return element rectangle that is relative to root view instead of window.
No new tests. Method is not used yet.
* html/ColorInputType.cpp:
(WebCore::ColorInputType::elementRectRelativeToRootView): Replaced elementRectRelativeToWindow. Returns element rectangle relative to root view.
* html/ColorInputType.h:
(ColorInputType):
* platform/ColorChooserClient.h:
(ColorChooserClient):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (123866 => 123867)
--- trunk/Source/WebCore/ChangeLog 2012-07-27 11:52:15 UTC (rev 123866)
+++ trunk/Source/WebCore/ChangeLog 2012-07-27 12:27:47 UTC (rev 123867)
@@ -1,3 +1,21 @@
+2012-07-27 Keishi Hattori <[email protected]>
+
+ Replace ColorChooserClient::elementRectRelativeToWindow with elementRectRelativeToRootView
+ https://bugs.webkit.org/show_bug.cgi?id=92488
+
+ Reviewed by Kent Tamura.
+
+ Changing ColorChooserClient interface to return element rectangle that is relative to root view instead of window.
+
+ No new tests. Method is not used yet.
+
+ * html/ColorInputType.cpp:
+ (WebCore::ColorInputType::elementRectRelativeToRootView): Replaced elementRectRelativeToWindow. Returns element rectangle relative to root view.
+ * html/ColorInputType.h:
+ (ColorInputType):
+ * platform/ColorChooserClient.h:
+ (ColorChooserClient):
+
2012-07-27 Dominik Röttsches <[email protected]>
[Cairo] Add complex font drawing using HarfbuzzNG
Modified: trunk/Source/WebCore/html/ColorInputType.cpp (123866 => 123867)
--- trunk/Source/WebCore/html/ColorInputType.cpp 2012-07-27 11:52:15 UTC (rev 123866)
+++ trunk/Source/WebCore/html/ColorInputType.cpp 2012-07-27 12:27:47 UTC (rev 123867)
@@ -201,11 +201,9 @@
return shadow ? toHTMLElement(shadow->firstChild()->firstChild()) : 0;
}
-IntRect ColorInputType::elementRectRelativeToWindow() const
+IntRect ColorInputType::elementRectRelativeToRootView() const
{
- RenderObject* renderer = element()->renderer();
- ASSERT(renderer);
- return pixelSnappedIntRect(renderer->view()->frameView()->contentsToWindow(renderer->absoluteBoundingBoxRect()));
+ return element()->document()->view()->contentsToRootView(element()->getPixelSnappedRect());
}
Color ColorInputType::currentColor()
Modified: trunk/Source/WebCore/html/ColorInputType.h (123866 => 123867)
--- trunk/Source/WebCore/html/ColorInputType.h 2012-07-27 11:52:15 UTC (rev 123866)
+++ trunk/Source/WebCore/html/ColorInputType.h 2012-07-27 12:27:47 UTC (rev 123867)
@@ -46,7 +46,7 @@
// ColorChooserClient implementation.
virtual void didChooseColor(const Color&) OVERRIDE;
virtual void didEndChooser() OVERRIDE;
- virtual IntRect elementRectRelativeToWindow() const OVERRIDE;
+ virtual IntRect elementRectRelativeToRootView() const OVERRIDE;
virtual Color currentColor() OVERRIDE;
virtual bool shouldShowSuggestions() const OVERRIDE;
virtual Vector<Color> suggestions() const OVERRIDE;
Modified: trunk/Source/WebCore/platform/ColorChooserClient.h (123866 => 123867)
--- trunk/Source/WebCore/platform/ColorChooserClient.h 2012-07-27 11:52:15 UTC (rev 123866)
+++ trunk/Source/WebCore/platform/ColorChooserClient.h 2012-07-27 12:27:47 UTC (rev 123867)
@@ -19,7 +19,7 @@
virtual void didChooseColor(const Color&) = 0;
virtual void didEndChooser() = 0;
- virtual IntRect elementRectRelativeToWindow() const = 0;
+ virtual IntRect elementRectRelativeToRootView() const = 0;
virtual Color currentColor() = 0;
virtual bool shouldShowSuggestions() const = 0;
virtual Vector<Color> suggestions() const = 0;
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes