This commit is contained in:
@@ -30,7 +30,6 @@ INCLUDEPATH += . \
|
|||||||
src/gui/qt/settingsdialog \
|
src/gui/qt/settingsdialog \
|
||||||
src/gui/qt/settingsdialog/selectavatardialog \
|
src/gui/qt/settingsdialog/selectavatardialog \
|
||||||
src/gui/qt/startnetworkgamedialog \
|
src/gui/qt/startnetworkgamedialog \
|
||||||
src/gui/qt/waitforservertostartgamedialog \
|
|
||||||
src/gui/qt/changehumanplayernamedialog
|
src/gui/qt/changehumanplayernamedialog
|
||||||
|
|
||||||
DEPENDPATH += . \
|
DEPENDPATH += . \
|
||||||
@@ -61,7 +60,6 @@ DEPENDPATH += . \
|
|||||||
src/gui/qt/settingsdialog \
|
src/gui/qt/settingsdialog \
|
||||||
src/gui/qt/settingsdialog/selectavatardialog \
|
src/gui/qt/settingsdialog/selectavatardialog \
|
||||||
src/gui/qt/startnetworkgamedialog \
|
src/gui/qt/startnetworkgamedialog \
|
||||||
src/gui/qt/waitforservertostartgamedialog \
|
|
||||||
src/gui/qt/changehumanplayernamedialog
|
src/gui/qt/changehumanplayernamedialog
|
||||||
# Input
|
# Input
|
||||||
HEADERS += src/game.h \
|
HEADERS += src/game.h \
|
||||||
@@ -145,7 +143,6 @@ HEADERS += src/game.h \
|
|||||||
src/gui/qt/settingsdialog/selectavatardialog/selectavatardialogimpl.h \
|
src/gui/qt/settingsdialog/selectavatardialog/selectavatardialogimpl.h \
|
||||||
src/gui/qt/settingsdialog/selectavatardialog/myavatarlistitem.h \
|
src/gui/qt/settingsdialog/selectavatardialog/myavatarlistitem.h \
|
||||||
src/gui/qt/startnetworkgamedialog/startnetworkgamedialogimpl.h \
|
src/gui/qt/startnetworkgamedialog/startnetworkgamedialogimpl.h \
|
||||||
src/gui/qt/waitforservertostartgamedialog/waitforservertostartgamedialogimpl.h \
|
|
||||||
src/gui/qt/changehumanplayernamedialog/changehumanplayernamedialogimpl.h \
|
src/gui/qt/changehumanplayernamedialog/changehumanplayernamedialogimpl.h \
|
||||||
src/gui/qttoolsinterface.h \
|
src/gui/qttoolsinterface.h \
|
||||||
src/gui/qt/qttools/qttoolswrapper.h \
|
src/gui/qt/qttools/qttoolswrapper.h \
|
||||||
@@ -160,7 +157,6 @@ FORMS += src/gui/qt/mainwindow.ui \
|
|||||||
src/gui/qt/settingsdialog.ui \
|
src/gui/qt/settingsdialog.ui \
|
||||||
src/gui/qt/selectavatardialog.ui \
|
src/gui/qt/selectavatardialog.ui \
|
||||||
src/gui/qt/startnetworkgamedialog.ui \
|
src/gui/qt/startnetworkgamedialog.ui \
|
||||||
src/gui/qt/waitforservertostartgamedialog.ui \
|
|
||||||
src/gui/qt/changehumanplayernamedialog.ui
|
src/gui/qt/changehumanplayernamedialog.ui
|
||||||
SOURCES += src/game.cpp \
|
SOURCES += src/game.cpp \
|
||||||
src/pokerth.cpp \
|
src/pokerth.cpp \
|
||||||
@@ -253,7 +249,6 @@ SOURCES += src/game.cpp \
|
|||||||
src/gui/qt/settingsdialog/selectavatardialog/selectavatardialogimpl.cpp \
|
src/gui/qt/settingsdialog/selectavatardialog/selectavatardialogimpl.cpp \
|
||||||
src/gui/qt/settingsdialog/selectavatardialog/myavatarlistitem.cpp \
|
src/gui/qt/settingsdialog/selectavatardialog/myavatarlistitem.cpp \
|
||||||
src/gui/qt/startnetworkgamedialog/startnetworkgamedialogimpl.cpp \
|
src/gui/qt/startnetworkgamedialog/startnetworkgamedialogimpl.cpp \
|
||||||
src/gui/qt/waitforservertostartgamedialog/waitforservertostartgamedialogimpl.cpp \
|
|
||||||
src/gui/qt/changehumanplayernamedialog/changehumanplayernamedialogimpl.cpp \
|
src/gui/qt/changehumanplayernamedialog/changehumanplayernamedialogimpl.cpp \
|
||||||
src/gui/qttoolsinterface.cpp \
|
src/gui/qttoolsinterface.cpp \
|
||||||
src/gui/qt/qttools/qttoolswrapper.cpp \
|
src/gui/qt/qttools/qttoolswrapper.cpp \
|
||||||
|
|||||||
@@ -5,8 +5,8 @@
|
|||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>287</width>
|
<width>311</width>
|
||||||
<height>259</height>
|
<height>470</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle" >
|
<property name="windowTitle" >
|
||||||
@@ -19,6 +19,80 @@
|
|||||||
<property name="spacing" >
|
<property name="spacing" >
|
||||||
<number>6</number>
|
<number>6</number>
|
||||||
</property>
|
</property>
|
||||||
|
<item row="2" column="0" >
|
||||||
|
<widget class="QGroupBox" name="groupBox" >
|
||||||
|
<property name="title" >
|
||||||
|
<string>Lobby-Chat</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QGridLayout" >
|
||||||
|
<property name="margin" >
|
||||||
|
<number>7</number>
|
||||||
|
</property>
|
||||||
|
<property name="spacing" >
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<item row="0" column="0" >
|
||||||
|
<widget class="QTextBrowser" name="textBrowser_ChatDisplay" />
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0" >
|
||||||
|
<widget class="QLineEdit" name="lineEdit_ChatInput" />
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="3" column="0" >
|
||||||
|
<widget class="Line" name="line" >
|
||||||
|
<property name="orientation" >
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="4" column="0" >
|
||||||
|
<layout class="QHBoxLayout" >
|
||||||
|
<property name="margin" >
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="spacing" >
|
||||||
|
<number>6</number>
|
||||||
|
</property>
|
||||||
|
<item>
|
||||||
|
<spacer>
|
||||||
|
<property name="orientation" >
|
||||||
|
<enum>Qt::Horizontal</enum>
|
||||||
|
</property>
|
||||||
|
<property name="sizeHint" >
|
||||||
|
<size>
|
||||||
|
<width>181</width>
|
||||||
|
<height>20</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
</spacer>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QPushButton" name="pushButton_startGame" >
|
||||||
|
<property name="text" >
|
||||||
|
<string>Start Game</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QPushButton" name="pushButton_cancel" >
|
||||||
|
<property name="text" >
|
||||||
|
<string>Cancel</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
</layout>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="0" >
|
||||||
|
<widget class="QTreeWidget" name="treeWidget" >
|
||||||
|
<column>
|
||||||
|
<property name="text" >
|
||||||
|
<string>Connected Players</string>
|
||||||
|
</property>
|
||||||
|
</column>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
<item row="1" column="0" >
|
<item row="1" column="0" >
|
||||||
<layout class="QHBoxLayout" >
|
<layout class="QHBoxLayout" >
|
||||||
<property name="margin" >
|
<property name="margin" >
|
||||||
@@ -63,59 +137,6 @@
|
|||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="0" >
|
|
||||||
<widget class="Line" name="line" >
|
|
||||||
<property name="orientation" >
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="0" >
|
|
||||||
<widget class="QTreeWidget" name="treeWidget" >
|
|
||||||
<column>
|
|
||||||
<property name="text" >
|
|
||||||
<string>Connected Players</string>
|
|
||||||
</property>
|
|
||||||
</column>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="0" >
|
|
||||||
<layout class="QHBoxLayout" >
|
|
||||||
<property name="margin" >
|
|
||||||
<number>0</number>
|
|
||||||
</property>
|
|
||||||
<property name="spacing" >
|
|
||||||
<number>6</number>
|
|
||||||
</property>
|
|
||||||
<item>
|
|
||||||
<spacer>
|
|
||||||
<property name="orientation" >
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" >
|
|
||||||
<size>
|
|
||||||
<width>181</width>
|
|
||||||
<height>20</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="pushButton_startGame" >
|
|
||||||
<property name="text" >
|
|
||||||
<string>Start Game</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="pushButton_cancel" >
|
|
||||||
<property name="text" >
|
|
||||||
<string>Cancel</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
<tabstops>
|
<tabstops>
|
||||||
|
|||||||
@@ -1,101 +0,0 @@
|
|||||||
<ui version="4.0" >
|
|
||||||
<class>waitForServerToStartGameDialog</class>
|
|
||||||
<widget class="QDialog" name="waitForServerToStartGameDialog" >
|
|
||||||
<property name="geometry" >
|
|
||||||
<rect>
|
|
||||||
<x>0</x>
|
|
||||||
<y>0</y>
|
|
||||||
<width>279</width>
|
|
||||||
<height>257</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="windowTitle" >
|
|
||||||
<string>Waiting for Server ...</string>
|
|
||||||
</property>
|
|
||||||
<layout class="QGridLayout" >
|
|
||||||
<property name="margin" >
|
|
||||||
<number>9</number>
|
|
||||||
</property>
|
|
||||||
<property name="spacing" >
|
|
||||||
<number>6</number>
|
|
||||||
</property>
|
|
||||||
<item row="0" column="0" colspan="3" >
|
|
||||||
<widget class="QTreeWidget" name="treeWidget" >
|
|
||||||
<column>
|
|
||||||
<property name="text" >
|
|
||||||
<string>Connected Players</string>
|
|
||||||
</property>
|
|
||||||
</column>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="0" colspan="3" >
|
|
||||||
<widget class="QLabel" name="label" >
|
|
||||||
<property name="text" >
|
|
||||||
<string>Waiting for the server to start the game ...</string>
|
|
||||||
</property>
|
|
||||||
<property name="alignment" >
|
|
||||||
<set>Qt::AlignCenter</set>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="1" >
|
|
||||||
<widget class="QPushButton" name="pushButton_cancel" >
|
|
||||||
<property name="maximumSize" >
|
|
||||||
<size>
|
|
||||||
<width>100</width>
|
|
||||||
<height>16777215</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="text" >
|
|
||||||
<string>Cancel</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="0" >
|
|
||||||
<spacer>
|
|
||||||
<property name="orientation" >
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" >
|
|
||||||
<size>
|
|
||||||
<width>40</width>
|
|
||||||
<height>20</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="2" >
|
|
||||||
<spacer>
|
|
||||||
<property name="orientation" >
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" >
|
|
||||||
<size>
|
|
||||||
<width>40</width>
|
|
||||||
<height>20</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
<resources/>
|
|
||||||
<connections>
|
|
||||||
<connection>
|
|
||||||
<sender>pushButton_cancel</sender>
|
|
||||||
<signal>clicked()</signal>
|
|
||||||
<receiver>waitForServerToStartGameDialog</receiver>
|
|
||||||
<slot>reject()</slot>
|
|
||||||
<hints>
|
|
||||||
<hint type="sourcelabel" >
|
|
||||||
<x>162</x>
|
|
||||||
<y>231</y>
|
|
||||||
</hint>
|
|
||||||
<hint type="destinationlabel" >
|
|
||||||
<x>64</x>
|
|
||||||
<y>233</y>
|
|
||||||
</hint>
|
|
||||||
</hints>
|
|
||||||
</connection>
|
|
||||||
</connections>
|
|
||||||
</ui>
|
|
||||||
@@ -1,66 +0,0 @@
|
|||||||
/***************************************************************************
|
|
||||||
* 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 "waitforservertostartgamedialogimpl.h"
|
|
||||||
#include "session.h"
|
|
||||||
#include <net/socket_msg.h>
|
|
||||||
// #include "configfile.h"
|
|
||||||
|
|
||||||
waitForServerToStartGameDialogImpl::waitForServerToStartGameDialogImpl(QWidget *parent)
|
|
||||||
: QDialog(parent)
|
|
||||||
{
|
|
||||||
|
|
||||||
setupUi(this);
|
|
||||||
|
|
||||||
connect( pushButton_cancel, SIGNAL( clicked() ), this, SLOT( cancel() ) );
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
void waitForServerToStartGameDialogImpl::refresh(int actionID) {
|
|
||||||
|
|
||||||
if (actionID == MSG_NET_GAME_CLIENT_START)
|
|
||||||
{
|
|
||||||
QTimer::singleShot(500, this, SLOT(accept()));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void waitForServerToStartGameDialogImpl::cancel() {
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
void waitForServerToStartGameDialogImpl::keyPressEvent ( QKeyEvent * event ) {
|
|
||||||
|
|
||||||
|
|
||||||
// if (event->key() == 16777220) { pushButton_connect->click(); } //ENTER
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
void waitForServerToStartGameDialogImpl::addConnectedPlayer(QString playerName) {
|
|
||||||
|
|
||||||
QTreeWidgetItem *item = new QTreeWidgetItem(treeWidget,0);
|
|
||||||
item->setData(0, 0, playerName);
|
|
||||||
}
|
|
||||||
|
|
||||||
void waitForServerToStartGameDialogImpl::removePlayer(QString playerName) {
|
|
||||||
|
|
||||||
QList<QTreeWidgetItem *> list = treeWidget->findItems(playerName, Qt::MatchExactly, 0);
|
|
||||||
if(!list.empty()) {
|
|
||||||
treeWidget->takeTopLevelItem(treeWidget->indexOfTopLevelItem(list[0]));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,44 +0,0 @@
|
|||||||
/***************************************************************************
|
|
||||||
* 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 WAITFORSERVERTOSTARTGAMEDIALOGIMPL_H
|
|
||||||
#define WAITFORSERVERTOSTARTGAMEDIALOGIMPL_H
|
|
||||||
|
|
||||||
#include "ui_waitforservertostartgamedialog.h"
|
|
||||||
|
|
||||||
#include <QtGui>
|
|
||||||
#include <QtCore>
|
|
||||||
|
|
||||||
class Session;
|
|
||||||
|
|
||||||
class waitForServerToStartGameDialogImpl: public QDialog, public Ui::waitForServerToStartGameDialog {
|
|
||||||
Q_OBJECT
|
|
||||||
public:
|
|
||||||
waitForServerToStartGameDialogImpl(QWidget *parent = 0);
|
|
||||||
|
|
||||||
public slots:
|
|
||||||
|
|
||||||
void refresh(int actionID);
|
|
||||||
void cancel();
|
|
||||||
void keyPressEvent ( QKeyEvent * event );
|
|
||||||
void addConnectedPlayer(QString playerName);
|
|
||||||
void removePlayer(QString playerName);
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif
|
|
||||||
Reference in New Issue
Block a user