[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
commit-queue at webkit.org
commit-queue at webkit.org
Wed Dec 22 12:23:28 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit d6f0a223fb578ec8711cb6fde4629ba047daf535
Author: commit-queue at webkit.org <commit-queue at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Fri Aug 20 20:37:58 2010 +0000
2010-08-20 Balazs Kelemen <kb at inf.u-szeged.hu>
Reviewed by Antonio Gomes.
[Qt] Implement cursor change in WebKit2
https://bugs.webkit.org/show_bug.cgi?id=44263
Implemented PageClient::setCursor.
* UIProcess/API/qt/qgraphicswkview.cpp: Added updateCursor slot to be connected to the QWKPage::setCursor signal.
(QGraphicsWKView::QGraphicsWKView):
(QGraphicsWKView::updateCursor): Sets the cursor of the widget.
* UIProcess/API/qt/qgraphicswkview.h:
* UIProcess/API/qt/qwkpage.cpp:
(QWKPagePrivate::setCursor): Added implementation for PageClient::setCursor. Emitting singal through the QWKPage.
* UIProcess/API/qt/qwkpage.h: Added setCursor signal.
* UIProcess/API/qt/qwkpage_p.h:
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@65751 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit2/ChangeLog b/WebKit2/ChangeLog
index 4e5accd..515cd70 100644
--- a/WebKit2/ChangeLog
+++ b/WebKit2/ChangeLog
@@ -1,3 +1,20 @@
+2010-08-20 Balazs Kelemen <kb at inf.u-szeged.hu>
+
+ Reviewed by Antonio Gomes.
+
+ [Qt] Implement cursor change in WebKit2
+ https://bugs.webkit.org/show_bug.cgi?id=44263
+
+ Implemented PageClient::setCursor.
+ * UIProcess/API/qt/qgraphicswkview.cpp: Added updateCursor slot to be connected to the QWKPage::setCursor signal.
+ (QGraphicsWKView::QGraphicsWKView):
+ (QGraphicsWKView::updateCursor): Sets the cursor of the widget.
+ * UIProcess/API/qt/qgraphicswkview.h:
+ * UIProcess/API/qt/qwkpage.cpp:
+ (QWKPagePrivate::setCursor): Added implementation for PageClient::setCursor. Emitting singal through the QWKPage.
+ * UIProcess/API/qt/qwkpage.h: Added setCursor signal.
+ * UIProcess/API/qt/qwkpage_p.h:
+
2010-08-19 David Kilzer <ddkilzer at apple.com>
BUILD FIX: Fix Mac build after Windows WebKit2 changes for Netscape Plug-ins
diff --git a/WebKit2/UIProcess/API/qt/qgraphicswkview.cpp b/WebKit2/UIProcess/API/qt/qgraphicswkview.cpp
index fd0b86e..c61926b 100644
--- a/WebKit2/UIProcess/API/qt/qgraphicswkview.cpp
+++ b/WebKit2/UIProcess/API/qt/qgraphicswkview.cpp
@@ -27,6 +27,7 @@
#include "WebPageNamespace.h"
#include "qwkpage.h"
#include "qwkpage_p.h"
+#include <QCursor>
#include <QGraphicsSceneMouseEvent>
#include <QGraphicsView>
#include <QPainter>
@@ -64,6 +65,7 @@ QGraphicsWKView::QGraphicsWKView(WKPageNamespaceRef pageNamespaceRef, BackingSto
connect(d->page, SIGNAL(loadProgress(int)), this, SIGNAL(loadProgress(int)));
connect(d->page, SIGNAL(initialLayoutCompleted()), this, SIGNAL(initialLayoutCompleted()));
connect(d->page, SIGNAL(urlChanged(const QUrl&)), this, SIGNAL(urlChanged(const QUrl&)));
+ connect(d->page, SIGNAL(cursorChanged(const QCursor&)), this, SLOT(updateCursor(const QCursor&)));
}
QGraphicsWKView::~QGraphicsWKView()
@@ -136,6 +138,11 @@ void QGraphicsWKView::stop()
page()->triggerAction(QWKPage::Stop);
}
+void QGraphicsWKView::updateCursor(const QCursor& cursor)
+{
+ setCursor(cursor);
+}
+
/*! \reimp
*/
QVariant QGraphicsWKView::itemChange(GraphicsItemChange change, const QVariant& value)
diff --git a/WebKit2/UIProcess/API/qt/qgraphicswkview.h b/WebKit2/UIProcess/API/qt/qgraphicswkview.h
index bec220b..375a80f 100644
--- a/WebKit2/UIProcess/API/qt/qgraphicswkview.h
+++ b/WebKit2/UIProcess/API/qt/qgraphicswkview.h
@@ -7,6 +7,10 @@
#include <QGraphicsWidget>
#include "qwkpage.h"
+QT_BEGIN_NAMESPACE
+class QCursor;
+QT_END_NAMESPACE
+
class QGraphicsWKViewPrivate;
WKStringRef WKStringCreateWithQString(QString qString);
@@ -69,6 +73,8 @@ protected:
virtual void hoverMoveEvent(QGraphicsSceneHoverEvent*);
+ Q_SLOT void updateCursor(const QCursor&);
+
private:
QGraphicsWKViewPrivate* d;
friend class QGraphicsWKViewPrivate;
diff --git a/WebKit2/UIProcess/API/qt/qwkpage.cpp b/WebKit2/UIProcess/API/qt/qwkpage.cpp
index b6d2916..5bf3d68 100644
--- a/WebKit2/UIProcess/API/qt/qwkpage.cpp
+++ b/WebKit2/UIProcess/API/qt/qwkpage.cpp
@@ -56,6 +56,13 @@ void QWKPagePrivate::init(const QSize& viewportSize, DrawingAreaProxy* proxy)
page->initializeWebPage(IntSize(viewportSize), proxy);
}
+void QWKPagePrivate::setCursor(const WebCore::Cursor& cursor)
+{
+#ifndef QT_NO_CURSOR
+ emit q->cursorChanged(*cursor.platformCursor());
+#endif
+}
+
void QWKPagePrivate::toolTipChanged(const String&, const String& newTooltip)
{
emit q->statusBarMessage(QString(newTooltip));
diff --git a/WebKit2/UIProcess/API/qt/qwkpage.h b/WebKit2/UIProcess/API/qt/qwkpage.h
index 660d47b..154eb1e 100644
--- a/WebKit2/UIProcess/API/qt/qwkpage.h
+++ b/WebKit2/UIProcess/API/qt/qwkpage.h
@@ -12,6 +12,7 @@
#include <WebKit2/WKPage.h>
#include <WebKit2/WKPageNamespace.h>
+class QCursor;
class QWKGraphicsWidget;
class QWKPagePrivate;
@@ -60,6 +61,7 @@ public:
Q_SIGNAL void initialLayoutCompleted();
Q_SIGNAL void urlChanged(const QUrl&);
Q_SIGNAL void contentsSizeChanged(const QSize&);
+ Q_SIGNAL void cursorChanged(const QCursor&);
protected:
void timerEvent(QTimerEvent*);
diff --git a/WebKit2/UIProcess/API/qt/qwkpage_p.h b/WebKit2/UIProcess/API/qt/qwkpage_p.h
index 0deda34..903ba1e 100644
--- a/WebKit2/UIProcess/API/qt/qwkpage_p.h
+++ b/WebKit2/UIProcess/API/qt/qwkpage_p.h
@@ -47,7 +47,7 @@ public:
#endif // USE(ACCELERATED_COMPOSITING)
virtual void processDidExit() { }
virtual void processDidRevive() { }
- virtual void setCursor(const WebCore::Cursor&) { }
+ virtual void setCursor(const WebCore::Cursor&);
virtual void takeFocus(bool direction) { }
virtual void toolTipChanged(const WTF::String&, const WTF::String&);
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list