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 @@ ...@@ -26,8 +26,8 @@
using namespace Konsole; using namespace Konsole;
CompositeWidgetFocusWatcher::CompositeWidgetFocusWatcher(QWidget *compositeWidget, QObject *parent) CompositeWidgetFocusWatcher::CompositeWidgetFocusWatcher(QWidget *compositeWidget)
: QObject(parent) : QObject(compositeWidget)
, _compositeWidget(compositeWidget) , _compositeWidget(compositeWidget)
{ {
registerWidgetAndChildren(compositeWidget); registerWidgetAndChildren(compositeWidget);
......
...@@ -37,7 +37,7 @@ class CompositeWidgetFocusWatcher : public QObject ...@@ -37,7 +37,7 @@ class CompositeWidgetFocusWatcher : public QObject
Q_OBJECT Q_OBJECT
public: public:
explicit CompositeWidgetFocusWatcher(QWidget *compositeWidget, QObject *parent); explicit CompositeWidgetFocusWatcher(QWidget *compositeWidget);
bool eventFilter(QObject *watched, QEvent *event) Q_DECL_OVERRIDE; bool eventFilter(QObject *watched, QEvent *event) Q_DECL_OVERRIDE;
Q_SIGNALS: Q_SIGNALS:
......
...@@ -564,7 +564,7 @@ TerminalDisplay::TerminalDisplay(QWidget* parent) ...@@ -564,7 +564,7 @@ TerminalDisplay::TerminalDisplay(QWidget* parent)
new AutoScrollHandler(this); new AutoScrollHandler(this);
// Keep this last // Keep this last
CompositeWidgetFocusWatcher *focusWatcher = new CompositeWidgetFocusWatcher(this, this); CompositeWidgetFocusWatcher *focusWatcher = new CompositeWidgetFocusWatcher(this);
connect(focusWatcher, &CompositeWidgetFocusWatcher::compositeFocusChanged, connect(focusWatcher, &CompositeWidgetFocusWatcher::compositeFocusChanged,
this, [this](bool focused) {_hasCompositeFocus = focused;}); this, [this](bool focused) {_hasCompositeFocus = focused;});
connect(focusWatcher, &CompositeWidgetFocusWatcher::compositeFocusChanged, 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