Home
Phabricator
Search
Log In
Paste
P467
Masterwork From Distant Lands
Active
Public
Actions
Authored by
davidedmundson
on Sep 16 2019, 8:40 PM.
Edit Paste
Archive Paste
View Raw File
Subscribe
Mute Notifications
Award Token
Flag For Later
Tags
None
Subscribers
None
diff --git a/src/kcmoduleqml.cpp b/src/kcmoduleqml.cpp
index de503ed..846ff5c 100644
--- a/src/kcmoduleqml.cpp
+++ b/src/kcmoduleqml.cpp
@@ -256,6 +256,18 @@ bool KCModuleQml::eventFilter(QObject* watched, QEvent* event)
return KCModule::eventFilter(watched, event);
}
+bool KCModuleQml::event(QEvent *event)
+{
+ // if a mouse press is handled by the new input handlers it is not accepted
+ // this causes the breeze style to start a window drag
+ // mark all mouse events as accepted after being processes
+ bool rc = KCModule::event(event);
+ if (event->type () == QEvent::MouseButtonPress || event->type() == QEvent::MouseButtonRelease) {
+ event->accept();
+ }
+ return rc;
+}
+
void KCModuleQml::focusInEvent(QFocusEvent *event)
{
Q_UNUSED(event)
diff --git a/src/kcmoduleqml_p.h b/src/kcmoduleqml_p.h
index bc89e3a..a17de60 100644
--- a/src/kcmoduleqml_p.h
+++ b/src/kcmoduleqml_p.h
@@ -47,6 +47,7 @@ public Q_SLOTS:
protected:
void focusInEvent(QFocusEvent *event) override;
QSize sizeHint() const override;
+ bool event(QEvent* event) override;
bool eventFilter(QObject* watched, QEvent* event) override;
private:
davidedmundson
edited the content of this paste.
(Show Details)
Sep 16 2019, 8:40 PM
davidedmundson
changed the title of this paste from untitled to
Masterwork From Distant Lands
.
Log In to Comment