How to disable pushbutton after clicking it
I created lots of pushbutton in a buttongroup and add slot and signal to them with` QT DESIGNER`. What I want to do is; after clicking any of the pushbuttons some operation will be done and after all finished the pushbutton should be disabled. How can I disable it(All I know is I can do it with isEnabled and setEnabled and we do not know which button is clicked)
Re: How to disable pushbutton after clicking it
Quote:
and we do not know which button is clicked
QObject::sender()
Re: How to disable pushbutton after clicking it
in a slot, you can use the "sender()"-method to obtain the object which emitted the signal.
edit: *arg* less text and I would have been faster than high_flyer;)
Re: How to disable pushbutton after clicking it
Or even high_flyer, which is who replied before you, not wysota :D
Re: How to disable pushbutton after clicking it
oh yes, I always mix them up because of the "certified developer"-logo :o
Re: How to disable pushbutton after clicking it
I think wysota will mind more to be mixed up with me, then I am with him :)
Re: How to disable pushbutton after clicking it
Quote:
Originally Posted by
FelixB
in a slot, you can use the "sender()"-method to obtain the object which emitted the signal.
I do not know how to use :D
Re: How to disable pushbutton after clicking it
then read the link high_flyer posted. or show us what you tried so far...
Re: How to disable pushbutton after clicking it
hi,
Quote:
I do not know how to use
use qobject_cast to cast the sender();
Bala
Re: How to disable pushbutton after clicking it
Quote:
Originally Posted by
high_flyer
I think wysota will mind more to be mixed up with me, then I am with him :)
Naaa... all stays in the family :) Besides, I'd like to participate in a lets-go-to-mars project too, so I don't mind :cool:
Re: How to disable pushbutton after clicking it
Quote:
I'd like to participate in a lets-go-to-mars project too, so I don't mind
really??
I am sure we can find something for you to chew on! ;)
Re: How to disable pushbutton after clicking it
Quote:
Originally Posted by
high_flyer
I am sure we can find something for you to chew on! ;)
If it involves coding Qt and not speaking German then bring it on! :)
Re: How to disable pushbutton after clicking it
We do all our non embedded coding in Qt.
Project language is English.
Once we get RTEMS running on our hardware depending on time and how much sense it will make we might try to port Qt to RTEMS.
At the moment there is not much to do that I can't do on my own in a relaxed time span.
But as we get nearer to launch (end 2013) we will need quite a bit of work done for the ground station -> Qt Desktop - and then help will be much appreciated.
I'll contact you then again.