At run-time the request parameter of void navigationRequested(QObject* request) is actually of type NavigationRequest: class NavigationRequest : public QObject { Q_OBJECT Q_PROPERTY(QUrl url READ url CONSTANT FINAL) Q_PROPERTY(int button READ button CONSTANT FINAL) Q_PROPERTY(int modifiers READ modifiers CONSTANT FINAL) Q_PROPERTY(int action READ action WRITE setAction NOTIFY actionChanged FINAL) Q_SIGNALS: void actionChanged(); }; This type should be registered with QML in order to support QML type revisions.
Created attachment 117941 [details] Patch
Comment on attachment 117941 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=117941&action=review No test? > Source/WebKit2/UIProcess/API/qt/qwebnavigationrequest_p.h:38 > + QWebNavigationRequest(const QUrl& url, Qt::MouseButton button, Qt::KeyboardModifiers modifiers, QObject* parent = 0); What about touch? I know that is not really part of this patch, but we are exposing it so we should think about such things. Maybe it is time to look at how MS exposed touch/mouse/pointers in their IE10 api - like if there is some abstraction
Comment on attachment 117941 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=117941&action=review r- because of the leak. Looks good otherwise. > Source/WebKit2/UIProcess/API/qt/qwebnavigationrequest.cpp:48 > + , d(new QWebNavigationRequestPrivate(url, button, modifiers)) Ooops, the d-pointer is leaked :)
Created attachment 118567 [details] Patch
Comment on attachment 118567 [details] Patch Clearing flags on attachment: 118567 Committed r102502: <http://trac.webkit.org/changeset/102502>
All reviewed patches have been landed. Closing bug.