diff --git a/src/gui/guiwrapper.cpp b/src/gui/guiwrapper.cpp index 8e6b3ef9..c5cd3c97 100644 --- a/src/gui/guiwrapper.cpp +++ b/src/gui/guiwrapper.cpp @@ -17,6 +17,7 @@ * Free Software Foundation, Inc., * * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * ***************************************************************************/ + #include "guiwrapper.h" #include "log.h" @@ -25,14 +26,13 @@ using namespace std; -GuiWrapper::GuiWrapper(mainWindowImpl* w) : myW(w) +GuiWrapper::GuiWrapper() : myLog(0), myW(0) { -// Am Ende soll GuiWrapper mainWindowImpl -// myW = new mainWindowImpl(); -// myW->show(); -// Jetzt muss myW erstmal aus Session kommen! + myW = new mainWindowImpl; + myW->show(); + myLog = new Log(myW); diff --git a/src/gui/guiwrapper.h b/src/gui/guiwrapper.h index 992aedab..0a941ef5 100644 --- a/src/gui/guiwrapper.h +++ b/src/gui/guiwrapper.h @@ -20,6 +20,8 @@ #ifndef GUIWRAPPER_H #define GUIWRAPPER_H +#include + #include #include #include @@ -32,7 +34,7 @@ class Log; class GuiWrapper : public GuiInterface { public: - GuiWrapper(mainWindowImpl*); + GuiWrapper(); ~GuiWrapper(); @@ -81,8 +83,9 @@ public: private: - mainWindowImpl *myW; + Log *myLog; + mainWindowImpl *myW; }; diff --git a/src/pokerth.cpp b/src/pokerth.cpp index ccb7334d..27c35c47 100755 --- a/src/pokerth.cpp +++ b/src/pokerth.cpp @@ -17,14 +17,9 @@ * Free Software Foundation, Inc., * * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * ***************************************************************************/ - - #include -//wenn die Interfaces fertig sind werden die folgenden beiden includes nicht mehr gebraucht #include "session.h" -#include "mainwindowimpl.h" - #include "guiwrapper.h" class GuiWrapper; @@ -37,12 +32,7 @@ int main( int argc, char **argv ) QApplication a( argc, argv ); Q_INIT_RESOURCE(deck); - //wenn die Interfaces fertig sind werden die folgenden beiden Objekte nicht mehr gebraucht da sie von GuiWrapper und EngineWrapper erstellt werden. - - mainWindowImpl *myW = new mainWindowImpl; - myW->show(); - - GuiInterface *myGuiInterface = new GuiWrapper(myW); + GuiInterface *myGuiInterface = new GuiWrapper(); Session theFirst(myGuiInterface); diff --git a/src/session.cpp b/src/session.cpp index 335be092..c2d2338d 100755 --- a/src/session.cpp +++ b/src/session.cpp @@ -28,9 +28,6 @@ Session::Session(GuiInterface* g) : actualGame(0), myGui(g) -// myW = new mainWindowImpl(); -// a.setMainWidget( w ); -// myW->show(); // Session an mainwindowimpl bergeben myGui->setSession(this);