1,在Activity的onStop()函数中隐藏Widget。
int HomeLauncher::onStop() { QWidget* pObj = mProperty->getUiObj(); if(pObj) { pObj->hide(); } return 0; }
2,在Activity的onDestory中释放掉了改Widget
int HomeLauncher::onDestory() { QWidget* pObj = mProperty->getUiObj(); if(pObj) { pObj->deleteLater(); pObj = NULL; } return 0; }