# HG changeset patch
# User nemo
# Date 1290320791 18000
# Node ID 95e27e12d0e969a73e9dcaed00f210330c7d7363
# Parent  de9e1a5102b4ee006f0b82e7605361d95c099b7c
Fix koda's esc key binding so leaving rooms works correctly with it

diff -r de9e1a5102b4 -r 95e27e12d0e9 QTfrontend/hwform.cpp
--- a/QTfrontend/hwform.cpp	Sun Nov 21 01:08:43 2010 -0500
+++ b/QTfrontend/hwform.cpp	Sun Nov 21 01:26:31 2010 -0500
@@ -276,7 +276,7 @@
 
 void HWForm::keyReleaseEvent(QKeyEvent *event)
 {
-  if (event->key() == Qt::Key_Escape /*|| event->key() == Qt::Key_Backspace*/ )
+  if (event->key() == Qt::Key_Escape /*|| event->key() == Qt::Key_Backspace*/ ) 
     this->GoBack();
 }
 
@@ -521,6 +521,7 @@
             GoBack();
 
     if (curid == ID_PAGE_ROOMSLIST) NetDisconnect();
+    if (curid == ID_PAGE_NETGAME) hwnet->partRoom();
 
     if (curid == ID_PAGE_SCHEME)
         ammoSchemeModel->Save();
@@ -678,7 +679,7 @@
     connect(hwnet, SIGNAL(EnteredGame()), this, SLOT(NetGameEnter()));
     connect(hwnet, SIGNAL(LeftRoom()), this, SLOT(NetLeftRoom()));
     connect(hwnet, SIGNAL(AddNetTeam(const HWTeam&)), this, SLOT(AddNetTeam(const HWTeam&)));
-    connect(ui.pageNetGame->BtnBack, SIGNAL(clicked()), hwnet, SLOT(partRoom()));
+    //connect(ui.pageNetGame->BtnBack, SIGNAL(clicked()), hwnet, SLOT(partRoom()));
 
 // rooms list page stuff
     connect(hwnet, SIGNAL(roomsList(const QStringList&)),