summaryrefslogtreecommitdiffstats
path: root/WebKit/qt
diff options
context:
space:
mode:
Diffstat (limited to 'WebKit/qt')
-rw-r--r--WebKit/qt/Api/qgraphicswebview.cpp7
-rw-r--r--WebKit/qt/Api/qwebframe.cpp7
-rw-r--r--WebKit/qt/Api/qwebpage.cpp9
-rw-r--r--WebKit/qt/Api/qwebpage_p.h2
-rw-r--r--WebKit/qt/Api/qwebview.cpp7
-rw-r--r--WebKit/qt/ChangeLog116
-rw-r--r--WebKit/qt/WebCoreSupport/ChromeClientQt.cpp50
-rw-r--r--WebKit/qt/WebCoreSupport/ChromeClientQt.h12
8 files changed, 163 insertions, 47 deletions
diff --git a/WebKit/qt/Api/qgraphicswebview.cpp b/WebKit/qt/Api/qgraphicswebview.cpp
index 8a94c9b..53c1494 100644
--- a/WebKit/qt/Api/qgraphicswebview.cpp
+++ b/WebKit/qt/Api/qgraphicswebview.cpp
@@ -711,7 +711,12 @@ void QGraphicsWebView::load(const QNetworkRequest& request,
through the charset attribute of the HTML script tag. Alternatively, the
encoding can also be specified by the web server.
- \sa load(), setContent(), QWebFrame::toHtml()
+ This is a convenience function equivalent to setContent(html, "text/html", baseUrl).
+
+ \warning This function works only for HTML, for other mime types (i.e. XHTML, SVG)
+ setContent() should be used instead.
+
+ \sa load(), setContent(), QWebFrame::toHtml(), QWebFrame::setContent()
*/
void QGraphicsWebView::setHtml(const QString& html, const QUrl& baseUrl)
{
diff --git a/WebKit/qt/Api/qwebframe.cpp b/WebKit/qt/Api/qwebframe.cpp
index f10d5b4..e90367e 100644
--- a/WebKit/qt/Api/qwebframe.cpp
+++ b/WebKit/qt/Api/qwebframe.cpp
@@ -793,9 +793,14 @@ void QWebFrame::load(const QNetworkRequest &req,
script can be specified through the charset attribute of the HTML script tag. It is also possible
for the encoding to be specified by web server.
+ This is a convenience function equivalent to setContent(html, "text/html", baseUrl).
+
\note This method will not affect session or global history for the frame.
- \sa toHtml(), setContent()
+ \warning This function works only for HTML, for other mime types (i.e. XHTML, SVG)
+ setContent() should be used instead.
+
+ \sa toHtml(), setContent(), load()
*/
void QWebFrame::setHtml(const QString &html, const QUrl &baseUrl)
{
diff --git a/WebKit/qt/Api/qwebpage.cpp b/WebKit/qt/Api/qwebpage.cpp
index fa49293..a8bd06a 100644
--- a/WebKit/qt/Api/qwebpage.cpp
+++ b/WebKit/qt/Api/qwebpage.cpp
@@ -1218,14 +1218,7 @@ typedef struct {
void QWebPagePrivate::dynamicPropertyChangeEvent(QDynamicPropertyChangeEvent* event)
{
if (event->propertyName() == "_q_viewMode") {
- QString mode = q->property("_q_viewMode").toString();
- if (mode != viewMode) {
- viewMode = mode;
- WebCore::Frame* frame = QWebFramePrivate::core(q->mainFrame());
- WebCore::FrameView* view = frame->view();
- frame->document()->updateStyleSelector();
- view->layout();
- }
+ page->setViewMode(Page::stringToViewMode(q->property("_q_viewMode").toString()));
} else if (event->propertyName() == "_q_HTMLTokenizerChunkSize") {
int chunkSize = q->property("_q_HTMLTokenizerChunkSize").toInt();
q->handle()->page->setCustomHTMLTokenizerChunkSize(chunkSize);
diff --git a/WebKit/qt/Api/qwebpage_p.h b/WebKit/qt/Api/qwebpage_p.h
index 44ceb87..cf4ab88 100644
--- a/WebKit/qt/Api/qwebpage_p.h
+++ b/WebKit/qt/Api/qwebpage_p.h
@@ -201,8 +201,6 @@ public:
QWebInspector* inspector;
bool inspectorIsInternalOnly; // True if created through the Inspect context menu action
Qt::DropAction m_lastDropAction;
-
- QString viewMode;
static bool drtRun;
};
diff --git a/WebKit/qt/Api/qwebview.cpp b/WebKit/qt/Api/qwebview.cpp
index 3daa045..773c79a 100644
--- a/WebKit/qt/Api/qwebview.cpp
+++ b/WebKit/qt/Api/qwebview.cpp
@@ -470,7 +470,12 @@ void QWebView::load(const QNetworkRequest &request,
through the charset attribute of the HTML script tag. Alternatively, the
encoding can also be specified by the web server.
- \sa load(), setContent(), QWebFrame::toHtml()
+ This is a convenience function equivalent to setContent(html, "text/html", baseUrl).
+
+ \warning This function works only for HTML, for other mime types (i.e. XHTML, SVG)
+ setContent() should be used instead.
+
+ \sa load(), setContent(), QWebFrame::toHtml(), QWebFrame::setContent()
*/
void QWebView::setHtml(const QString &html, const QUrl &baseUrl)
{
diff --git a/WebKit/qt/ChangeLog b/WebKit/qt/ChangeLog
index 455fd89..b49385a 100644
--- a/WebKit/qt/ChangeLog
+++ b/WebKit/qt/ChangeLog
@@ -1,3 +1,119 @@
+2010-07-27 Luiz Agostini <luiz.agostini@openbossa.org>
+
+ Reviewed by Darin Fisher.
+
+ PopupMenu refactoring in preparation to WebKit2
+ https://bugs.webkit.org/show_bug.cgi?id=42592
+
+ As ChromeClient was made responsible for providing PopupMenu and SearchPopupMenu
+ instances, concrete classes that inherit from ChromeClient needed to be changed to
+ implement the new methods.
+
+ * WebCoreSupport/ChromeClientQt.cpp:
+ (WebCore::ChromeClientQt::selectItemWritingDirectionIsNatural):
+ (WebCore::ChromeClientQt::createPopupMenu):
+ (WebCore::ChromeClientQt::createSearchPopupMenu):
+ * WebCoreSupport/ChromeClientQt.h:
+
+2010-08-02 Jeremy Orlow <jorlow@chromium.org>
+
+ Speculative revert of 64425 due to Chromium instability
+ https://bugs.webkit.org/show_bug.cgi?id=43347
+
+ * WebCoreSupport/ChromeClientQt.cpp:
+ * WebCoreSupport/ChromeClientQt.h:
+
+2010-07-27 Luiz Agostini <luiz.agostini@openbossa.org>
+
+ Reviewed by Darin Fisher.
+
+ PopupMenu refactoring in preparation to WebKit2
+ https://bugs.webkit.org/show_bug.cgi?id=42592
+
+ As ChromeClient was made responsible for providing PopupMenu and SearchPopupMenu
+ instances, concrete classes that inherit from ChromeClient needed to be changed to
+ implement the new methods.
+
+ * WebCoreSupport/ChromeClientQt.cpp:
+ (WebCore::ChromeClientQt::selectItemWritingDirectionIsNatural):
+ (WebCore::ChromeClientQt::createPopupMenu):
+ (WebCore::ChromeClientQt::createSearchPopupMenu):
+ * WebCoreSupport/ChromeClientQt.h:
+
+2010-07-31 Sheriff Bot <webkit.review.bot@gmail.com>
+
+ Unreviewed, rolling out r64422.
+ http://trac.webkit.org/changeset/64422
+ https://bugs.webkit.org/show_bug.cgi?id=43304
+
+ Build fixes are needed for Snow Leopard and Windows.
+ (Requested by lca on #webkit).
+
+ * WebCoreSupport/ChromeClientQt.cpp:
+ * WebCoreSupport/ChromeClientQt.h:
+
+2010-07-27 Luiz Agostini <luiz.agostini@openbossa.org>
+
+ Reviewed by Darin Fisher.
+
+ PopupMenu refactoring in preparation to WebKit2
+ https://bugs.webkit.org/show_bug.cgi?id=42592
+
+ As ChromeClient was made responsible for providing PopupMenu and SearchPopupMenu
+ instances, concrete classes that inherit from ChromeClient needed to be changed to
+ implement the new methods.
+
+ * WebCoreSupport/ChromeClientQt.cpp:
+ (WebCore::ChromeClientQt::selectItemWritingDirectionIsNatural):
+ (WebCore::ChromeClientQt::createPopupMenu):
+ (WebCore::ChromeClientQt::createSearchPopupMenu):
+ * WebCoreSupport/ChromeClientQt.h:
+
+2010-07-30 Luiz Agostini <luiz.agostini@openbossa.org>
+
+ Reviewed by Simon Fraser.
+
+ Enabling view modes to all platforms
+ https://bugs.webkit.org/show_bug.cgi?id=37505
+
+ As view mode media feature is now supported by WebCore there is no need
+ to keep its implementation here. QtWebKit now uses WebCore's view mode media feature
+ implementation.
+
+ * Api/qwebpage.cpp:
+ (QWebPagePrivate::dynamicPropertyChangeEvent):
+ * Api/qwebpage_p.h:
+ * WebCoreSupport/ChromeClientQt.cpp:
+ * WebCoreSupport/ChromeClientQt.h:
+
+2010-07-30 Joseph Pecoraro <joepeck@webkit.org>
+
+ Reviewed by David Kilzer.
+
+ Limit ApplicationCache Total and Per-Origin Storage Capacity (Quotas)
+ https://bugs.webkit.org/show_bug.cgi?id=40627
+
+ * WebCoreSupport/ChromeClientQt.cpp:
+ (WebCore::ChromeClientQt::reachedApplicationCacheOriginQuota):
+ * WebCoreSupport/ChromeClientQt.h:
+
+2010-07-29 Alexis Menard <alexis.menard@nokia.com>
+
+ Reviewed by Antonio Gomes.
+
+ QWebFrame and QWebView documentation fix.
+
+ The QWebFrame and the QWebView setHtml() methods are a bit confusing.
+ There are a few registered bugs in Webkit's bugzilla that source is
+ in a bad usage of the function.
+ Additional information were added.
+
+ https://bugs.webkit.org/show_bug.cgi?id=31115
+
+ * Api/qgraphicswebview.cpp:
+ * Api/qwebframe.cpp:
+ * Api/qwebview.cpp:
+
2010-07-28 Kim Grönholm <kim.1.gronholm@nokia.com>
Reviewed by Antonio Gomes.
diff --git a/WebKit/qt/WebCoreSupport/ChromeClientQt.cpp b/WebKit/qt/WebCoreSupport/ChromeClientQt.cpp
index 2c64a78..a0bac72 100644
--- a/WebKit/qt/WebCoreSupport/ChromeClientQt.cpp
+++ b/WebKit/qt/WebCoreSupport/ChromeClientQt.cpp
@@ -1,6 +1,7 @@
/*
* Copyright (C) 2006 Zack Rusin <zack@kde.org>
* Copyright (C) 2006 Apple Computer, Inc. All rights reserved.
+ * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
*
* All rights reserved.
*
@@ -45,6 +46,7 @@
#include "NotImplemented.h"
#include "NotificationPresenterClientQt.h"
#include "PageClientQt.h"
+#include "PopupMenuQt.h"
#if defined(Q_WS_MAEMO_5)
#include "QtMaemoWebPopup.h"
#else
@@ -52,6 +54,7 @@
#endif
#include "QWebPageClient.h"
#include "ScrollbarTheme.h"
+#include "SearchPopupMenuQt.h"
#include "SecurityOrigin.h"
#include "ViewportArguments.h"
#include "WindowFeatures.h"
@@ -483,6 +486,11 @@ void ChromeClientQt::reachedMaxAppCacheSize(int64_t)
// FIXME: Free some space.
notImplemented();
}
+
+void ChromeClientQt::reachedApplicationCacheOriginQuota(SecurityOrigin*)
+{
+ notImplemented();
+}
#endif
#if ENABLE(NOTIFICATIONS)
@@ -598,33 +606,6 @@ QtAbstractWebPopup* ChromeClientQt::createSelectPopup()
#endif
}
-#if ENABLE(WIDGETS_10_SUPPORT)
-bool ChromeClientQt::isWindowed()
-{
- return m_webPage->d->viewMode == "windowed";
-}
-
-bool ChromeClientQt::isFloating()
-{
- return m_webPage->d->viewMode == "floating";
-}
-
-bool ChromeClientQt::isFullscreen()
-{
- return m_webPage->d->viewMode == "fullscreen";
-}
-
-bool ChromeClientQt::isMaximized()
-{
- return m_webPage->d->viewMode == "maximized";
-}
-
-bool ChromeClientQt::isMinimized()
-{
- return m_webPage->d->viewMode == "minimized";
-}
-#endif
-
void ChromeClientQt::didReceiveViewportArguments(Frame* frame, const ViewportArguments& arguments) const
{
if (m_webPage->mainFrame()->d->initialLayoutComplete)
@@ -644,4 +625,19 @@ void ChromeClientQt::didReceiveViewportArguments(Frame* frame, const ViewportArg
emit m_webPage->viewportChangeRequested(hints);
}
+bool ChromeClientQt::selectItemWritingDirectionIsNatural()
+{
+ return false;
+}
+
+PassRefPtr<PopupMenu> ChromeClientQt::createPopupMenu(PopupMenuClient* client) const
+{
+ return adoptRef(new PopupMenuQt(client));
+}
+
+PassRefPtr<SearchPopupMenu> ChromeClientQt::createSearchPopupMenu(PopupMenuClient* client) const
+{
+ return adoptRef(new SearchPopupMenuQt(client));
+}
+
} // namespace WebCore
diff --git a/WebKit/qt/WebCoreSupport/ChromeClientQt.h b/WebKit/qt/WebCoreSupport/ChromeClientQt.h
index 70b4a25..aab2813 100644
--- a/WebKit/qt/WebCoreSupport/ChromeClientQt.h
+++ b/WebKit/qt/WebCoreSupport/ChromeClientQt.h
@@ -1,5 +1,6 @@
/*
* Copyright (C) 2006 Zack Rusin <zack@kde.org>
+ * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
*
* All rights reserved.
*
@@ -131,6 +132,7 @@ namespace WebCore {
#endif
#if ENABLE(OFFLINE_WEB_APPLICATIONS)
virtual void reachedMaxAppCacheSize(int64_t spaceNeeded);
+ virtual void reachedApplicationCacheOriginQuota(SecurityOrigin*);
#endif
#if ENABLE(NOTIFICATIONS)
@@ -168,13 +170,9 @@ namespace WebCore {
virtual void requestGeolocationPermissionForFrame(Frame*, Geolocation*);
virtual void cancelGeolocationPermissionRequestForFrame(Frame*, Geolocation*) { }
-#if ENABLE(WIDGETS_10_SUPPORT)
- virtual bool isWindowed();
- virtual bool isFloating();
- virtual bool isFullscreen();
- virtual bool isMaximized();
- virtual bool isMinimized();
-#endif
+ virtual bool selectItemWritingDirectionIsNatural();
+ virtual PassRefPtr<PopupMenu> createPopupMenu(PopupMenuClient*) const;
+ virtual PassRefPtr<SearchPopupMenu> createSearchPopupMenu(PopupMenuClient*) const;
QtAbstractWebPopup* createSelectPopup();