How to make a widget recieve mouseevent?
-
Hello everyone! I am facing a confused issue, I use 3 widget3, one is the under other widgets, the other widgets (widget A and widgetB) are used without parent. The issue is when I use A->show() to show A, I use A->close(),then I use B->show(), A->show(), the A widget is on the top, but QApplication::notify shows that when I click the screen, B widget recieved the event. Do you know why? My Qt is 5.11.x . And I have used activateWindow() and setFocus() , they don't make sense.
-
Hi and welcome to devnet,
Does one of these widgets have their focus handling changed ?
Can you provide a minimal compilable example that shows that behaviour ?
-
Hi and welcome to devnet,
Does one of these widgets have their focus handling changed ?
Can you provide a minimal compilable example that shows that behaviour ?
-
Hi and welcome to devnet,
Does one of these widgets have their focus handling changed ?
Can you provide a minimal compilable example that shows that behaviour ?
-
@SGaist Hi , do you need the code?
By the way, I face this issue on embeded system, when I use this code on PC, seems everything works well.@wohehe said in How to make a widget recieve mouseevent?:
@SGaist Hi , do you need the code?
By the way, I face this issue on embeded system, when I use this code on PC, seems everything works well.A minimal compilable example would be good.
Embedded device ?
Which device ?
Which OS ?
Which QPA backend ?