From: Christoph Egger Date: Thu, 27 Nov 2014 12:18:03 +0000 (+0100) Subject: Fix widget setup for scripting X-Git-Tag: v0.1~165 X-Git-Url: https://git.siccegge.de//index.cgi?a=commitdiff_plain;h=f04354b5975c943fc0bacbaefb7b4644c37e1948;p=frida%2Ffrida.git Fix widget setup for scripting --- diff --git a/src/gui/widgets/ScriptingDock.hxx b/src/gui/widgets/ScriptingDock.hxx index e070955..ce53191 100644 --- a/src/gui/widgets/ScriptingDock.hxx +++ b/src/gui/widgets/ScriptingDock.hxx @@ -9,14 +9,16 @@ class ScriptingDock : public QDockWidget { public: ScriptingDock(const QString& title, QWidget * parent = 0) - : logger(log4cxx::Logger::getLogger("ScriptingDock")) { - QDockWidget(title, parent); + : QDockWidget(title, parent) + , logger(log4cxx::Logger::getLogger("ScriptingDock")) { + QTabWidget * tab = new QTabWidget; QWidget * widget = new QWidget; - widget->setLayout(layout = new QGridLayout(this)); + widget->setLayout(layout = new QGridLayout); layout->addWidget(browser = new QTextBrowser, 0, 0, 1, 0); layout->addWidget(line = new QLineEdit, 1, 0); layout->addWidget(button = new QPushButton(tr("Evaluate")), 1, 1); - setWidget(widget); + tab->addTab(widget, "GUILE"); + ((QDockWidget*)this)->setWidget(tab); connect(button, SIGNAL(released()), this, SLOT(doEvaluate())); connect(line, SIGNAL(returnPressed()), this, SLOT(doEvaluate())); scm_init_guile();