Commit 4445c5e1 authored by Gustavo Carneiro's avatar Gustavo Carneiro Committed by Kurt Hindenburg
Browse files

Simplify CompositeWidgetFocusWatcher constructor.

parent 81a3e4f7
......@@ -26,8 +26,8 @@
using namespace Konsole;
CompositeWidgetFocusWatcher::CompositeWidgetFocusWatcher(QWidget *compositeWidget, QObject *parent)
: QObject(parent)
CompositeWidgetFocusWatcher::CompositeWidgetFocusWatcher(QWidget *compositeWidget)
: QObject(compositeWidget)
, _compositeWidget(compositeWidget)
{
registerWidgetAndChildren(compositeWidget);
......
......@@ -37,7 +37,7 @@ class CompositeWidgetFocusWatcher : public QObject
Q_OBJECT
public:
explicit CompositeWidgetFocusWatcher(QWidget *compositeWidget, QObject *parent);
explicit CompositeWidgetFocusWatcher(QWidget *compositeWidget);
bool eventFilter(QObject *watched, QEvent *event) Q_DECL_OVERRIDE;
Q_SIGNALS:
......
......@@ -564,7 +564,7 @@ TerminalDisplay::TerminalDisplay(QWidget* parent)
new AutoScrollHandler(this);
// Keep this last
CompositeWidgetFocusWatcher *focusWatcher = new CompositeWidgetFocusWatcher(this, this);
CompositeWidgetFocusWatcher *focusWatcher = new CompositeWidgetFocusWatcher(this);
connect(focusWatcher, &CompositeWidgetFocusWatcher::compositeFocusChanged,
this, [this](bool focused) {_hasCompositeFocus = focused;});
connect(focusWatcher, &CompositeWidgetFocusWatcher::compositeFocusChanged,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment