Qt Application Slowing Down
-
@mrjj i used breakpoints on distructor
if i use close()...they are not freed
only if remove close()....they get clearedIm not sure in what context.
if using something like
void class::insomefunc() {
mainSortDialog ms;
this->close();//closes the setting screen
ms->exec();
}MS should always be deleted. the this->close() should have no effect.
If you use new for other classes make sure it still has WA_DeleteOnClose.
-
Im not sure in what context.
if using something like
void class::insomefunc() {
mainSortDialog ms;
this->close();//closes the setting screen
ms->exec();
}MS should always be deleted. the this->close() should have no effect.
If you use new for other classes make sure it still has WA_DeleteOnClose.
@mrjj
am using this one move to main sort
void class::insomefunc() {
mainSortDialog ms;
ms->exec();
}
and back to main screen by using just "hide();" in back button
this is work for me even the memory leakage.
but if use close(); its not working
void class::insomefunc() {
mainSortDialog ms;
this->close();//closes the setting screen
ms->exec();
} -
hi
in what way "not working" ? -
@mrjj
1.i used breakpoints on distructor of each screen.
2.am moving to main sort using
void class::insomefunc() {
mainSortDialog ms;
this->close();//closes the setting screen
ms->exec();
}
3.and moving back to the home page
void class::insomefunc() {
homeDialog h;
this->close();//closes the setting screen
h->exec();
}
at this point it is not moving to destructor
only if i move to mainwindow it moving to destructor mainsort page -
@mrjj
1.i used breakpoints on distructor of each screen.
2.am moving to main sort using
void class::insomefunc() {
mainSortDialog ms;
this->close();//closes the setting screen
ms->exec();
}
3.and moving back to the home page
void class::insomefunc() {
homeDialog h;
this->close();//closes the setting screen
h->exec();
}
at this point it is not moving to destructor
only if i move to mainwindow it moving to destructor mainsort page@swansorter
Hi
Really?
but they are local variables. they will be destroyed.
I can't see anyway, they could avoid that. -
@swansorter
Hi
Really?
but they are local variables. they will be destroyed.
I can't see anyway, they could avoid that.@mrjj said in Qt Application Slowing Down:
will be destroyed
Yes, but only when exec() finishes I guess :-)
-
@mrjj said in Qt Application Slowing Down:
will be destroyed
Yes, but only when exec() finishes I guess :-)