D24012: Supress mouse events in KCMs causing window moves

2019-10-03 Thread David Edmundson
This revision was automatically updated to reflect the committed changes.
davidedmundson marked an inline comment as done.
Closed by commit R295:8f0858eb79a9: Supress mouse events in KCMs causing window 
moves (authored by davidedmundson).

REPOSITORY
  R295 KCMUtils

CHANGES SINCE LAST UPDATE
  https://phabricator.kde.org/D24012?vs=66274=67253

REVISION DETAIL
  https://phabricator.kde.org/D24012

AFFECTED FILES
  src/kcmoduleqml.cpp
  src/kcmoduleqml_p.h

To: davidedmundson, #plasma, romangg
Cc: romangg, ngraham, anthonyfieroni, kde-frameworks-devel, LeGast00n, GB_2, 
michaelh, bruns


D24012: Supress mouse events in KCMs causing window moves

2019-09-19 Thread Roman Gilg
romangg added a comment.


  Forgot that KCMUtils is part of Frameworks... And probably doesn't make sense 
to create a bug fix Frameworks release just for that. The KScreen KCM is still 
usable, just moving outputs is difficult but also possible. So just push for 
next Frameworks release.

REPOSITORY
  R295 KCMUtils

BRANCH
  master

REVISION DETAIL
  https://phabricator.kde.org/D24012

To: davidedmundson, #plasma, romangg
Cc: romangg, ngraham, anthonyfieroni, kde-frameworks-devel, LeGast00n, GB_2, 
michaelh, bruns


D24012: Supress mouse events in KCMs causing window moves

2019-09-19 Thread Roman Gilg
romangg accepted this revision.
romangg added a comment.
This revision is now accepted and ready to land.


  Let's get it in the beta. But can you reply to @anthonyfieroni inline reply 
before pushing?

REPOSITORY
  R295 KCMUtils

BRANCH
  master

REVISION DETAIL
  https://phabricator.kde.org/D24012

To: davidedmundson, #plasma, romangg
Cc: romangg, ngraham, anthonyfieroni, kde-frameworks-devel, LeGast00n, GB_2, 
michaelh, bruns


D24012: Supress mouse events in KCMs causing window moves

2019-09-17 Thread Nathaniel Graham
ngraham added a comment.


  +1, fixes the bug.

REPOSITORY
  R295 KCMUtils

REVISION DETAIL
  https://phabricator.kde.org/D24012

To: davidedmundson, #plasma
Cc: ngraham, anthonyfieroni, kde-frameworks-devel, LeGast00n, GB_2, michaelh, 
bruns


D24012: Supress mouse events in KCMs causing window moves

2019-09-17 Thread Anthony Fieroni
anthonyfieroni added inline comments.

INLINE COMMENTS

> kcmoduleqml.cpp:265-268
> +bool rc = KCModule::event(event);
> +if (event->type () == QEvent::MouseButtonPress || event->type() == 
> QEvent::MouseButtonRelease) {
> +event->accept();
> +}

Should we check `if (rc && ...)` if rc is false event is not handled no?

REPOSITORY
  R295 KCMUtils

REVISION DETAIL
  https://phabricator.kde.org/D24012

To: davidedmundson, #plasma
Cc: anthonyfieroni, kde-frameworks-devel, LeGast00n, GB_2, michaelh, ngraham, 
bruns


D24012: Supress mouse events in KCMs causing window moves

2019-09-16 Thread David Edmundson
davidedmundson created this revision.
davidedmundson added a reviewer: Plasma.
Herald added a project: Frameworks.
Herald added a subscriber: kde-frameworks-devel.
davidedmundson requested review of this revision.

REVISION SUMMARY
  If a mouse press is handled by the new input handlers the mouse evnet is
  not accepted at a window level.
  
  This causes the breeze style to start a window drag.
  
  Marking all mouse events as accepted after being processed supresses
  them reaching the widget.
  
  This is noticable in the rewritten kscreen KCM when running on XCB. (it
  would also affect wayland, but the breeze window management is currently
  broken there)

TEST PLAN
  Dragged a monitor in kscreen kcm. The monitor representation moved not the 
whole window

REPOSITORY
  R295 KCMUtils

BRANCH
  master

REVISION DETAIL
  https://phabricator.kde.org/D24012

AFFECTED FILES
  src/kcmoduleqml.cpp
  src/kcmoduleqml_p.h

To: davidedmundson, #plasma
Cc: kde-frameworks-devel, LeGast00n, GB_2, michaelh, ngraham, bruns