I have a custom widget which is created being some parameters.
I have :
A_panel * a_panel = new A_panel(a_widget, parent, sizable );
a_panel->resize(parent->width()*float(tam_100_or_0)/100, parent->height()*float(tam_100_or_0)/100);
A_panel * a_panel = new A_panel(a_widget, parent, sizable );
QApplication::processEvents(QEventLoop::AllEvents);
a_panel->resize(parent->width()*float(tam_100_or_0)/100, parent->height()*float(tam_100_or_0)/100);
To copy to clipboard, switch view to plain text mode
Ok. my 'A_panel' has three internal calls. The constructor calls a function and this one a last one, that sets a 'i_am_ready' variable to 'true'.
the resizeevent has 'if i_am_ready!=true return', that is, until my widget is not ready I dont want to process any resize event.
Ok. The last code fails, I have a resizeevent before the three functions be called.
I have tried to use the processEvents, but without success.
Any help or idea ? Thanks.
Bookmarks