PDA

View Full Version : Question about resizeEvent



SkripT
28th February 2006, 17:06
Hi all, I'm programming an applicattion and I need to know everytime that a widget changes it's size. Currently, I emit a signal everytime that the widget receives a resizeEvent. The problem is that if connect this signal with its respective slot before the widget is shown, in the moment that I make this widget visible, the slot is executed because the widget has changed its size to its initial size. I would like not to deal with this first case. A solution is making the conection inmediately after that I call to show. I've tried to make the conection in the show event of the widget but the slot is still executed at the moment that I make the widget visible. And here's my questions: making the conection inmediately after calling to show garantees that the slot is never exectuted at the moment that the widget is shown in any case? Does anybody knows another solution to solve this problem?

Many thanks.

yogeshm02
28th February 2006, 17:13
Try
QCoreApplication::processEvents() before the connect statement.