This commit is contained in:
@@ -42,7 +42,7 @@ joinNetworkGameDialogImpl::joinNetworkGameDialogImpl(QWidget *parent)
|
||||
myServerProfilesFile = myConfig.readConfigString("DataDir")+"serverprofiles.xml";
|
||||
|
||||
//Anlegen wenn noch nicht existiert!
|
||||
QFile serverProfilesfile(QString::fromStdString(myServerProfilesFile));
|
||||
QFile serverProfilesfile(QString::fromUtf8(myServerProfilesFile.c_str()));
|
||||
|
||||
if(!serverProfilesfile.exists()) {
|
||||
|
||||
@@ -89,7 +89,7 @@ void joinNetworkGameDialogImpl::fillServerProfileList() {
|
||||
TiXmlDocument doc(myServerProfilesFile);
|
||||
if(!doc.LoadFile()) {
|
||||
QMessageBox::warning(this, tr("Load Server-Profile-File Error"),
|
||||
tr("Could not load server-profiles-file:\n"+QString::fromStdString(myServerProfilesFile).toAscii()),
|
||||
tr("Could not load server-profiles-file:\n"+QString::fromUtf8(myServerProfilesFile.c_str()).toAscii()),
|
||||
QMessageBox::Close);
|
||||
}
|
||||
TiXmlHandle docHandle( &doc );
|
||||
@@ -108,7 +108,7 @@ void joinNetworkGameDialogImpl::fillServerProfileList() {
|
||||
int tempInt = 0;
|
||||
profile->QueryIntAttribute("IsIpv6", &tempInt );
|
||||
if( tempInt == 1 ) { isIpv6 = "yes"; }
|
||||
item->setData(3, 0, QString::fromStdString(isIpv6));
|
||||
item->setData(3, 0, QString::fromUtf8(isIpv6.c_str()));
|
||||
|
||||
treeWidget->addTopLevelItem(item);
|
||||
}
|
||||
@@ -128,7 +128,7 @@ void joinNetworkGameDialogImpl::itemFillForm (QTreeWidgetItem* item, int column)
|
||||
TiXmlDocument doc(myServerProfilesFile);
|
||||
if(!doc.LoadFile()) {
|
||||
QMessageBox::warning(this, tr("Load Server-Profile-File Error"),
|
||||
tr("Could not load server-profiles-file:\n"+QString::fromStdString(myServerProfilesFile).toAscii()),
|
||||
tr("Could not load server-profiles-file:\n"+QString::fromUtf8(myServerProfilesFile.c_str()).toAscii()),
|
||||
QMessageBox::Close);
|
||||
}
|
||||
TiXmlHandle docHandle( &doc );
|
||||
@@ -136,11 +136,11 @@ void joinNetworkGameDialogImpl::itemFillForm (QTreeWidgetItem* item, int column)
|
||||
TiXmlElement* profile = docHandle.FirstChild( "PokerTH" ).FirstChild( "ServerProfiles" ).FirstChild( item->data(0,0).toString().toStdString() ).ToElement();
|
||||
if ( profile ) {
|
||||
|
||||
lineEdit_profileName->setText(QString::fromStdString(profile->Attribute("Name")));
|
||||
lineEdit_ipAddress->setText(QString::fromStdString(profile->Attribute("Address")));
|
||||
lineEdit_password->setText(QString::fromStdString(profile->Attribute("Password")));
|
||||
spinBox_port->setValue(QString::fromStdString(profile->Attribute("Port")).toInt(&toIntTrue, 10));
|
||||
checkBox_ipv6->setChecked(QString::fromStdString(profile->Attribute("IsIpv6")).toInt(&toIntTrue, 10));
|
||||
lineEdit_profileName->setText(QString::fromUtf8(profile->Attribute("Name")));
|
||||
lineEdit_ipAddress->setText(QString::fromUtf8(profile->Attribute("Address")));
|
||||
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));
|
||||
|
||||
}
|
||||
|
||||
@@ -154,7 +154,7 @@ void joinNetworkGameDialogImpl::saveServerProfile() {
|
||||
TiXmlDocument doc(myServerProfilesFile);
|
||||
if(!doc.LoadFile()) {
|
||||
QMessageBox::warning(this, tr("Load Server-Profile-File Error"),
|
||||
tr("Could not load server-profiles-file:\n"+QString::fromStdString(myServerProfilesFile).toAscii()),
|
||||
tr("Could not load server-profiles-file:\n"+QString::fromUtf8(myServerProfilesFile.c_str()).toAscii()),
|
||||
QMessageBox::Close);
|
||||
}
|
||||
TiXmlHandle docHandle( &doc );
|
||||
@@ -210,7 +210,7 @@ void joinNetworkGameDialogImpl::saveServerProfile() {
|
||||
QMessageBox::Close); }
|
||||
|
||||
if(!doc.SaveFile()) { QMessageBox::warning(this, tr("Save Server-Profile-File Error"),
|
||||
tr("Could not save server-profiles-file:\n"+QString::fromStdString(myServerProfilesFile).toAscii()),
|
||||
tr("Could not save server-profiles-file:\n"+QString::fromUtf8(myServerProfilesFile.c_str()).toAscii()),
|
||||
QMessageBox::Close); }
|
||||
|
||||
fillServerProfileList();
|
||||
@@ -221,7 +221,7 @@ void joinNetworkGameDialogImpl::deleteServerProfile() {
|
||||
TiXmlDocument doc(myServerProfilesFile);
|
||||
if(!doc.LoadFile()) {
|
||||
QMessageBox::warning(this, tr("Load Server-Profile-File Error"),
|
||||
tr("Could not load server-profiles-file:\n"+QString::fromStdString(myServerProfilesFile).toAscii()),
|
||||
tr("Could not load server-profiles-file:\n"+QString::fromUtf8(myServerProfilesFile.c_str()).toAscii()),
|
||||
QMessageBox::Close);
|
||||
}
|
||||
else {
|
||||
@@ -232,7 +232,7 @@ void joinNetworkGameDialogImpl::deleteServerProfile() {
|
||||
if ( profile ) { profile->Parent()->RemoveChild(profile); }
|
||||
|
||||
if(!doc.SaveFile()) { QMessageBox::warning(this, tr("Save Server-Profile-File Error"),
|
||||
tr("Could not save server-profiles-file:\n"+QString::fromStdString(myServerProfilesFile).toAscii()),
|
||||
tr("Could not save server-profiles-file:\n"+QString::fromUtf8(myServerProfilesFile.c_str()).toAscii()),
|
||||
QMessageBox::Close); }
|
||||
|
||||
//Liste Füllen
|
||||
|
||||
+21
-18
@@ -28,12 +28,12 @@ Log::Log(mainWindowImpl* w) : myW(w)
|
||||
myW->setLog(this);
|
||||
|
||||
myConfig = new ConfigFile;
|
||||
if(myConfig->readConfigString("LogDir") != "" && QDir::QDir(QString::fromStdString(myConfig->readConfigString("LogDir"))).exists()) {
|
||||
if(myConfig->readConfigString("LogDir") != "" && QDir::QDir(QString::fromUtf8(myConfig->readConfigString("LogDir").c_str())).exists()) {
|
||||
|
||||
#ifdef _WIN32
|
||||
myLogDir = new QDir(QString::fromStdString(myConfig->readConfigString("LogDir")));
|
||||
myLogDir = new QDir(QString::fromUtf8(myConfig->readConfigString("LogDir").c_str()));
|
||||
#else
|
||||
myLogDir = new QDir(QString::fromStdString(myConfig->readConfigString("LogDir")));
|
||||
myLogDir = new QDir(QString::fromUtf8(myConfig->readConfigString("LogDir").c_str()));
|
||||
#endif
|
||||
myLogFile = new QFile(myLogDir->absolutePath()+"/pokerth-log-"+QDateTime::currentDateTime().toString("yyyy-MM-dd_hh.mm.ss")+".html");
|
||||
|
||||
@@ -45,6 +45,9 @@ Log::Log(mainWindowImpl* w) : myW(w)
|
||||
myLogFile->open( QIODevice::WriteOnly );
|
||||
QTextStream stream( myLogFile );
|
||||
stream << "<html>\n";
|
||||
stream << "<head>\n";
|
||||
stream << "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=utf8\">";
|
||||
stream << "</head>\n";
|
||||
stream << "<body>\n";
|
||||
stream << "<img src='logo.png'>\n";
|
||||
stream << "<h3><b>Log-File for PokerTH Session started on "+QDate::currentDate().toString("yyyy-MM-dd")+" at "+QTime::currentTime().toString("hh:mm:ss")+"</b></h3>\n";
|
||||
@@ -95,7 +98,7 @@ void Log::logPlayerActionMsg(string playerName, int action, int setValue) {
|
||||
int i;
|
||||
|
||||
QString msg;
|
||||
msg = QString::fromStdString(playerName);
|
||||
msg = QString::fromUtf8(playerName.c_str());
|
||||
|
||||
switch (action) {
|
||||
|
||||
@@ -160,12 +163,12 @@ void Log::logNewGameHandMsg(int gameID, int handID) {
|
||||
if(myW->getActualHand()->getPlayerArray()[i]->getMyButton() == 1) {
|
||||
if(k==1) { stream << ", "; }
|
||||
k=1;
|
||||
stream << QString::fromStdString(myW->getActualHand()->getPlayerArray()[i]->getMyName())+" (Dealer): "+QString::number(myW->getActualHand()->getPlayerArray()[i]->getMyCash(),10)+"$";
|
||||
stream << QString::fromUtf8(myW->getActualHand()->getPlayerArray()[i]->getMyName().c_str())+" (Dealer): "+QString::number(myW->getActualHand()->getPlayerArray()[i]->getMyCash(),10)+"$";
|
||||
}
|
||||
else {
|
||||
if(k==1) { stream << ", "; }
|
||||
k=1;
|
||||
stream << QString::fromStdString(myW->getActualHand()->getPlayerArray()[i]->getMyName())+": "+QString::number(myW->getActualHand()->getPlayerArray()[i]->getMyCash()+myW->getActualHand()->getPlayerArray()[i]->getMySet(),10)+"$";
|
||||
stream << QString::fromUtf8(myW->getActualHand()->getPlayerArray()[i]->getMyName().c_str())+": "+QString::number(myW->getActualHand()->getPlayerArray()[i]->getMyCash()+myW->getActualHand()->getPlayerArray()[i]->getMySet(),10)+"$";
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -177,12 +180,12 @@ void Log::logNewGameHandMsg(int gameID, int handID) {
|
||||
if(myW->getActualHand()->getPlayerArray()[i]->getMyButton() == 3) {
|
||||
if(k==1) { stream << ", "; }
|
||||
k=1;
|
||||
stream << QString::fromStdString(myW->getActualHand()->getPlayerArray()[i]->getMyName())+" (Dealer): "+QString::number(myW->getActualHand()->getPlayerArray()[i]->getMyCash(),10)+"$";
|
||||
stream << QString::fromUtf8(myW->getActualHand()->getPlayerArray()[i]->getMyName().c_str())+" (Dealer): "+QString::number(myW->getActualHand()->getPlayerArray()[i]->getMyCash()+myW->getActualHand()->getPlayerArray()[i]->getMySet(),10)+"$";
|
||||
}
|
||||
else {
|
||||
if(k==1) { stream << ", "; }
|
||||
k=1;
|
||||
stream << QString::fromStdString(myW->getActualHand()->getPlayerArray()[i]->getMyName())+": "+QString::number(myW->getActualHand()->getPlayerArray()[i]->getMyCash()+myW->getActualHand()->getPlayerArray()[i]->getMySet(),10)+"$";
|
||||
stream << QString::fromUtf8(myW->getActualHand()->getPlayerArray()[i]->getMyName().c_str())+": "+QString::number(myW->getActualHand()->getPlayerArray()[i]->getMyCash()+myW->getActualHand()->getPlayerArray()[i]->getMySet(),10)+"$";
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -202,9 +205,9 @@ void Log::logNewGameHandMsg(int gameID, int handID) {
|
||||
// cout << (i+myW->getActualHand()->getDealerPosition()+j)%5 << endl;
|
||||
|
||||
switch (myW->getActualHand()->getPlayerArray()[(i+myW->getActualHand()->getDealerPosition()+j)%myW->getMaxQuantityPlayers()]->getMyButton()) {
|
||||
case 2 : stream << QString::fromStdString(myW->getActualHand()->getPlayerArray()[(i+myW->getActualHand()->getDealerPosition()+j)%myW->getMaxQuantityPlayers()]->getMyName())+" ("+QString::number(myW->getActualHand()->getPlayerArray()[(i+myW->getActualHand()->getDealerPosition()+j)%myW->getMaxQuantityPlayers()]->getMySet(),10)+"$), ";
|
||||
case 2 : stream << QString::fromUtf8(myW->getActualHand()->getPlayerArray()[(i+myW->getActualHand()->getDealerPosition()+j)%myW->getMaxQuantityPlayers()]->getMyName().c_str())+" ("+QString::number(myW->getActualHand()->getPlayerArray()[(i+myW->getActualHand()->getDealerPosition()+j)%myW->getMaxQuantityPlayers()]->getMySet(),10)+"$), ";
|
||||
break;
|
||||
case 3 : stream << QString::fromStdString(myW->getActualHand()->getPlayerArray()[(i+myW->getActualHand()->getDealerPosition()+j)%myW->getMaxQuantityPlayers()]->getMyName())+" ("+QString::number(myW->getActualHand()->getPlayerArray()[(i+myW->getActualHand()->getDealerPosition()+j)%myW->getMaxQuantityPlayers()]->getMySet(),10)+"$)";
|
||||
case 3 : stream << QString::fromUtf8(myW->getActualHand()->getPlayerArray()[(i+myW->getActualHand()->getDealerPosition()+j)%myW->getMaxQuantityPlayers()]->getMyName().c_str())+" ("+QString::number(myW->getActualHand()->getPlayerArray()[(i+myW->getActualHand()->getDealerPosition()+j)%myW->getMaxQuantityPlayers()]->getMySet(),10)+"$)";
|
||||
break;
|
||||
default :;
|
||||
}
|
||||
@@ -228,12 +231,12 @@ void Log::logPlayerWinsMsg(int playerID, int pot) {
|
||||
for(i=0; i<=linesInFile; i++) { stream.readLine(); }
|
||||
|
||||
// if (cardsValueInt != -1) {
|
||||
// myW->textBrowser_Log->append(QString::fromStdString(myW->getActualHand()->getPlayerArray()[playerID]->getMyName())+" wins "+QString::number(pot,10)+"$ with "+translateCardsValueCode(cardsValueInt).at(0)+"!!! ");
|
||||
// stream << "</br><i>"+QString::fromStdString(myW->getActualHand()->getPlayerArray()[playerID]->getMyName())+" wins "+QString::number(pot,10)+"$!!!</i></p>\n";
|
||||
// myW->textBrowser_Log->append(QString::fromUtf8(myW->getActualHand()->getPlayerArray()[playerID]->getMyName())+" wins "+QString::number(pot,10)+"$ with "+translateCardsValueCode(cardsValueInt).at(0)+"!!! ");
|
||||
// stream << "</br><i>"+QString::fromUtf8(myW->getActualHand()->getPlayerArray()[playerID]->getMyName())+" wins "+QString::number(pot,10)+"$!!!</i></p>\n";
|
||||
// }
|
||||
// else {
|
||||
myW->textBrowser_Log->append(QString::fromStdString(myW->getActualHand()->getPlayerArray()[playerID]->getMyName())+" wins "+QString::number(pot,10)+"$!!! ");
|
||||
stream << "</br><i>"+QString::fromStdString(myW->getActualHand()->getPlayerArray()[playerID]->getMyName())+" wins "+QString::number(pot,10)+"$!!!</i></p>\n";
|
||||
myW->textBrowser_Log->append(QString::fromUtf8(myW->getActualHand()->getPlayerArray()[playerID]->getMyName().c_str())+" wins "+QString::number(pot,10)+"$!!! ");
|
||||
stream << "</br><i>"+QString::fromUtf8(myW->getActualHand()->getPlayerArray()[playerID]->getMyName().c_str())+" wins "+QString::number(pot,10)+"$!!!</i></p>\n";
|
||||
// }
|
||||
myLogFile->close();
|
||||
|
||||
@@ -384,13 +387,13 @@ void Log::logFlipHoleCardsMsg(std::string playerName, int card1, int card2, int
|
||||
default: {}
|
||||
}
|
||||
|
||||
myW->textBrowser_Log->append(QString::fromStdString(playerName)+" "+QString::fromStdString(showHas)+" \""+tempHandName+"\"");
|
||||
stream << QString::fromStdString(playerName)+" "+QString::fromStdString(showHas)+" [ <b>"+translateCardCode(card1).at(0)+"</b>"+translateCardCode(card1).at(1)+",<b>"+translateCardCode(card2).at(0)+"</b>"+translateCardCode(card2).at(1)+"] - "+tempHandName+"</br>\n";
|
||||
myW->textBrowser_Log->append(QString::fromUtf8(playerName.c_str())+" "+QString::fromUtf8(showHas.c_str())+" \""+tempHandName+"\"");
|
||||
stream << QString::fromUtf8(playerName.c_str())+" "+QString::fromUtf8(showHas.c_str())+" [ <b>"+translateCardCode(card1).at(0)+"</b>"+translateCardCode(card1).at(1)+",<b>"+translateCardCode(card2).at(0)+"</b>"+translateCardCode(card2).at(1)+"] - "+tempHandName+"</br>\n";
|
||||
|
||||
}
|
||||
else {
|
||||
myW->textBrowser_Log->append(QString::fromStdString(playerName)+" "+QString::fromStdString(showHas)+" ["+translateCardCode(card1).at(0)+translateCardCode(card1).at(1)+","+translateCardCode(card2).at(0)+translateCardCode(card2).at(1)+"]");
|
||||
stream << QString::fromStdString(playerName)+" "+QString::fromStdString(showHas)+" [<b>"+translateCardCode(card1).at(0)+"</b>"+translateCardCode(card1).at(1)+",<b>"+translateCardCode(card2).at(0)+"</b>"+translateCardCode(card2).at(1)+"]"+"</br>\n";
|
||||
myW->textBrowser_Log->append(QString::fromUtf8(playerName.c_str())+" "+QString::fromUtf8(showHas.c_str())+" ["+translateCardCode(card1).at(0)+translateCardCode(card1).at(1)+","+translateCardCode(card2).at(0)+translateCardCode(card2).at(1)+"]");
|
||||
stream << QString::fromUtf8(playerName.c_str())+" "+QString::fromUtf8(showHas.c_str())+" [<b>"+translateCardCode(card1).at(0)+"</b>"+translateCardCode(card1).at(1)+",<b>"+translateCardCode(card2).at(0)+"</b>"+translateCardCode(card2).at(1)+"]"+"</br>\n";
|
||||
|
||||
}
|
||||
myLogFile->close();
|
||||
|
||||
+168
-3
@@ -1347,6 +1347,9 @@
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton_break" >
|
||||
<property name="enabled" >
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="maximumSize" >
|
||||
<size>
|
||||
<width>40</width>
|
||||
@@ -1356,6 +1359,15 @@
|
||||
<property name="palette" >
|
||||
<palette>
|
||||
<active>
|
||||
<colorrole role="WindowText" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>240</red>
|
||||
<green>240</green>
|
||||
<blue>240</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="Button" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
@@ -1365,6 +1377,33 @@
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="Light" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>255</red>
|
||||
<green>255</green>
|
||||
<blue>255</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="Text" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>240</red>
|
||||
<green>240</green>
|
||||
<blue>240</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="BrightText" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>255</red>
|
||||
<green>255</green>
|
||||
<blue>255</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="ButtonText" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
@@ -1383,8 +1422,35 @@
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="HighlightedText" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>255</red>
|
||||
<green>255</green>
|
||||
<blue>255</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="AlternateBase" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>232</red>
|
||||
<green>232</green>
|
||||
<blue>232</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
</active>
|
||||
<inactive>
|
||||
<colorrole role="WindowText" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>240</red>
|
||||
<green>240</green>
|
||||
<blue>240</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="Button" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
@@ -1394,6 +1460,33 @@
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="Light" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>255</red>
|
||||
<green>255</green>
|
||||
<blue>255</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="Text" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>240</red>
|
||||
<green>240</green>
|
||||
<blue>240</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="BrightText" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>255</red>
|
||||
<green>255</green>
|
||||
<blue>255</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="ButtonText" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
@@ -1412,8 +1505,35 @@
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="HighlightedText" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>255</red>
|
||||
<green>255</green>
|
||||
<blue>255</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="AlternateBase" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>232</red>
|
||||
<green>232</green>
|
||||
<blue>232</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
</inactive>
|
||||
<disabled>
|
||||
<colorrole role="WindowText" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>131</red>
|
||||
<green>153</green>
|
||||
<blue>86</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="Button" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
@@ -1423,12 +1543,39 @@
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="Light" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>131</red>
|
||||
<green>153</green>
|
||||
<blue>86</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="Text" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>131</red>
|
||||
<green>153</green>
|
||||
<blue>86</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="BrightText" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>131</red>
|
||||
<green>153</green>
|
||||
<blue>86</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="ButtonText" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>128</red>
|
||||
<green>128</green>
|
||||
<blue>128</blue>
|
||||
<red>131</red>
|
||||
<green>153</green>
|
||||
<blue>86</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
@@ -1441,6 +1588,24 @@
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="HighlightedText" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>131</red>
|
||||
<green>153</green>
|
||||
<blue>86</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
<colorrole role="AlternateBase" >
|
||||
<brush brushstyle="SolidPattern" >
|
||||
<color alpha="255" >
|
||||
<red>131</red>
|
||||
<green>153</green>
|
||||
<blue>86</blue>
|
||||
</color>
|
||||
</brush>
|
||||
</colorrole>
|
||||
</disabled>
|
||||
</palette>
|
||||
</property>
|
||||
|
||||
@@ -58,19 +58,25 @@ mainWindowImpl::mainWindowImpl(QMainWindow *parent)
|
||||
{
|
||||
int i;
|
||||
|
||||
//for statistic development
|
||||
for(i=0; i<15; i++) {
|
||||
statisticArray[i] = 0;
|
||||
}
|
||||
////////////////////////////
|
||||
|
||||
myConfig = new ConfigFile;
|
||||
|
||||
// Resourcen abladen
|
||||
QFile preflopValuesFile(":data/resources/data/preflopValues");
|
||||
QFile preflopValuesFileDest(QString::fromStdString(myConfig->readConfigString("DataDir")+"preflopValues"));
|
||||
QFile preflopValuesFileDest(QString::fromUtf8(myConfig->readConfigString("DataDir").c_str())+QString("preflopValues"));
|
||||
// if(!preflopValuesFileDest.exists()) {
|
||||
preflopValuesFile.copy(QString::fromStdString(myConfig->readConfigString("DataDir")+"preflopValues"));
|
||||
preflopValuesFile.copy(QString::fromUtf8(myConfig->readConfigString("DataDir").c_str())+QString("preflopValues"));
|
||||
// }
|
||||
|
||||
QFile flopValuesFile(":data/resources/data/flopValues");
|
||||
QFile flopValuesFileDest(QString::fromStdString(myConfig->readConfigString("DataDir")+"flopValues"));
|
||||
QFile flopValuesFileDest(QString::fromUtf8(myConfig->readConfigString("DataDir").c_str())+QString("flopValues"));
|
||||
// if(!flopValuesFileDest.exists()) {
|
||||
flopValuesFile.copy(QString::fromStdString(myConfig->readConfigString("DataDir")+"flopValues"));
|
||||
flopValuesFile.copy(QString::fromUtf8(myConfig->readConfigString("DataDir").c_str())+QString("flopValues"));
|
||||
// }
|
||||
|
||||
// Schriftart laden und für Dialoge setzen
|
||||
@@ -196,7 +202,7 @@ mainWindowImpl::mainWindowImpl(QMainWindow *parent)
|
||||
flipside = new QPixmap(":/cards/resources/graphics/cards/flipside.png");
|
||||
|
||||
if (myConfig->readConfigInt("FlipsideOwn") && myConfig->readConfigString("FlipsideOwnFile") != "") {
|
||||
QPixmap tmpFlipside(QString::fromStdString(myConfig->readConfigString("FlipsideOwnFile")));
|
||||
QPixmap tmpFlipside(QString::fromUtf8(myConfig->readConfigString("FlipsideOwnFile").c_str()));
|
||||
flipside = new QPixmap(tmpFlipside.scaled(QSize(57, 80)));
|
||||
}
|
||||
else { flipside->load(":/cards/resources/graphics/cards/flipside.png"); }
|
||||
@@ -727,7 +733,7 @@ void mainWindowImpl::callSettingsDialog() {
|
||||
//Flipside refresh
|
||||
if (myConfig->readConfigInt("FlipsideOwn") && myConfig->readConfigString("FlipsideOwnFile") != "") {
|
||||
|
||||
QPixmap tmpFlipside(QString::fromStdString(myConfig->readConfigString("FlipsideOwnFile")));
|
||||
QPixmap tmpFlipside(QString::fromUtf8(myConfig->readConfigString("FlipsideOwnFile").c_str()));
|
||||
flipside = new QPixmap(tmpFlipside.scaled(QSize(57, 80)));
|
||||
}
|
||||
else { flipside->load(":/cards/resources/graphics/cards/flipside.png"); }
|
||||
@@ -805,7 +811,7 @@ void mainWindowImpl::refreshPlayerName() {
|
||||
int i;
|
||||
for (i=0; i<maxQuantityPlayers; i++) {
|
||||
if(actualHand->getPlayerArray()[i]->getMyActiveStatus()) {
|
||||
playerNameLabelArray[i]->setText(QString::fromStdString(actualHand->getPlayerArray()[i]->getMyName()));
|
||||
playerNameLabelArray[i]->setText(QString::fromUtf8(actualHand->getPlayerArray()[i]->getMyName().c_str()));
|
||||
|
||||
} else {
|
||||
playerNameLabelArray[i]->setText("");
|
||||
@@ -828,7 +834,7 @@ void mainWindowImpl::refreshPlayerAvatar() {
|
||||
playerAvatarLabelArray[0]->setPixmap(QPixmap(":/guiv2/resources/guiv2/genereticAvatar.png"));
|
||||
}
|
||||
else {
|
||||
playerAvatarLabelArray[0]->setPixmap(QString::fromStdString(actualHand->getPlayerArray()[0]->getMyAvatar()));
|
||||
playerAvatarLabelArray[0]->setPixmap(QString::fromUtf8(actualHand->getPlayerArray()[0]->getMyAvatar().c_str()));
|
||||
}
|
||||
}
|
||||
else {
|
||||
@@ -836,7 +842,7 @@ void mainWindowImpl::refreshPlayerAvatar() {
|
||||
playerAvatarLabelArray[i]->setPixmap(QPixmap(":/guiv2/resources/guiv2/genereticAvatar.png"));
|
||||
}
|
||||
else {
|
||||
playerAvatarLabelArray[i]->setPixmap(QString::fromStdString(actualHand->getPlayerArray()[i]->getMyAvatar()));
|
||||
playerAvatarLabelArray[i]->setPixmap(QString::fromUtf8(actualHand->getPlayerArray()[i]->getMyAvatar().c_str()));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1005,7 +1011,7 @@ void mainWindowImpl::refreshGroupbox(int playerID, int status) {
|
||||
|
||||
void mainWindowImpl::highlightRoundLabel(string tempround) {
|
||||
|
||||
QString round (QString::fromStdString(tempround));
|
||||
QString round (QString::fromUtf8(tempround.c_str()));
|
||||
|
||||
// für PostRiverRun (alte Runden stehen lassen)
|
||||
if(round != "") {
|
||||
@@ -1840,16 +1846,31 @@ void mainWindowImpl::postRiverRunAnimation5() {
|
||||
void mainWindowImpl::postRiverRunAnimation6() {
|
||||
|
||||
int i;
|
||||
|
||||
refreshCash();
|
||||
refreshPot();
|
||||
|
||||
// wenn nur noch ein Spieler aktive "neues Spiel"-Dialog anzeigen
|
||||
int playersPositiveCashCounter = 0;
|
||||
for (i=0; i<actualGame->getStartQuantityPlayers(); i++) {
|
||||
// cout << "player 0 cash: " << actualHand->getPlayerArray()[0]->getMyCash()
|
||||
|
||||
if (actualHand->getPlayerArray()[i]->getMyCash() > 0) playersPositiveCashCounter++;
|
||||
if (actualHand->getPlayerArray()[i]->getMyCash() > 0)
|
||||
playersPositiveCashCounter++;
|
||||
}
|
||||
if (playersPositiveCashCounter==1) {
|
||||
|
||||
// for (i=0; i<actualGame->getStartQuantityPlayers(); i++) {
|
||||
// // cout << "player 0 cash: " << actualHand->getPlayerArray()[0]->getMyCash()
|
||||
// if (actualHand->getPlayerArray()[i]->getMyCash() > 0) {
|
||||
// (statisticArray[actualHand->getPlayerArray()[i]->getMyDude4()+7])++;
|
||||
// }
|
||||
// }
|
||||
|
||||
// for(i=0; i<15; i++) {
|
||||
// cout << i-7 << ": " << statisticArray[i] << " | ";
|
||||
// }
|
||||
// cout << endl;
|
||||
|
||||
callNewGameDialog();
|
||||
//Bei Cancel nichts machen!!!
|
||||
|
||||
@@ -308,6 +308,9 @@ private:
|
||||
QColor inactive;
|
||||
QColor highlight;
|
||||
|
||||
// statistic testing
|
||||
int statisticArray[15];
|
||||
|
||||
friend class GuiWrapper;
|
||||
};
|
||||
|
||||
|
||||
+309
-248
@@ -137,7 +137,7 @@
|
||||
<string><html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Nimbus Sans L'; font-size:9pt; font-weight:400; font-style:normal; text-decoration:none;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-style:italic;">Note: Best Quality with Image Ratio like </span><span style=" font-weight:600; font-style:italic;">Width=100, Height=140</span></p></body></html></string>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-style:italic;">Note: Best quality with image ratio like </span><span style=" font-weight:600; font-style:italic;">width=100, height=140.</span></p></body></html></string>
|
||||
</property>
|
||||
<property name="wordWrap" >
|
||||
<bool>true</bool>
|
||||
@@ -608,6 +608,13 @@ p, li { white-space: pre-wrap; }
|
||||
<property name="spacing" >
|
||||
<number>6</number>
|
||||
</property>
|
||||
<item row="1" column="0" >
|
||||
<widget class="Line" name="line_4" >
|
||||
<property name="orientation" >
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0" >
|
||||
<widget class="QGroupBox" name="groupBox_3" >
|
||||
<property name="title" >
|
||||
@@ -620,6 +627,90 @@ p, li { white-space: pre-wrap; }
|
||||
<property name="spacing" >
|
||||
<number>5</number>
|
||||
</property>
|
||||
<item row="3" column="1" >
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent4Name" />
|
||||
</item>
|
||||
<item row="2" column="3" >
|
||||
<layout class="QHBoxLayout" >
|
||||
<property name="margin" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="spacing" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent3Avatar" />
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton_openAvatarFile3" >
|
||||
<property name="minimumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="icon" >
|
||||
<iconset resource="resources.qrc" >:/graphics/resources/graphics/fileopen16.png</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="4" column="0" >
|
||||
<widget class="QLabel" name="label_26" >
|
||||
<property name="text" >
|
||||
<string>Opponent 5:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="2" >
|
||||
<widget class="QLabel" name="label_22" >
|
||||
<property name="text" >
|
||||
<string>Avatar:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="3" >
|
||||
<layout class="QHBoxLayout" >
|
||||
<property name="margin" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="spacing" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent2Avatar" />
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton_openAvatarFile2" >
|
||||
<property name="minimumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="icon" >
|
||||
<iconset resource="resources.qrc" >:/graphics/resources/graphics/fileopen16.png</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="0" column="1" >
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent1Name" />
|
||||
</item>
|
||||
<item row="5" column="3" >
|
||||
<layout class="QHBoxLayout" >
|
||||
<property name="margin" >
|
||||
@@ -652,6 +743,149 @@ p, li { white-space: pre-wrap; }
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="2" column="0" >
|
||||
<widget class="QLabel" name="label_11" >
|
||||
<property name="text" >
|
||||
<string>Opponent 3:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="1" >
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent6Name" />
|
||||
</item>
|
||||
<item row="0" column="3" >
|
||||
<layout class="QHBoxLayout" >
|
||||
<property name="margin" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="spacing" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent1Avatar" />
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton_openAvatarFile1" >
|
||||
<property name="minimumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="icon" >
|
||||
<iconset resource="resources.qrc" >:/graphics/resources/graphics/fileopen16.png</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="1" column="1" >
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent2Name" />
|
||||
</item>
|
||||
<item row="2" column="2" >
|
||||
<widget class="QLabel" name="label_24" >
|
||||
<property name="text" >
|
||||
<string>Avatar:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="2" >
|
||||
<widget class="QLabel" name="label_21" >
|
||||
<property name="text" >
|
||||
<string>Avatar:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0" >
|
||||
<widget class="QLabel" name="label_10" >
|
||||
<property name="text" >
|
||||
<string>Opponent 2:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="2" >
|
||||
<widget class="QLabel" name="label_25" >
|
||||
<property name="text" >
|
||||
<string>Avatar:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="0" >
|
||||
<widget class="QLabel" name="label_32" >
|
||||
<property name="text" >
|
||||
<string>Opponent 6:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="2" >
|
||||
<widget class="QLabel" name="label_30" >
|
||||
<property name="text" >
|
||||
<string>Avatar:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0" >
|
||||
<widget class="QLabel" name="label_9" >
|
||||
<property name="text" >
|
||||
<string>Opponent 1:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0" >
|
||||
<widget class="QLabel" name="label_12" >
|
||||
<property name="text" >
|
||||
<string>Opponent 4:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="2" >
|
||||
<widget class="QLabel" name="label_31" >
|
||||
<property name="text" >
|
||||
<string>Avatar:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="1" >
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent3Name" />
|
||||
</item>
|
||||
<item row="3" column="3" >
|
||||
<layout class="QHBoxLayout" >
|
||||
<property name="margin" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="spacing" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent4Avatar" />
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton_openAvatarFile4" >
|
||||
<property name="minimumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="icon" >
|
||||
<iconset resource="resources.qrc" >:/graphics/resources/graphics/fileopen16.png</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="4" column="3" >
|
||||
<layout class="QHBoxLayout" >
|
||||
<property name="margin" >
|
||||
@@ -684,259 +918,12 @@ p, li { white-space: pre-wrap; }
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="3" column="3" >
|
||||
<layout class="QHBoxLayout" >
|
||||
<property name="margin" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="spacing" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent4Avatar" />
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton_openAvatarFile4" >
|
||||
<property name="minimumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="icon" >
|
||||
<iconset resource="resources.qrc" >:/graphics/resources/graphics/fileopen16.png</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="2" column="3" >
|
||||
<layout class="QHBoxLayout" >
|
||||
<property name="margin" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="spacing" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent3Avatar" />
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton_openAvatarFile3" >
|
||||
<property name="minimumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="icon" >
|
||||
<iconset resource="resources.qrc" >:/graphics/resources/graphics/fileopen16.png</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="1" column="3" >
|
||||
<layout class="QHBoxLayout" >
|
||||
<property name="margin" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="spacing" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent2Avatar" />
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton_openAvatarFile2" >
|
||||
<property name="minimumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="icon" >
|
||||
<iconset resource="resources.qrc" >:/graphics/resources/graphics/fileopen16.png</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="0" column="3" >
|
||||
<layout class="QHBoxLayout" >
|
||||
<property name="margin" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="spacing" >
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent1Avatar" />
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="pushButton_openAvatarFile1" >
|
||||
<property name="minimumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize" >
|
||||
<size>
|
||||
<width>27</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="icon" >
|
||||
<iconset resource="resources.qrc" >:/graphics/resources/graphics/fileopen16.png</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="2" column="2" >
|
||||
<widget class="QLabel" name="label_24" >
|
||||
<property name="text" >
|
||||
<string>Avatar:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="2" >
|
||||
<widget class="QLabel" name="label_21" >
|
||||
<property name="text" >
|
||||
<string>Avatar:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="2" >
|
||||
<widget class="QLabel" name="label_22" >
|
||||
<property name="text" >
|
||||
<string>Avatar:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="2" >
|
||||
<widget class="QLabel" name="label_25" >
|
||||
<property name="text" >
|
||||
<string>Avatar:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="2" >
|
||||
<widget class="QLabel" name="label_30" >
|
||||
<property name="text" >
|
||||
<string>Avatar:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="2" >
|
||||
<widget class="QLabel" name="label_31" >
|
||||
<property name="text" >
|
||||
<string>Avatar:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="1" >
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent4Name" />
|
||||
</item>
|
||||
<item row="2" column="1" >
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent3Name" />
|
||||
</item>
|
||||
<item row="0" column="1" >
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent1Name" />
|
||||
</item>
|
||||
<item row="1" column="1" >
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent2Name" />
|
||||
</item>
|
||||
<item row="5" column="1" >
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent6Name" />
|
||||
</item>
|
||||
<item row="4" column="1" >
|
||||
<widget class="QLineEdit" name="lineEdit_Opponent5Name" />
|
||||
</item>
|
||||
<item row="1" column="0" >
|
||||
<widget class="QLabel" name="label_10" >
|
||||
<property name="text" >
|
||||
<string>Opponent 2:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0" >
|
||||
<widget class="QLabel" name="label_11" >
|
||||
<property name="text" >
|
||||
<string>Opponent 3:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="3" column="0" >
|
||||
<widget class="QLabel" name="label_12" >
|
||||
<property name="text" >
|
||||
<string>Opponent 4:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="0" >
|
||||
<widget class="QLabel" name="label_9" >
|
||||
<property name="text" >
|
||||
<string>Opponent 1:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0" >
|
||||
<widget class="QLabel" name="label_26" >
|
||||
<property name="text" >
|
||||
<string>Opponent 5:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="5" column="0" >
|
||||
<widget class="QLabel" name="label_32" >
|
||||
<property name="text" >
|
||||
<string>Opponent 6:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0" >
|
||||
<spacer>
|
||||
<property name="orientation" >
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" >
|
||||
<size>
|
||||
<width>295</width>
|
||||
<height>51</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item row="1" column="0" >
|
||||
<widget class="Line" name="line_4" >
|
||||
<property name="orientation" >
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0" >
|
||||
<layout class="QHBoxLayout" >
|
||||
<property name="margin" >
|
||||
@@ -996,6 +983,19 @@ p, li { white-space: pre-wrap; }
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item row="5" column="0" >
|
||||
<spacer>
|
||||
<property name="orientation" >
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" >
|
||||
<size>
|
||||
<width>295</width>
|
||||
<height>51</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item row="0" column="0" >
|
||||
<widget class="QLabel" name="label_7" >
|
||||
<property name="font" >
|
||||
@@ -1009,6 +1009,16 @@ p, li { white-space: pre-wrap; }
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="4" column="0" >
|
||||
<widget class="QLabel" name="label_38" >
|
||||
<property name="text" >
|
||||
<string><html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Nimbus Sans L'; font-size:9pt; font-weight:400; font-style:normal; text-decoration:none;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-style:italic;">Note: Best quality with image ratio like </span><span style=" font-weight:600; font-style:italic;">width=50, height=50.</span></p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="page_5" >
|
||||
@@ -1206,6 +1216,57 @@ p, li { white-space: pre-wrap; }
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>listWidget</tabstop>
|
||||
<tabstop>checkBox_showIntro</tabstop>
|
||||
<tabstop>checkBox_showLeftToolbox</tabstop>
|
||||
<tabstop>checkBox_showRightToolbox</tabstop>
|
||||
<tabstop>checkBox_showStatusbarMessages</tabstop>
|
||||
<tabstop>checkBox_showFadeOutCardsAnimation</tabstop>
|
||||
<tabstop>checkBox_showFlipCardsAnimation</tabstop>
|
||||
<tabstop>radioButton_flipsideTux</tabstop>
|
||||
<tabstop>radioButton_flipsideOwn</tabstop>
|
||||
<tabstop>lineEdit_OwnFlipsideFilename</tabstop>
|
||||
<tabstop>pushButton_openFlipsidePicture</tabstop>
|
||||
<tabstop>spinBox_quantityPlayers</tabstop>
|
||||
<tabstop>spinBox_startCash</tabstop>
|
||||
<tabstop>spinBox_smallBlind</tabstop>
|
||||
<tabstop>spinBox_handsBeforeRaiseSmallBlind</tabstop>
|
||||
<tabstop>spinBox_gameSpeed</tabstop>
|
||||
<tabstop>comboBox_engineVersion</tabstop>
|
||||
<tabstop>checkBox_pauseBetweenHands</tabstop>
|
||||
<tabstop>checkBox_showGameSettingsDialogOnNewGame</tabstop>
|
||||
<tabstop>spinBox_netQuantityPlayers</tabstop>
|
||||
<tabstop>spinBox_netStartCash</tabstop>
|
||||
<tabstop>spinBox_netSmallBlind</tabstop>
|
||||
<tabstop>spinBox_netHandsBeforeRaiseSmallBlind</tabstop>
|
||||
<tabstop>spinBox_netGameSpeed</tabstop>
|
||||
<tabstop>comboBox_netEngineVersion</tabstop>
|
||||
<tabstop>spinBox_serverPort</tabstop>
|
||||
<tabstop>lineEdit_serverPassword</tabstop>
|
||||
<tabstop>checkBox_useIpv6</tabstop>
|
||||
<tabstop>lineEdit_humanPlayerName</tabstop>
|
||||
<tabstop>lineEdit_humanPlayerAvatar</tabstop>
|
||||
<tabstop>pushButton_openAvatarFile0</tabstop>
|
||||
<tabstop>lineEdit_Opponent1Name</tabstop>
|
||||
<tabstop>lineEdit_Opponent1Avatar</tabstop>
|
||||
<tabstop>pushButton_openAvatarFile1</tabstop>
|
||||
<tabstop>lineEdit_Opponent2Name</tabstop>
|
||||
<tabstop>lineEdit_Opponent2Avatar</tabstop>
|
||||
<tabstop>pushButton_openAvatarFile2</tabstop>
|
||||
<tabstop>lineEdit_Opponent3Name</tabstop>
|
||||
<tabstop>lineEdit_Opponent3Avatar</tabstop>
|
||||
<tabstop>pushButton_openAvatarFile3</tabstop>
|
||||
<tabstop>lineEdit_Opponent4Name</tabstop>
|
||||
<tabstop>lineEdit_Opponent4Avatar</tabstop>
|
||||
<tabstop>pushButton_openAvatarFile4</tabstop>
|
||||
<tabstop>lineEdit_Opponent5Name</tabstop>
|
||||
<tabstop>lineEdit_Opponent5Avatar</tabstop>
|
||||
<tabstop>pushButton_openAvatarFile5</tabstop>
|
||||
<tabstop>lineEdit_Opponent6Name</tabstop>
|
||||
<tabstop>lineEdit_Opponent6Avatar</tabstop>
|
||||
<tabstop>pushButton_openAvatarFile6</tabstop>
|
||||
<tabstop>lineEdit_logDir</tabstop>
|
||||
<tabstop>pushButton_openLogDir</tabstop>
|
||||
<tabstop>spinBox_logStoreDuration</tabstop>
|
||||
<tabstop>buttonBox</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
|
||||
@@ -38,20 +38,20 @@ settingsDialogImpl::settingsDialogImpl(QWidget *parent)
|
||||
ConfigFile myConfig;
|
||||
|
||||
//Player Nicks
|
||||
lineEdit_humanPlayerName->setText(QString::fromStdString(myConfig.readConfigString("MyName")));
|
||||
lineEdit_humanPlayerAvatar->setText(QString::fromStdString(myConfig.readConfigString("MyAvatar")));
|
||||
lineEdit_Opponent1Name->setText(QString::fromStdString(myConfig.readConfigString("Opponent1Name")));
|
||||
lineEdit_Opponent1Avatar->setText(QString::fromStdString(myConfig.readConfigString("Opponent1Avatar")));
|
||||
lineEdit_Opponent2Name->setText(QString::fromStdString(myConfig.readConfigString("Opponent2Name")));
|
||||
lineEdit_Opponent2Avatar->setText(QString::fromStdString(myConfig.readConfigString("Opponent2Avatar")));
|
||||
lineEdit_Opponent3Name->setText(QString::fromStdString(myConfig.readConfigString("Opponent3Name")));
|
||||
lineEdit_Opponent3Avatar->setText(QString::fromStdString(myConfig.readConfigString("Opponent3Avatar")));
|
||||
lineEdit_Opponent4Name->setText(QString::fromStdString(myConfig.readConfigString("Opponent4Name")));
|
||||
lineEdit_Opponent4Avatar->setText(QString::fromStdString(myConfig.readConfigString("Opponent4Avatar")));
|
||||
lineEdit_Opponent5Name->setText(QString::fromStdString(myConfig.readConfigString("Opponent5Name")));
|
||||
lineEdit_Opponent5Avatar->setText(QString::fromStdString(myConfig.readConfigString("Opponent5Avatar")));
|
||||
lineEdit_Opponent6Name->setText(QString::fromStdString(myConfig.readConfigString("Opponent6Name")));
|
||||
lineEdit_Opponent6Avatar->setText(QString::fromStdString(myConfig.readConfigString("Opponent6Avatar")));
|
||||
lineEdit_humanPlayerName->setText(QString::fromUtf8(myConfig.readConfigString("MyName").c_str()));
|
||||
lineEdit_humanPlayerAvatar->setText(QString::fromUtf8(myConfig.readConfigString("MyAvatar").c_str()));
|
||||
lineEdit_Opponent1Name->setText(QString::fromUtf8(myConfig.readConfigString("Opponent1Name").c_str()));
|
||||
lineEdit_Opponent1Avatar->setText(QString::fromUtf8(myConfig.readConfigString("Opponent1Avatar").c_str()));
|
||||
lineEdit_Opponent2Name->setText(QString::fromUtf8(myConfig.readConfigString("Opponent2Name").c_str()));
|
||||
lineEdit_Opponent2Avatar->setText(QString::fromUtf8(myConfig.readConfigString("Opponent2Avatar").c_str()));
|
||||
lineEdit_Opponent3Name->setText(QString::fromUtf8(myConfig.readConfigString("Opponent3Name").c_str()));
|
||||
lineEdit_Opponent3Avatar->setText(QString::fromUtf8(myConfig.readConfigString("Opponent3Avatar").c_str()));
|
||||
lineEdit_Opponent4Name->setText(QString::fromUtf8(myConfig.readConfigString("Opponent4Name").c_str()));
|
||||
lineEdit_Opponent4Avatar->setText(QString::fromUtf8(myConfig.readConfigString("Opponent4Avatar").c_str()));
|
||||
lineEdit_Opponent5Name->setText(QString::fromUtf8(myConfig.readConfigString("Opponent5Name").c_str()));
|
||||
lineEdit_Opponent5Avatar->setText(QString::fromUtf8(myConfig.readConfigString("Opponent5Avatar").c_str()));
|
||||
lineEdit_Opponent6Name->setText(QString::fromUtf8(myConfig.readConfigString("Opponent6Name").c_str()));
|
||||
lineEdit_Opponent6Avatar->setText(QString::fromUtf8(myConfig.readConfigString("Opponent6Avatar").c_str()));
|
||||
|
||||
//Local Game Settings
|
||||
spinBox_quantityPlayers->setValue(myConfig.readConfigInt("NumberOfPlayers"));
|
||||
@@ -71,7 +71,7 @@ settingsDialogImpl::settingsDialogImpl(QWidget *parent)
|
||||
spinBox_netGameSpeed->setValue(myConfig.readConfigInt("NetGameSpeed"));
|
||||
comboBox_netEngineVersion->setCurrentIndex(myConfig.readConfigInt("NetEngineVersion"));
|
||||
spinBox_serverPort->setValue(myConfig.readConfigInt("ServerPort"));
|
||||
lineEdit_serverPassword->setText(QString::fromStdString(myConfig.readConfigString("ServerPassword")));
|
||||
lineEdit_serverPassword->setText(QString::fromUtf8(myConfig.readConfigString("ServerPassword").c_str()));
|
||||
checkBox_useIpv6->setChecked(myConfig.readConfigInt("ServerUseIpv6"));
|
||||
|
||||
|
||||
@@ -88,10 +88,10 @@ settingsDialogImpl::settingsDialogImpl(QWidget *parent)
|
||||
lineEdit_OwnFlipsideFilename->setEnabled(TRUE);
|
||||
pushButton_openFlipsidePicture->setEnabled(TRUE);
|
||||
}
|
||||
lineEdit_OwnFlipsideFilename->setText(QString::fromStdString(myConfig.readConfigString("FlipsideOwnFile")));
|
||||
lineEdit_OwnFlipsideFilename->setText(QString::fromUtf8(myConfig.readConfigString("FlipsideOwnFile").c_str()));
|
||||
|
||||
//Log
|
||||
lineEdit_logDir->setText(QString::fromStdString(myConfig.readConfigString("LogDir")));
|
||||
lineEdit_logDir->setText(QString::fromUtf8(myConfig.readConfigString("LogDir").c_str()));
|
||||
spinBox_logStoreDuration->setValue(myConfig.readConfigInt("LogStoreDuration"));
|
||||
|
||||
connect( buttonBox, SIGNAL( accepted() ), this, SLOT( isAccepted() ) );
|
||||
|
||||
@@ -44,7 +44,7 @@ void startNetworkGameDialogImpl::cancel() {
|
||||
void startNetworkGameDialogImpl::addConnectedPlayer(std::string playerName) {
|
||||
|
||||
QTreeWidgetItem *item = new QTreeWidgetItem(treeWidget,0);
|
||||
item->setData(0, 0, QString::fromStdString(playerName));
|
||||
item->setData(0, 0, QString::fromUtf8(playerName.c_str()));
|
||||
}
|
||||
|
||||
void startNetworkGameDialogImpl::keyPressEvent ( QKeyEvent * event ) {
|
||||
|
||||
Reference in New Issue
Block a user