This commit is contained in:
@@ -127,6 +127,12 @@ void joinNetworkGameDialogImpl::fillServerProfileList() {
|
||||
profile->QueryIntAttribute("IsIpv6", &tempInt );
|
||||
if( tempInt == 1 ) { isIpv6 = "yes"; }
|
||||
item->setData(3, 0, QString::fromUtf8(isIpv6.c_str()));
|
||||
|
||||
string isSctp = "no";
|
||||
int tempInt1 = 0;
|
||||
profile->QueryIntAttribute("IsSctp", &tempInt1 );
|
||||
if( tempInt1 == 1 ) { isSctp = "yes"; }
|
||||
item->setData(4, 0, QString::fromUtf8(isSctp.c_str()));
|
||||
|
||||
treeWidget->addTopLevelItem(item);
|
||||
}
|
||||
@@ -159,6 +165,7 @@ void joinNetworkGameDialogImpl::itemFillForm (QTreeWidgetItem* item, int column)
|
||||
lineEdit_password->setText(QString::fromUtf8(profile->Attribute("Password")));
|
||||
spinBox_port->setValue(QString::fromUtf8(profile->Attribute("Port")).toInt(&toIntTrue, 10));
|
||||
checkBox_ipv6->setChecked(QString::fromUtf8(profile->Attribute("IsIpv6")).toInt(&toIntTrue, 10));
|
||||
checkBox_sctp->setChecked(QString::fromUtf8(profile->Attribute("IsSctp")).toInt(&toIntTrue, 10));
|
||||
|
||||
}
|
||||
|
||||
@@ -200,6 +207,7 @@ void joinNetworkGameDialogImpl::saveServerProfile() {
|
||||
profile1->SetAttribute("Password", lineEdit_password->text().toUtf8().constData());
|
||||
profile1->SetAttribute("Port", spinBox_port->value());
|
||||
profile1->SetAttribute("IsIpv6", checkBox_ipv6->isChecked());
|
||||
profile1->SetAttribute("IsSctp", checkBox_sctp->isChecked());
|
||||
}
|
||||
break;
|
||||
case QMessageBox::No:
|
||||
@@ -220,6 +228,7 @@ void joinNetworkGameDialogImpl::saveServerProfile() {
|
||||
profile2->SetAttribute("Password", lineEdit_password->text().toUtf8().constData());
|
||||
profile2->SetAttribute("Port", spinBox_port->value());
|
||||
profile2->SetAttribute("IsIpv6", checkBox_ipv6->isChecked());
|
||||
profile2->SetAttribute("IsSctp", checkBox_sctp->isChecked());
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -511,6 +511,9 @@ mainWindowImpl::mainWindowImpl(ConfigFile *c, QMainWindow *parent)
|
||||
myWaitingForServerGameDialog = new waitForServerToStartGameDialogImpl(this);
|
||||
myAboutPokerthDialog = new aboutPokerthImpl(this);
|
||||
|
||||
//dialog settings
|
||||
// mySettingsDialog->checkBox_useSctp->setEnabled(mySession->hasSctp());
|
||||
// myJoinNetworkGameDialog->checkBox_sctp->setEnabled(mySession->hasSctp());
|
||||
|
||||
// //ShortCuts
|
||||
// QShortcut *quitPokerTHKeys = new QShortcut(QKeySequence(Qt::Key_Control + Qt::Key_Q), this);
|
||||
|
||||
@@ -39,7 +39,7 @@
|
||||
<item row="0" column="1" >
|
||||
<widget class="QStackedWidget" name="stackedWidget" >
|
||||
<property name="currentIndex" >
|
||||
<number>3</number>
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="page" >
|
||||
<layout class="QGridLayout" >
|
||||
@@ -725,7 +725,7 @@ p, li { white-space: pre-wrap; }
|
||||
<number>9</number>
|
||||
</property>
|
||||
<property name="spacing" >
|
||||
<number>6</number>
|
||||
<number>15</number>
|
||||
</property>
|
||||
<item row="1" column="2" >
|
||||
<layout class="QGridLayout" >
|
||||
|
||||
@@ -109,6 +109,7 @@ void settingsDialogImpl::exec() {
|
||||
spinBox_serverPort->setValue(myConfig->readConfigInt("ServerPort"));
|
||||
lineEdit_serverPassword->setText(QString::fromUtf8(myConfig->readConfigString("ServerPassword").c_str()));
|
||||
checkBox_useIpv6->setChecked(myConfig->readConfigInt("ServerUseIpv6"));
|
||||
checkBox_useSctp->setChecked(myConfig->readConfigInt("ServerUseSctp"));
|
||||
|
||||
|
||||
|
||||
@@ -187,6 +188,7 @@ void settingsDialogImpl::isAccepted() {
|
||||
myConfig->writeConfigInt("ServerPort", spinBox_serverPort->value());
|
||||
myConfig->writeConfigString("ServerPassword", lineEdit_serverPassword->text().toUtf8().constData());
|
||||
myConfig->writeConfigInt("ServerUseIpv6", checkBox_useIpv6->isChecked());
|
||||
myConfig->writeConfigInt("ServerUseSctp", checkBox_useSctp->isChecked());
|
||||
|
||||
// Interface
|
||||
myConfig->writeConfigInt("ShowLeftToolBox", checkBox_showLeftToolbox->isChecked());
|
||||
|
||||
Reference in New Issue
Block a user