Title: [90817] trunk/Source/WebKit2
- Revision
- 90817
- Author
- [email protected]
- Date
- 2011-07-12 07:44:33 -0700 (Tue, 12 Jul 2011)
Log Message
[Qt] Forward the touch view scale changes to the tiled drawing area.
https://bugs.webkit.org/show_bug.cgi?id=64357
Reviewed by Kenneth Rohde Christiansen.
The drawing area needs to know the new scale to render tiles accordingly.
* UIProcess/API/qt/qtouchwebpage.cpp:
(QTouchWebPagePrivate::commitScaleChange):
* UIProcess/qt/qtouchwebpageproxy.cpp:
(QTouchWebPageProxy::setContentsScale):
* UIProcess/qt/qtouchwebpageproxy.h:
(QTouchWebPageProxy::drawingArea):
Modified Paths
Diff
Modified: trunk/Source/WebKit2/ChangeLog (90816 => 90817)
--- trunk/Source/WebKit2/ChangeLog 2011-07-12 13:59:01 UTC (rev 90816)
+++ trunk/Source/WebKit2/ChangeLog 2011-07-12 14:44:33 UTC (rev 90817)
@@ -1,3 +1,19 @@
+2011-07-12 Jocelyn Turcotte <[email protected]>
+
+ [Qt] Forward the touch view scale changes to the tiled drawing area.
+ https://bugs.webkit.org/show_bug.cgi?id=64357
+
+ Reviewed by Kenneth Rohde Christiansen.
+
+ The drawing area needs to know the new scale to render tiles accordingly.
+
+ * UIProcess/API/qt/qtouchwebpage.cpp:
+ (QTouchWebPagePrivate::commitScaleChange):
+ * UIProcess/qt/qtouchwebpageproxy.cpp:
+ (QTouchWebPageProxy::setContentsScale):
+ * UIProcess/qt/qtouchwebpageproxy.h:
+ (QTouchWebPageProxy::drawingArea):
+
2011-07-12 Adam Roben <[email protected]>
Export some symbols needed by TestWebKitAPI
Modified: trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebpage.cpp (90816 => 90817)
--- trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebpage.cpp 2011-07-12 13:59:01 UTC (rev 90816)
+++ trunk/Source/WebKit2/UIProcess/API/qt/qtouchwebpage.cpp 2011-07-12 14:44:33 UTC (rev 90817)
@@ -124,7 +124,7 @@
{
ASSERT(m_isChangingScale);
m_isChangingScale = false;
- // FIXME: add webpage support when the view has its proper WKPage subclass.
+ page->setContentsScale(q->scale());
}
void QTouchWebPagePrivate::onScaleChanged()
Modified: trunk/Source/WebKit2/UIProcess/qt/qtouchwebpageproxy.cpp (90816 => 90817)
--- trunk/Source/WebKit2/UIProcess/qt/qtouchwebpageproxy.cpp 2011-07-12 13:59:01 UTC (rev 90816)
+++ trunk/Source/WebKit2/UIProcess/qt/qtouchwebpageproxy.cpp 2011-07-12 14:44:33 UTC (rev 90817)
@@ -21,7 +21,6 @@
#include "config.h"
#include "qtouchwebpageproxy.h"
-#include <TiledDrawingAreaProxy.h>
#include <IntRect.h>
#include <NativeWebTouchEvent.h>
#include <WebEventFactoryQt.h>
@@ -113,6 +112,11 @@
m_webPageProxy->findZoomableAreaForPoint(point);
}
+void QTouchWebPageProxy::setContentsScale(qreal scale)
+{
+ drawingArea()->setContentsScale(scale);
+}
+
void QTouchWebPageProxy::didFindZoomableArea(const IntRect& area)
{
emit zoomableAreaFound(QRect(area));
Modified: trunk/Source/WebKit2/UIProcess/qt/qtouchwebpageproxy.h (90816 => 90817)
--- trunk/Source/WebKit2/UIProcess/qt/qtouchwebpageproxy.h 2011-07-12 13:59:01 UTC (rev 90816)
+++ trunk/Source/WebKit2/UIProcess/qt/qtouchwebpageproxy.h 2011-07-12 14:44:33 UTC (rev 90817)
@@ -25,6 +25,7 @@
#include "DrawingAreaProxy.h"
#include "QtPanGestureRecognizer.h"
#include "QtWebPageProxy.h"
+#include "TiledDrawingAreaProxy.h"
#include "TouchViewInterface.h"
#include <wtf/PassOwnPtr.h>
@@ -40,6 +41,7 @@
void setVisibleArea(const QRectF&);
void setResizesToContentsUsingLayoutSize(const QSize& targetLayoutSize);
void findZoomableAreaForPoint(const QPoint&);
+ void setContentsScale(qreal);
protected:
virtual void paintContent(QPainter* painter, const QRect& area);
@@ -54,6 +56,7 @@
virtual void didFindZoomableArea(const WebCore::IntRect&);
TouchViewInterface* touchViewInterface() const { return static_cast<TouchViewInterface*>(m_viewInterface); }
+ TiledDrawingAreaProxy* drawingArea() const { return static_cast<WebKit::TiledDrawingAreaProxy*>(m_webPageProxy->drawingArea()); }
void touchEvent(QTouchEvent*);
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes