diff --git a/pokerth_game.pro b/pokerth_game.pro index 0a5fe623..77bb6ba2 100644 --- a/pokerth_game.pro +++ b/pokerth_game.pro @@ -49,6 +49,7 @@ INCLUDEPATH += . \ src/gui/qt/settingsdialog/selectavatardialog \ src/gui/qt/settingsdialog/manualblindsorderdialog \ src/gui/qt/startnetworkgamedialog \ + src/gui/qt/startwindow \ src/gui/qt/changehumanplayernamedialog \ src/gui/qt/changecompleteblindsdialog \ src/gui/qt/mymessagedialog \ @@ -87,6 +88,7 @@ DEPENDPATH += . \ src/gui/qt/settingsdialog/selectavatardialog \ src/gui/qt/settingsdialog/manualblindsorderdialog \ src/gui/qt/startnetworkgamedialog \ + src/gui/qt/startwindow \ src/gui/qt/changehumanplayernamedialog \ src/gui/qt/changecompleteblindsdialog \ src/gui/qt/mymessagedialog \ @@ -169,6 +171,7 @@ HEADERS += \ src/gui/qt/settingsdialog/selectavatardialog/myavatarlistitem.h \ src/gui/qt/settingsdialog/manualblindsorderdialog/manualblindsorderdialogimpl.h \ src/gui/qt/startnetworkgamedialog/startnetworkgamedialogimpl.h \ + src/gui/qt/startwindow/startwindowimpl.h \ src/gui/qt/changehumanplayernamedialog/changehumanplayernamedialogimpl.h \ src/gui/qt/changecompleteblindsdialog/changecompleteblindsdialogimpl.h \ src/gui/qt/gamelobbydialog/gamelobbydialogimpl.h \ @@ -192,6 +195,7 @@ FORMS += \ src/gui/qt/settingsdialog.ui \ src/gui/qt/selectavatardialog.ui \ src/gui/qt/startnetworkgamedialog.ui \ + src/gui/qt/startwindow.ui \ src/gui/qt/changehumanplayernamedialog.ui \ src/gui/qt/changecompleteblindsdialog.ui \ src/gui/qt/gamelobbydialog.ui \ @@ -228,6 +232,7 @@ SOURCES += \ src/gui/qt/settingsdialog/selectavatardialog/myavatarlistitem.cpp \ src/gui/qt/settingsdialog/manualblindsorderdialog/manualblindsorderdialogimpl.cpp \ src/gui/qt/startnetworkgamedialog/startnetworkgamedialogimpl.cpp \ + src/gui/qt/startwindow/startwindowimpl.cpp \ src/gui/qt/changehumanplayernamedialog/changehumanplayernamedialogimpl.cpp \ src/gui/qt/changecompleteblindsdialog/changecompleteblindsdialogimpl.cpp \ src/gui/qt/mymessagedialog/mymessagedialogimpl.cpp \ diff --git a/src/gui/qt/startwindow.ui b/src/gui/qt/startwindow.ui index 46a6bc62..c31fb890 100644 --- a/src/gui/qt/startwindow.ui +++ b/src/gui/qt/startwindow.ui @@ -1,6 +1,6 @@ - mainWindow - + startWindow + 0 @@ -13,21 +13,13 @@ PokerTH 0.6.3 - The Open-Source Texas Holdem Engine - - - 0 - 28 - 444 - 289 - - - + - + Qt::Vertical - + 20 95 @@ -36,11 +28,11 @@ - + Qt::Horizontal - + 63 20 @@ -49,7 +41,7 @@ - + @@ -81,11 +73,11 @@ - + Qt::Horizontal - + 63 20 @@ -94,11 +86,11 @@ - + Qt::Vertical - + 20 95 @@ -149,16 +141,7 @@ - - - - 0 - 317 - 444 - 21 - - - + Start Local Game ... diff --git a/src/gui/qt/startwindow/startwindowimpl.cpp b/src/gui/qt/startwindow/startwindowimpl.cpp new file mode 100644 index 00000000..6033a2f9 --- /dev/null +++ b/src/gui/qt/startwindow/startwindowimpl.cpp @@ -0,0 +1,34 @@ +/*************************************************************************** + * Copyright (C) 2006 by FThauer FHammer * + * f.thauer@web.de * + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + * This program is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * + * GNU General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this program; if not, write to the * + * Free Software Foundation, Inc., * + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * + ***************************************************************************/ +#include "startwindowimpl.h" +#include "configfile.h" +#include "gametableimpl.h" + +startWindowImpl::startWindowImpl(gameTableImpl *w, ConfigFile *c) + : myW(w), myConfig(c) +{ +// #ifdef __APPLE__ +// setWindowModality(Qt::ApplicationModal); +// setWindowFlags(Qt::WindowSystemMenuHint | Qt::CustomizeWindowHint | Qt::Dialog); +// #endif + setupUi(this); + + +} diff --git a/src/gui/qt/startwindow/startwindowimpl.h b/src/gui/qt/startwindow/startwindowimpl.h new file mode 100644 index 00000000..64996c74 --- /dev/null +++ b/src/gui/qt/startwindow/startwindowimpl.h @@ -0,0 +1,39 @@ +/*************************************************************************** + * Copyright (C) 2006 by FThauer FHammer * + * f.thauer@web.de * + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + * This program is distributed in the hope that it will be useful, * + * but WITHOUT ANY WARRANTY; without even the implied warranty of * + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * + * GNU General Public License for more details. * + * * + * You should have received a copy of the GNU General Public License * + * along with this program; if not, write to the * + * Free Software Foundation, Inc., * + * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * + ***************************************************************************/ +#ifndef STARTWINDOWIMPL_H +#define STARTWINDOWIMPL_H + +#include "ui_startwindow.h" + +class ConfigFile; +class gameTableImpl; + +class startWindowImpl: public QMainWindow, public Ui::startWindow { +Q_OBJECT +public: + startWindowImpl(gameTableImpl *w = 0, ConfigFile *c =0); + +private: + + ConfigFile *myConfig; + gameTableImpl *myW; +}; + +#endif diff --git a/src/pokerth.cpp b/src/pokerth.cpp index 790e590a..ff1e2604 100755 --- a/src/pokerth.cpp +++ b/src/pokerth.cpp @@ -28,6 +28,7 @@ #include "session.h" #include "guiwrapper.h" +#include "startwindowimpl.h" #include "configfile.h" #include @@ -134,6 +135,8 @@ int main( int argc, char **argv ) myGuiInterface->setSession(session); } +// boost::shared_ptr myStartWindow(new startWindowImpl(myGuiInterface.get(), myConfig)); + int retVal = a.exec(); curl_global_cleanup();