checkBox_fillUpWithComputerOpponents added; some startnetworkgamedialog behaviour changes
This commit is contained in:
+2
-2
@@ -3,8 +3,8 @@
|
|||||||
TEMPLATE = app
|
TEMPLATE = app
|
||||||
CODECFORSRC = UTF-8
|
CODECFORSRC = UTF-8
|
||||||
|
|
||||||
#CONFIG += qt thread embed_manifest_exe release
|
CONFIG += qt thread embed_manifest_exe release
|
||||||
CONFIG += qt thread embed_manifest_exe warn_on debug
|
#CONFIG += qt thread embed_manifest_exe warn_on debug
|
||||||
UI_DIR = uics
|
UI_DIR = uics
|
||||||
MOC_DIR = mocs
|
MOC_DIR = mocs
|
||||||
OBJECTS_DIR = obj
|
OBJECTS_DIR = obj
|
||||||
|
|||||||
+2
-2
@@ -178,8 +178,8 @@ mac{
|
|||||||
INCLUDEPATH += /Library/Frameworks/SDL_mixer.framework/Headers
|
INCLUDEPATH += /Library/Frameworks/SDL_mixer.framework/Headers
|
||||||
}
|
}
|
||||||
|
|
||||||
#CONFIG += staticlib qt thread release
|
CONFIG += staticlib qt thread release
|
||||||
CONFIG += staticlib qt thread warn_on debug
|
#CONFIG += staticlib qt thread warn_on debug
|
||||||
UI_DIR = uics
|
UI_DIR = uics
|
||||||
TARGET = lib/pokerth_lib
|
TARGET = lib/pokerth_lib
|
||||||
MOC_DIR = mocs
|
MOC_DIR = mocs
|
||||||
|
|||||||
@@ -145,7 +145,8 @@ ConfigFile::ConfigFile(int argc, char **argv) : noWriteAccess(0)
|
|||||||
configList.push_back(ConfigInfo("ShowFadeOutCardsAnimation", CONFIG_TYPE_INT, "1"));
|
configList.push_back(ConfigInfo("ShowFadeOutCardsAnimation", CONFIG_TYPE_INT, "1"));
|
||||||
configList.push_back(ConfigInfo("ShowFlipCardsAnimation", CONFIG_TYPE_INT, "1"));
|
configList.push_back(ConfigInfo("ShowFlipCardsAnimation", CONFIG_TYPE_INT, "1"));
|
||||||
configList.push_back(ConfigInfo("ShowBlindButtons", CONFIG_TYPE_INT, "1"));
|
configList.push_back(ConfigInfo("ShowBlindButtons", CONFIG_TYPE_INT, "1"));
|
||||||
configList.push_back(ConfigInfo("AntiPeekMode", CONFIG_TYPE_INT, "0")); configList.push_back(ConfigInfo("PlaySoundEffects", CONFIG_TYPE_INT, "1"));
|
configList.push_back(ConfigInfo("AntiPeekMode", CONFIG_TYPE_INT, "0"));
|
||||||
|
configList.push_back(ConfigInfo("PlaySoundEffects", CONFIG_TYPE_INT, "1"));
|
||||||
configList.push_back(ConfigInfo("SoundVolume", CONFIG_TYPE_INT, "8"));
|
configList.push_back(ConfigInfo("SoundVolume", CONFIG_TYPE_INT, "8"));
|
||||||
configList.push_back(ConfigInfo("FlipsideTux", CONFIG_TYPE_INT, "1"));
|
configList.push_back(ConfigInfo("FlipsideTux", CONFIG_TYPE_INT, "1"));
|
||||||
configList.push_back(ConfigInfo("FlipsideOwn", CONFIG_TYPE_INT, "0"));
|
configList.push_back(ConfigInfo("FlipsideOwn", CONFIG_TYPE_INT, "0"));
|
||||||
|
|||||||
@@ -187,7 +187,7 @@
|
|||||||
<property name="verticalSpacing" >
|
<property name="verticalSpacing" >
|
||||||
<number>6</number>
|
<number>6</number>
|
||||||
</property>
|
</property>
|
||||||
<item row="3" column="0" >
|
<item row="4" column="0" >
|
||||||
<spacer>
|
<spacer>
|
||||||
<property name="orientation" >
|
<property name="orientation" >
|
||||||
<enum>Qt::Vertical</enum>
|
<enum>Qt::Vertical</enum>
|
||||||
@@ -215,7 +215,7 @@
|
|||||||
</column>
|
</column>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="0" >
|
<item row="2" column="0" >
|
||||||
<layout class="QHBoxLayout" >
|
<layout class="QHBoxLayout" >
|
||||||
<property name="spacing" >
|
<property name="spacing" >
|
||||||
<number>6</number>
|
<number>6</number>
|
||||||
@@ -277,14 +277,14 @@
|
|||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item row="4" column="0" >
|
<item row="5" column="0" >
|
||||||
<widget class="QPushButton" name="pushButton_Leave" >
|
<widget class="QPushButton" name="pushButton_Leave" >
|
||||||
<property name="text" >
|
<property name="text" >
|
||||||
<string>Leave</string>
|
<string>Leave</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="0" >
|
<item row="3" column="0" >
|
||||||
<layout class="QGridLayout" >
|
<layout class="QGridLayout" >
|
||||||
<property name="leftMargin" >
|
<property name="leftMargin" >
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
@@ -391,6 +391,13 @@ p, li { white-space: pre-wrap; }
|
|||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
|
<item row="1" column="0" >
|
||||||
|
<widget class="QCheckBox" name="checkBox_fillUpWithComputerOpponents" >
|
||||||
|
<property name="text" >
|
||||||
|
<string>Fill up with computer opponents</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
|||||||
@@ -174,6 +174,7 @@ void gameLobbyDialogImpl::clearDialog()
|
|||||||
pushButton_Leave->hide();
|
pushButton_Leave->hide();
|
||||||
pushButton_Kick->hide();
|
pushButton_Kick->hide();
|
||||||
pushButton_StartGame->hide();
|
pushButton_StartGame->hide();
|
||||||
|
checkBox_fillUpWithComputerOpponents->hide();
|
||||||
|
|
||||||
treeWidget_GameList->setColumnWidth(0,250);
|
treeWidget_GameList->setColumnWidth(0,250);
|
||||||
treeWidget_GameList->setColumnWidth(1,75);
|
treeWidget_GameList->setColumnWidth(1,75);
|
||||||
|
|||||||
@@ -164,6 +164,9 @@
|
|||||||
</property>
|
</property>
|
||||||
<item row="0" column="0" >
|
<item row="0" column="0" >
|
||||||
<widget class="MyLeftTabWidget" name="tabWidget_Left" >
|
<widget class="MyLeftTabWidget" name="tabWidget_Left" >
|
||||||
|
<property name="focusPolicy" >
|
||||||
|
<enum>Qt::NoFocus</enum>
|
||||||
|
</property>
|
||||||
<property name="currentIndex" >
|
<property name="currentIndex" >
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
@@ -947,6 +950,9 @@
|
|||||||
</property>
|
</property>
|
||||||
<item row="0" column="0" >
|
<item row="0" column="0" >
|
||||||
<widget class="MyRightTabWidget" name="tabWidget_Right" >
|
<widget class="MyRightTabWidget" name="tabWidget_Right" >
|
||||||
|
<property name="focusPolicy" >
|
||||||
|
<enum>Qt::NoFocus</enum>
|
||||||
|
</property>
|
||||||
<property name="currentIndex" >
|
<property name="currentIndex" >
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
@@ -975,43 +981,6 @@
|
|||||||
</property>
|
</property>
|
||||||
<item row="0" column="0" >
|
<item row="0" column="0" >
|
||||||
<widget class="QTextBrowser" name="textBrowser_Log" >
|
<widget class="QTextBrowser" name="textBrowser_Log" >
|
||||||
<property name="palette" >
|
|
||||||
<palette>
|
|
||||||
<active>
|
|
||||||
<colorrole role="Button" >
|
|
||||||
<brush brushstyle="SolidPattern" >
|
|
||||||
<color alpha="255" >
|
|
||||||
<red>30</red>
|
|
||||||
<green>80</green>
|
|
||||||
<blue>0</blue>
|
|
||||||
</color>
|
|
||||||
</brush>
|
|
||||||
</colorrole>
|
|
||||||
</active>
|
|
||||||
<inactive>
|
|
||||||
<colorrole role="Button" >
|
|
||||||
<brush brushstyle="SolidPattern" >
|
|
||||||
<color alpha="255" >
|
|
||||||
<red>30</red>
|
|
||||||
<green>80</green>
|
|
||||||
<blue>0</blue>
|
|
||||||
</color>
|
|
||||||
</brush>
|
|
||||||
</colorrole>
|
|
||||||
</inactive>
|
|
||||||
<disabled>
|
|
||||||
<colorrole role="Button" >
|
|
||||||
<brush brushstyle="SolidPattern" >
|
|
||||||
<color alpha="255" >
|
|
||||||
<red>30</red>
|
|
||||||
<green>80</green>
|
|
||||||
<blue>0</blue>
|
|
||||||
</color>
|
|
||||||
</brush>
|
|
||||||
</colorrole>
|
|
||||||
</disabled>
|
|
||||||
</palette>
|
|
||||||
</property>
|
|
||||||
<property name="focusPolicy" >
|
<property name="focusPolicy" >
|
||||||
<enum>Qt::NoFocus</enum>
|
<enum>Qt::NoFocus</enum>
|
||||||
</property>
|
</property>
|
||||||
|
|||||||
@@ -414,6 +414,8 @@ mainWindowImpl::mainWindowImpl(ConfigFile *c, QMainWindow *parent)
|
|||||||
textBrowser_Log->setStyleSheet("QTextBrowser { "+ font1String +" font-size: 11px; color: white; background-color: #1D3B00; border:none; }");
|
textBrowser_Log->setStyleSheet("QTextBrowser { "+ font1String +" font-size: 11px; color: white; background-color: #1D3B00; border:none; }");
|
||||||
#else
|
#else
|
||||||
textBrowser_Log->setStyleSheet("QTextBrowser { "+ font1String +" font-size: 10px; color: white; background-color: #1D3B00; border:none; }");
|
textBrowser_Log->setStyleSheet("QTextBrowser { "+ font1String +" font-size: 10px; color: white; background-color: #1D3B00; border:none; }");
|
||||||
|
// textBrowser_Log->verticalScrollBar()->setStyleSheet("background: yellow");
|
||||||
|
// textBrowser_Log->verticalScrollBar()->setAutoFillBackground ( TRUE );
|
||||||
textBrowser_Chat->setStyleSheet("QTextBrowser { "+ font1String +" font-size: 10px; color: white; background-color: #1D3B00; border:none; }");
|
textBrowser_Chat->setStyleSheet("QTextBrowser { "+ font1String +" font-size: 10px; color: white; background-color: #1D3B00; border:none; }");
|
||||||
lineEdit_ChatInput->setStyleSheet("QLineEdit { "+ font1String +" font-size: 10px; color: white; background-color: #1D3B00; border-top: 2px solid #286400; }");
|
lineEdit_ChatInput->setStyleSheet("QLineEdit { "+ font1String +" font-size: 10px; color: white; background-color: #1D3B00; border-top: 2px solid #286400; }");
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -6,29 +6,53 @@
|
|||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>311</width>
|
<width>311</width>
|
||||||
<height>470</height>
|
<height>547</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle" >
|
<property name="windowTitle" >
|
||||||
<string>Start Network Game</string>
|
<string>Start Network Game</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" >
|
<layout class="QGridLayout" >
|
||||||
<property name="margin" >
|
<property name="leftMargin" >
|
||||||
<number>9</number>
|
<number>9</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="spacing" >
|
<property name="topMargin" >
|
||||||
|
<number>9</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin" >
|
||||||
|
<number>9</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin" >
|
||||||
|
<number>9</number>
|
||||||
|
</property>
|
||||||
|
<property name="horizontalSpacing" >
|
||||||
<number>6</number>
|
<number>6</number>
|
||||||
</property>
|
</property>
|
||||||
<item row="2" column="0" >
|
<property name="verticalSpacing" >
|
||||||
|
<number>6</number>
|
||||||
|
</property>
|
||||||
|
<item row="3" column="0" >
|
||||||
<widget class="QGroupBox" name="groupBox" >
|
<widget class="QGroupBox" name="groupBox" >
|
||||||
<property name="title" >
|
<property name="title" >
|
||||||
<string>Lobby-Chat</string>
|
<string>Lobby-Chat</string>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" >
|
<layout class="QGridLayout" >
|
||||||
<property name="margin" >
|
<property name="leftMargin" >
|
||||||
<number>7</number>
|
<number>7</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="spacing" >
|
<property name="topMargin" >
|
||||||
|
<number>7</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin" >
|
||||||
|
<number>7</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin" >
|
||||||
|
<number>7</number>
|
||||||
|
</property>
|
||||||
|
<property name="horizontalSpacing" >
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="verticalSpacing" >
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
<item row="0" column="0" >
|
<item row="0" column="0" >
|
||||||
@@ -40,21 +64,30 @@
|
|||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="3" column="0" >
|
<item row="4" column="0" >
|
||||||
<widget class="Line" name="line" >
|
<widget class="Line" name="line" >
|
||||||
<property name="orientation" >
|
<property name="orientation" >
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="4" column="0" >
|
<item row="5" column="0" >
|
||||||
<layout class="QHBoxLayout" >
|
<layout class="QHBoxLayout" >
|
||||||
<property name="margin" >
|
|
||||||
<number>0</number>
|
|
||||||
</property>
|
|
||||||
<property name="spacing" >
|
<property name="spacing" >
|
||||||
<number>6</number>
|
<number>6</number>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="leftMargin" >
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin" >
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin" >
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin" >
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<spacer>
|
<spacer>
|
||||||
<property name="orientation" >
|
<property name="orientation" >
|
||||||
@@ -93,14 +126,23 @@
|
|||||||
</column>
|
</column>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="0" >
|
<item row="2" column="0" >
|
||||||
<layout class="QHBoxLayout" >
|
<layout class="QHBoxLayout" >
|
||||||
<property name="margin" >
|
|
||||||
<number>0</number>
|
|
||||||
</property>
|
|
||||||
<property name="spacing" >
|
<property name="spacing" >
|
||||||
<number>6</number>
|
<number>6</number>
|
||||||
</property>
|
</property>
|
||||||
|
<property name="leftMargin" >
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin" >
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin" >
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin" >
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="label" >
|
<widget class="QLabel" name="label" >
|
||||||
<property name="text" >
|
<property name="text" >
|
||||||
@@ -137,6 +179,13 @@
|
|||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
|
<item row="1" column="0" >
|
||||||
|
<widget class="QCheckBox" name="checkBox_fillUpWithComputerOpponents" >
|
||||||
|
<property name="text" >
|
||||||
|
<string>Fill up with computer opponents</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
<tabstops>
|
<tabstops>
|
||||||
|
|||||||
@@ -138,20 +138,28 @@ void startNetworkGameDialogImpl::kickPlayer() {
|
|||||||
|
|
||||||
void startNetworkGameDialogImpl::checkPlayerQuantity() {
|
void startNetworkGameDialogImpl::checkPlayerQuantity() {
|
||||||
|
|
||||||
if (treeWidget->topLevelItemCount() >= 2 && isAdmin) {
|
if(isAdmin){
|
||||||
|
pushButton_Kick->show();
|
||||||
|
pushButton_startGame->show();
|
||||||
|
checkBox_fillUpWithComputerOpponents->show();
|
||||||
|
|
||||||
|
if (treeWidget->topLevelItemCount() >= 2) {
|
||||||
pushButton_startGame->setEnabled(true);
|
pushButton_startGame->setEnabled(true);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
pushButton_startGame->setEnabled(false);
|
pushButton_startGame->setEnabled(false);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void startNetworkGameDialogImpl::clearDialog()
|
void startNetworkGameDialogImpl::clearDialog()
|
||||||
{
|
{
|
||||||
|
pushButton_Kick->hide();
|
||||||
|
pushButton_startGame->hide();
|
||||||
pushButton_Kick->setEnabled(false);
|
pushButton_Kick->setEnabled(false);
|
||||||
pushButton_startGame->setEnabled(false);
|
pushButton_startGame->setEnabled(false);
|
||||||
treeWidget->clear();
|
treeWidget->clear();
|
||||||
|
checkBox_fillUpWithComputerOpponents->hide();
|
||||||
}
|
}
|
||||||
|
|
||||||
void startNetworkGameDialogImpl::setSession(Session *session)
|
void startNetworkGameDialogImpl::setSession(Session *session)
|
||||||
|
|||||||
Reference in New Issue
Block a user