closeevent fix

This commit is contained in:
doitux
2007-05-14 13:01:16 +00:00
parent 2d894c6a2c
commit bc146c8899
2 changed files with 11 additions and 0 deletions
+9
View File
@@ -2425,3 +2425,12 @@ void mainWindowImpl::blinkingStartButtonAnimationAction() {
} }
pushButton_break->setPalette(tempPalette); pushButton_break->setPalette(tempPalette);
} }
void mainWindowImpl::closeEvent(QCloseEvent *event) {
mySession->terminateNetworkClient();
if (myServerGuiInterface.get()) myServerGuiInterface->getSession().terminateNetworkServer();
event->accept();
}
+2
View File
@@ -199,6 +199,8 @@ public slots:
void networkError(int, int); void networkError(int, int);
void networkStart(int, int, int, int); void networkStart(int, int, int, int);
void closeEvent(QCloseEvent*);
private: private:
boost::shared_ptr<GuiInterface> myServerGuiInterface; boost::shared_ptr<GuiInterface> myServerGuiInterface;