summaryrefslogtreecommitdiffstats
path: root/WebKit/qt/QtLauncher
diff options
context:
space:
mode:
authorSteve Block <steveblock@google.com>2009-11-05 09:23:40 +0000
committerSteve Block <steveblock@google.com>2009-11-10 22:41:12 +0000
commitcac0f67c402d107cdb10971b95719e2ff9c7c76b (patch)
treed182c7f87211c6f201a5f038e332336493ebdbe7 /WebKit/qt/QtLauncher
parent4b2ef0f288e7c6c4602f621b7a0e9feed304b70e (diff)
downloadexternal_webkit-cac0f67c402d107cdb10971b95719e2ff9c7c76b.zip
external_webkit-cac0f67c402d107cdb10971b95719e2ff9c7c76b.tar.gz
external_webkit-cac0f67c402d107cdb10971b95719e2ff9c7c76b.tar.bz2
Merge webkit.org at r50258 : Initial merge by git.
Change-Id: I1a9e1dc4ed654b69174ad52a4f031a07240f37b0
Diffstat (limited to 'WebKit/qt/QtLauncher')
-rw-r--r--WebKit/qt/QtLauncher/QtLauncher.pro5
-rw-r--r--WebKit/qt/QtLauncher/main.cpp16
2 files changed, 18 insertions, 3 deletions
diff --git a/WebKit/qt/QtLauncher/QtLauncher.pro b/WebKit/qt/QtLauncher/QtLauncher.pro
index 5b10dea..133869c 100644
--- a/WebKit/qt/QtLauncher/QtLauncher.pro
+++ b/WebKit/qt/QtLauncher/QtLauncher.pro
@@ -10,4 +10,7 @@ QT += network
macx:QT+=xml
QMAKE_RPATHDIR = $$OUTPUT_DIR/lib $$QMAKE_RPATHDIR
-symbian:TARGET.UID3 = 0xA000E543
+symbian {
+ TARGET.UID3 = 0xA000E543
+ TARGET.CAPABILITY = ReadUserData WriteUserData NetworkServices
+}
diff --git a/WebKit/qt/QtLauncher/main.cpp b/WebKit/qt/QtLauncher/main.cpp
index 8cc8a09..e3c6116 100644
--- a/WebKit/qt/QtLauncher/main.cpp
+++ b/WebKit/qt/QtLauncher/main.cpp
@@ -34,6 +34,7 @@
#include <qwebview.h>
#include <qwebframe.h>
#include <qwebsettings.h>
+#include <qwebplugindatabase.h>
#include <qwebelement.h>
#include <qwebinspector.h>
@@ -232,6 +233,16 @@ protected slots:
formatMenuAction->setVisible(on);
}
+ void dumpPlugins() {
+ QList<QWebPluginInfo> plugins = QWebSettings::pluginDatabase()->plugins();
+ foreach (const QWebPluginInfo plugin, plugins) {
+ qDebug() << "Plugin:" << plugin.name();
+ foreach (const QWebPluginInfo::MimeType mime, plugin.mimeTypes()) {
+ qDebug() << " " << mime.name;
+ }
+ }
+ }
+
void dumpHtml() {
qDebug() << "HTML: " << view->page()->mainFrame()->toHtml();
}
@@ -242,7 +253,7 @@ protected slots:
QLineEdit::Normal, "a", &ok);
if (ok && !str.isEmpty()) {
- QList<QWebElement> result = view->page()->mainFrame()->findAllElements(str);
+ QWebElementCollection result = view->page()->mainFrame()->findAllElements(str);
foreach (QWebElement e, result)
e.setStyleProperty("background-color", "yellow");
statusBar()->showMessage(QString("%1 element(s) selected").arg(result.count()), 5000);
@@ -292,7 +303,7 @@ private:
QMenu *fileMenu = menuBar()->addMenu("&File");
QAction *newWindow = fileMenu->addAction("New Window", this, SLOT(newWindow()));
#if QT_VERSION >= 0x040400
- fileMenu->addAction(tr("Print"), this, SLOT(print()));
+ fileMenu->addAction(tr("Print"), this, SLOT(print()), QKeySequence::Print);
#endif
QAction* screenshot = fileMenu->addAction("Screenshot", this, SLOT(screenshot()));
fileMenu->addAction("Close", this, SLOT(close()));
@@ -320,6 +331,7 @@ private:
zoomTextOnly->setChecked(false);
viewMenu->addSeparator();
viewMenu->addAction("Dump HTML", this, SLOT(dumpHtml()));
+ viewMenu->addAction("Dump plugins", this, SLOT(dumpPlugins()));
QMenu *formatMenu = new QMenu("F&ormat", this);
formatMenuAction = menuBar()->addMenu(formatMenu);