QPushButton::pressed()
Unsolved
General and Desktop
-
@ivanicy said in QPushButton::pressed():
the function inside the button will execute in loop
what?? What are you trying to achieve exactly?
Do you mean that the signal is triggered repeatedly as long as the button is held down?The signal is only emitted once when the mouse press event is received.
-
Is exactly that. I want to keep the button hold and do the function inside it until I released the button.
-
@ivanicy
Hi
If you make a loop inside a button, you will strangulate
whole application.Its better to use the auto repeat feature
http://doc.qt.io/qt-5/qabstractbutton.html#autoRepeat-propand perform function as long as its repeating the signal
Looping will make you sad :)