[SCM] WebKit Debian packaging branch, webkit-1.1, updated. upstream/1.1.17-1283-gcf603cf
eric at webkit.org
eric at webkit.org
Tue Jan 5 23:42:33 UTC 2010
The following commit has been merged in the webkit-1.1 branch:
commit 1c14c9df3f0efa0bb00de33fd57749a4bf4fe397
Author: eric at webkit.org <eric at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Fri Dec 4 18:04:54 2009 +0000
2009-12-04 Jocelyn Turcotte <jocelyn.turcotte at nokia.com>
Reviewed by Kenneth Rohde Christiansen.
[Qt] QtLauncher: add a menu to show or hide the web inspector.
https://bugs.webkit.org/show_bug.cgi?id=32149
* QtLauncher/main.cpp:
(WebInspector::WebInspector):
(WebInspector::showEvent):
(WebInspector::hideEvent):
(MainWindow::MainWindow):
(MainWindow::setupUI):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@51701 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit/qt/ChangeLog b/WebKit/qt/ChangeLog
index 5cc4e0c..3253bfc 100644
--- a/WebKit/qt/ChangeLog
+++ b/WebKit/qt/ChangeLog
@@ -1,3 +1,17 @@
+2009-12-04 Jocelyn Turcotte <jocelyn.turcotte at nokia.com>
+
+ Reviewed by Kenneth Rohde Christiansen.
+
+ [Qt] QtLauncher: add a menu to show or hide the web inspector.
+ https://bugs.webkit.org/show_bug.cgi?id=32149
+
+ * QtLauncher/main.cpp:
+ (WebInspector::WebInspector):
+ (WebInspector::showEvent):
+ (WebInspector::hideEvent):
+ (MainWindow::MainWindow):
+ (MainWindow::setupUI):
+
2009-12-04 Kenneth Rohde Christiansen <kenneth at webkit.org>
Reviewed by Antti Koivisto.
diff --git a/WebKit/qt/QtLauncher/main.cpp b/WebKit/qt/QtLauncher/main.cpp
index e416e37..e86b711 100644
--- a/WebKit/qt/QtLauncher/main.cpp
+++ b/WebKit/qt/QtLauncher/main.cpp
@@ -144,6 +144,25 @@ public:
}
};
+class WebInspector : public QWebInspector {
+ Q_OBJECT
+public:
+ WebInspector(QWidget* parent) : QWebInspector(parent) {}
+signals:
+ void visibleChanged(bool nowVisible);
+protected:
+ void showEvent(QShowEvent* event)
+ {
+ QWebInspector::showEvent(event);
+ emit visibleChanged(true);
+ }
+ void hideEvent(QHideEvent* event)
+ {
+ QWebInspector::hideEvent(event);
+ emit visibleChanged(false);
+ }
+};
+
class MainWindow : public QMainWindow
{
Q_OBJECT
@@ -167,7 +186,7 @@ public:
this, SLOT(showLinkHover(const QString&, const QString&)));
connect(view->page(), SIGNAL(windowCloseRequested()), this, SLOT(close()));
- inspector = new QWebInspector(splitter);
+ inspector = new WebInspector(splitter);
inspector->setPage(page);
inspector->hide();
connect(this, SIGNAL(destroyed()), inspector, SLOT(deleteLater()));
@@ -437,13 +456,17 @@ private:
QMenu *toolsMenu = menuBar()->addMenu("&Tools");
toolsMenu->addAction("Select elements...", this, SLOT(selectElements()));
+ QAction* showInspectorAction = toolsMenu->addAction("Show inspector", inspector, SLOT(setVisible(bool)));
+ showInspectorAction->setCheckable(true);
+ showInspectorAction->setShortcuts(QList<QKeySequence>() << QKeySequence(tr("F12")));
+ showInspectorAction->connect(inspector, SIGNAL(visibleChanged(bool)), SLOT(setChecked(bool)));
}
QWebView *view;
QLineEdit *urlEdit;
QProgressBar *progress;
- QWebInspector* inspector;
+ WebInspector* inspector;
QAction *formatMenuAction;
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list