summaryrefslogtreecommitdiff
path: root/src/mainwindow.cpp
diff options
context:
space:
mode:
authorAndrea Diamantini <adjam7@gmail.com>2011-05-11 23:52:52 +0200
committerAndrea Diamantini <adjam7@gmail.com>2011-05-11 23:52:52 +0200
commit23ae10d14ab7fec087f358af187ae60d6c50812b (patch)
tree9f5e524ecd47b149af8893e8ed273defe618ed80 /src/mainwindow.cpp
parentConvert these extracomment to comment (diff)
downloadrekonq-23ae10d14ab7fec087f358af187ae60d6c50812b.tar.xz
Developer tool: set content editable.
Diffstat (limited to 'src/mainwindow.cpp')
-rw-r--r--src/mainwindow.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index f226c9ee..2ed8fef5 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -245,6 +245,7 @@ void MainWindow::updateToolsMenu()
m_developerMenu->addAction(actionByName(QL1S("web_inspector")));
m_developerMenu->addAction(actionByName(QL1S("page_source")));
m_developerMenu->addAction(actionByName(QL1S("net_analyzer")));
+ m_developerMenu->addAction(actionByName(QL1S("set_editable")));
m_toolsMenu->addAction(m_developerMenu);
if (!ReKonfig::showDeveloperTools())
@@ -544,6 +545,11 @@ void MainWindow::setupActions()
a = new KAction(KIcon("preferences-web-browser-identification"), i18n("Browser Identification"), this);
actionCollection()->addAction(QL1S("UserAgentSettings"), a);
connect(a, SIGNAL(triggered(bool)), this, SLOT(showUserAgentSettings()));
+
+ a = new KAction(KIcon(""), i18n("set editable"), this);
+ a->setCheckable(true);
+ actionCollection()->addAction(QL1S("set_editable"), a);
+ connect(a, SIGNAL(triggered(bool)), this, SLOT(setEditable(bool)));
}
@@ -1578,3 +1584,9 @@ void MainWindow::resizeEvent(QResizeEvent *event)
KMainWindow::resizeEvent(event);
}
+
+
+void MainWindow::setEditable(bool on)
+{
+ currentTab()->page()->setContentEditable(on);
+}