extendet error handling for game table styles. every missing field or picture will be filled up by default style.

This commit is contained in:
doitux
2010-07-09 22:45:21 +00:00
parent 3610d0eaf9
commit 68594eceb7
7 changed files with 1029 additions and 939 deletions
+8
View File
@@ -134,4 +134,12 @@ struct ServerStats
unsigned maxPlayersLoggedIn;
};
enum StyleState {
OK = 0,
OUTDATED,
FIELDS_EMPTY,
PICTURES_MISSING,
NOT_READABLE
};
#endif
Binary file not shown.

After

Width:  |  Height:  |  Size: 752 B

+1
View File
@@ -49,6 +49,7 @@
<file>text-html.png</file>
<file>text-plain.png</file>
<file>document-open-folder.png</file>
<file>emblem-important.png</file>
</qresource>
<qresource prefix="/cflags">
<file>cflags/ad.png</file>
-5
View File
@@ -571,11 +571,6 @@ p, li { white-space: pre-wrap; }
<string>Maintainer</string>
</property>
</column>
<column>
<property name="text">
<string>State</string>
</property>
</column>
</widget>
</item>
</layout>
@@ -255,6 +255,9 @@ void settingsDialogImpl::exec() {
defaultTableItem->setData(0, 15, QString::fromUtf8(myConfig->readConfigString("AppDataDir").c_str())+"gfx/gui/table/default/defaulttablestyle.xml");
defaultTableItem->setData(0, 16, POKERTH_DISTRIBUTED_STYLE);
defaultTableItem->setData(0, Qt::ToolTipRole, QString::fromUtf8(myConfig->readConfigString("AppDataDir").c_str())+"gfx/gui/table/default/defaulttablestyle.xml");
defaultTableItem->setData(2, Qt::ToolTipRole, defaultTableStyle.getMyStateToolTipInfo());
if(defaultTableStyle.getState()) defaultTableItem->setIcon(2, QIcon(":/gfx/emblem-important.png"));
else defaultTableItem->setIcon(2, QIcon(":/gfx/dialog_ok_apply.png"));
}
//add danuxi table
GameTableStyleReader danuxi1TableStyle(myConfig, this);
@@ -266,6 +269,9 @@ void settingsDialogImpl::exec() {
danuxi1TableItem->setData(0, 15, QString::fromUtf8(myConfig->readConfigString("AppDataDir").c_str())+"gfx/gui/table/danuxi1/danuxi1tablestyle.xml");
danuxi1TableItem->setData(0, 16, POKERTH_DISTRIBUTED_STYLE);
danuxi1TableItem->setData(0, Qt::ToolTipRole, QString::fromUtf8(myConfig->readConfigString("AppDataDir").c_str())+"gfx/gui/table/danuxi1/danuxi1tablestyle.xml");
danuxi1TableItem->setData(2, Qt::ToolTipRole, danuxi1TableStyle.getMyStateToolTipInfo());
if(danuxi1TableStyle.getState()) danuxi1TableItem->setIcon(2, QIcon(":/gfx/emblem-important.png"));
else danuxi1TableItem->setIcon(2, QIcon(":/gfx/dialog_ok_apply.png"));
}
//load secondary styles into list (if fallback no entry)
@@ -281,6 +287,9 @@ void settingsDialogImpl::exec() {
nextItem->setData(0, 15,QString::fromUtf8(it1->c_str()));
nextItem->setData(0, 16, ADDITIONAL_STYLE);
nextItem->setData(0, Qt::ToolTipRole,QString::fromUtf8(it1->c_str()));
nextItem->setData(2, Qt::ToolTipRole, nextStyle.getMyStateToolTipInfo());
if(nextStyle.getState()) nextItem->setIcon(2, QIcon(":/gfx/emblem-important.png"));
else nextItem->setIcon(2, QIcon(":/gfx/dialog_ok_apply.png"));
treeWidget_gameTableStyles->addTopLevelItem(nextItem);
}
}
@@ -1052,6 +1061,9 @@ void settingsDialogImpl::addGameTableStyle()
newItem->setData(0, 15,fileName);
newItem->setData(0, 16, ADDITIONAL_STYLE);
newItem->setData(0, Qt::ToolTipRole,fileName);
newItem->setData(2, Qt::ToolTipRole, newStyle.getMyStateToolTipInfo());
if(newStyle.getState()) newItem->setIcon(2, QIcon(":/gfx/emblem-important.png"));
else newItem->setIcon(2, QIcon(":/gfx/dialog-ok-apply.png"));
treeWidget_gameTableStyles->addTopLevelItem(newItem);
treeWidget_gameTableStyles->setCurrentItem(newItem);
treeWidget_gameTableStyles->sortItems(0, Qt::AscendingOrder);
+262 -196
View File
@@ -44,19 +44,19 @@ GameTableStyleReader::GameTableStyleReader(ConfigFile *c, QWidget *w) : myConfig
tabBarPaddingTop = "2";
tabBarPaddingSide = "10";
#else
#ifdef __APPLE__
#ifdef __APPLE__
font1String = "font-family: \"Lucida Grande\";";
font2String = "font-family: \"Lucida Grande\";";
tabBarPaddingTop = "1";
tabBarPaddingSide = "9";
#else
#else
font1String = "font-family: \"Nimbus Sans L\";";
font2String = "font-family: \"Bitstream Vera Sans\";";
tabBarPaddingTop = "0";
tabBarPaddingSide = "9";
#endif
#endif
textBrowserFontsize= "10";
cashFontSize = "10";
setLabelFontSize = "10";
@@ -249,7 +249,7 @@ void GameTableStyleReader::readStyleFile(QString file) {
}
}
//check if style items are left and if pictures where not found and show warning
//check if style items are left and if pictures where not found
leftItems.clear();
itemPicsLeft.clear();
@@ -260,240 +260,242 @@ void GameTableStyleReader::readStyleFile(QString file) {
if(StyleCreateDate == "") { leftItems << "StyleCreateDate"; }
if(PokerTHStyleFileVersion == "") { leftItems << "PokerTHStyleFileVersion"; }
// WINDOWS SETTINGS
if(IfFixedWindowSize == "") { leftItems << "IfFixedWindowSize"; }
if(FixedWindowWidth == "") { leftItems << "FixedWindowWidth"; }
if(FixedWindowHeight == "") { leftItems << "FixedWindowHeight"; }
if(MinimumWindowWidth == "") { leftItems << "MinimumWindowWidth"; }
if(MinimumWindowHeight == "") { leftItems << "MinimumWindowHeight"; }
if(MaximumWindowWidth == "") { leftItems << "MaximumWindowWidth"; }
if(MaximumWindowHeight == "") { leftItems << "MaximumWindowHeight"; }
// PICS
if(ActionAllInI18NPic == "") { leftItems << "ActionAllInI18NPic"; }
else if(ActionAllInI18NPic != QString(currentDir+"NULL") && !QFile(ActionAllInI18NPic).exists()) { itemPicsLeft << "ActionAllInI18NPic = "+ActionAllInI18NPic; }
if(IfFixedWindowSize == "") { IfFixedWindowSize = getFallBackFieldContent("IfFixedWindowSize", 0); leftItems << "IfFixedWindowSize"; }
if(FixedWindowWidth == "") { FixedWindowWidth = getFallBackFieldContent("FixedWindowWidth", 0); leftItems << "FixedWindowWidth"; }
if(FixedWindowHeight == "") { FixedWindowHeight = getFallBackFieldContent("FixedWindowHeight", 0); leftItems << "FixedWindowHeight"; }
if(MinimumWindowWidth == "") { MinimumWindowWidth = getFallBackFieldContent("MinimumWindowWidth", 0); leftItems << "MinimumWindowWidth"; }
if(MinimumWindowHeight == "") { MinimumWindowHeight = getFallBackFieldContent("MinimumWindowHeight", 0); leftItems << "MinimumWindowHeight"; }
if(MaximumWindowWidth == "") { MaximumWindowWidth = getFallBackFieldContent("MaximumWindowWidth", 0); leftItems << "MaximumWindowWidth"; }
if(MaximumWindowHeight == "") { MaximumWindowHeight = getFallBackFieldContent("MaximumWindowHeight", 0); leftItems << "MaximumWindowHeight"; }
// P I C S
if(ActionRaiseI18NPic == "") { leftItems << "ActionRaiseI18NPic"; }
else if(ActionRaiseI18NPic != QString(currentDir+"NULL") && !QFile(ActionRaiseI18NPic).exists()) { itemPicsLeft << "ActionRaiseI18NPic = "+ActionRaiseI18NPic; }
// I18N Pics
if(ActionAllInI18NPic == "") { ActionAllInI18NPic = "NULL"; leftItems << "ActionAllInI18NPic"; }
else if(ActionAllInI18NPic != QString(currentDir+"NULL") && !QFile(ActionAllInI18NPic).exists()) { ActionAllInI18NPic = "NULL"; itemPicsLeft << "ActionAllInI18NPic = "+ActionAllInI18NPic; }
if(ActionBetI18NPic == "") { leftItems << "ActionBetI18NPic"; }
else if(ActionBetI18NPic != QString(currentDir+"NULL") && !QFile(ActionBetI18NPic).exists()) { itemPicsLeft << "ActionBetI18NPic = "+ActionBetI18NPic; }
if(ActionRaiseI18NPic == "") { ActionRaiseI18NPic = "NULL"; leftItems << "ActionRaiseI18NPic"; }
else if(ActionRaiseI18NPic != QString(currentDir+"NULL") && !QFile(ActionRaiseI18NPic).exists()) { ActionRaiseI18NPic = "NULL"; itemPicsLeft << "ActionRaiseI18NPic = "+ActionRaiseI18NPic; }
if(ActionCallI18NPic == "") { leftItems << "ActionCallI18NPic"; }
else if(ActionCallI18NPic != QString(currentDir+"NULL") && !QFile(ActionCallI18NPic).exists()) { itemPicsLeft << "ActionCallI18NPic = "+ActionCallI18NPic; }
if(ActionBetI18NPic == "") { ActionBetI18NPic = "NULL"; leftItems << "ActionBetI18NPic"; }
else if(ActionBetI18NPic != QString(currentDir+"NULL") && !QFile(ActionBetI18NPic).exists()) { ActionBetI18NPic = "NULL"; itemPicsLeft << "ActionBetI18NPic = "+ActionBetI18NPic; }
if(ActionCheckI18NPic == "") { leftItems << "ActionCheckI18NPic"; }
else if(ActionCheckI18NPic != QString(currentDir+"NULL") && !QFile(ActionCheckI18NPic).exists()) { itemPicsLeft << "ActionCheckI18NPic = "+ActionCheckI18NPic; }
if(ActionCallI18NPic == "") { ActionCallI18NPic = "NULL"; leftItems << "ActionCallI18NPic"; }
else if(ActionCallI18NPic != QString(currentDir+"NULL") && !QFile(ActionCallI18NPic).exists()) { ActionCallI18NPic = "NULL"; itemPicsLeft << "ActionCallI18NPic = "+ActionCallI18NPic; }
if(ActionFoldI18NPic == "") { leftItems << "ActionFoldI18NPic"; }
else if(ActionFoldI18NPic != QString(currentDir+"NULL") && !QFile(ActionFoldI18NPic).exists()) { itemPicsLeft << "ActionFoldI18NPic = "+ActionFoldI18NPic; }
if(ActionCheckI18NPic == "") { ActionCheckI18NPic = "NULL"; leftItems << "ActionCheckI18NPic"; }
else if(ActionCheckI18NPic != QString(currentDir+"NULL") && !QFile(ActionCheckI18NPic).exists()) { ActionCheckI18NPic = "NULL"; itemPicsLeft << "ActionCheckI18NPic = "+ActionCheckI18NPic; }
if(ActionWinnerI18NPic == "") { leftItems << "ActionWinnerI18NPic"; }
else if(ActionWinnerI18NPic != QString(currentDir+"NULL") && !QFile(ActionWinnerI18NPic).exists()) { itemPicsLeft << "ActionWinnerI18NPic = "+ActionWinnerI18NPic; }
if(ActionFoldI18NPic == "") { ActionFoldI18NPic = "NULL"; leftItems << "ActionFoldI18NPic"; }
else if(ActionFoldI18NPic != QString(currentDir+"NULL") && !QFile(ActionFoldI18NPic).exists()) { ActionFoldI18NPic = "NULL"; itemPicsLeft << "ActionFoldI18NPic = "+ActionFoldI18NPic; }
if(BigBlindPuck == "") { leftItems << "BigBlindPuck"; }
else if(BigBlindPuck != QString(currentDir+"NULL") && !QFile(BigBlindPuck).exists()) { itemPicsLeft << "BigBlindPuck = "+BigBlindPuck; }
if(ActionWinnerI18NPic == "") { ActionWinnerI18NPic = "NULL"; leftItems << "ActionWinnerI18NPic"; }
else if(ActionWinnerI18NPic != QString(currentDir+"NULL") && !QFile(ActionWinnerI18NPic).exists()) { ActionWinnerI18NPic = "NULL"; itemPicsLeft << "ActionWinnerI18NPic = "+ActionWinnerI18NPic; }
if(SmallBlindPuck == "") { leftItems << "SmallBlindPuck"; }
else if(SmallBlindPuck != QString(currentDir+"NULL") && !QFile(SmallBlindPuck).exists()) { itemPicsLeft << "SmallBlindPuck = "+SmallBlindPuck; }
if(DealerPuck == "") { leftItems << "DealerPuck"; }
else if(DealerPuck != QString(currentDir+"NULL") && !QFile(DealerPuck).exists()) { itemPicsLeft << "DealerPuck = "+DealerPuck; }
// Other Pics
if(BigBlindPuck == "") { BigBlindPuck = getFallBackFieldContent("BigBlindPuck", 1); leftItems << "BigBlindPuck"; }
else if(BigBlindPuck != QString(currentDir+"NULL") && !QFile(BigBlindPuck).exists()) { BigBlindPuck = getFallBackFieldContent("BigBlindPuck", 1); itemPicsLeft << "BigBlindPuck = "+BigBlindPuck; }
if(DefaultAvatar == "") { leftItems << "DefaultAvatar"; }
else if(DefaultAvatar != QString(currentDir+"NULL") && !QFile(DefaultAvatar).exists()) { itemPicsLeft << "DefaultAvatar = "+DefaultAvatar; }
if(SmallBlindPuck == "") { SmallBlindPuck = getFallBackFieldContent("SmallBlindPuck", 1); leftItems << "SmallBlindPuck"; }
else if(SmallBlindPuck != QString(currentDir+"NULL") && !QFile(SmallBlindPuck).exists()) { SmallBlindPuck = getFallBackFieldContent("SmallBlindPuck", 1); itemPicsLeft << "SmallBlindPuck = "+SmallBlindPuck; }
if(CardHolderFlop == "") { leftItems << "CardHolderFlop"; }
else if(CardHolderFlop != QString(currentDir+"NULL") && !QFile(CardHolderFlop).exists()) { itemPicsLeft << "CardHolderFlop = "+CardHolderFlop; }
if(DealerPuck == "") { DealerPuck = getFallBackFieldContent("DealerPuck", 1); leftItems << "DealerPuck"; }
else if(DealerPuck != QString(currentDir+"NULL") && !QFile(DealerPuck).exists()) { DealerPuck = getFallBackFieldContent("DealerPuck", 1); itemPicsLeft << "DealerPuck = "+DealerPuck; }
if(CardHolderTurn == "") { leftItems << "CardHolderTurn"; }
else if(CardHolderTurn != QString(currentDir+"NULL") && !QFile(CardHolderTurn).exists()) { itemPicsLeft << "CardHolderTurn = "+CardHolderTurn; }
if(DefaultAvatar == "") { DefaultAvatar = getFallBackFieldContent("DefaultAvatar", 1); leftItems << "DefaultAvatar"; }
else if(DefaultAvatar != QString(currentDir+"NULL") && !QFile(DefaultAvatar).exists()) { DefaultAvatar = getFallBackFieldContent("DefaultAvatar", 1); itemPicsLeft << "DefaultAvatar = "+DefaultAvatar; }
if(CardHolderRiver == "") { leftItems << "CardHolderRiver"; }
else if(CardHolderRiver != QString(currentDir+"NULL") && !QFile(CardHolderRiver).exists()) { itemPicsLeft << "CardHolderRiver = "+CardHolderRiver; }
if(CardHolderFlop == "") { CardHolderFlop = getFallBackFieldContent("CardHolderFlop", 1); leftItems << "CardHolderFlop"; }
else if(CardHolderFlop != QString(currentDir+"NULL") && !QFile(CardHolderFlop).exists()) { CardHolderFlop = getFallBackFieldContent("CardHolderFlop", 1); itemPicsLeft << "CardHolderFlop = "+CardHolderFlop; }
if(FoldButtonDefault == "") { leftItems << "FoldButtonDefault"; }
else if(FoldButtonDefault != QString(currentDir+"NULL") && !QFile(FoldButtonDefault).exists()) { itemPicsLeft << "FoldButtonDefault = "+FoldButtonDefault; }
if(CardHolderTurn == "") { CardHolderTurn = getFallBackFieldContent("CardHolderTurn", 1); leftItems << "CardHolderTurn"; }
else if(CardHolderTurn != QString(currentDir+"NULL") && !QFile(CardHolderTurn).exists()) { CardHolderTurn = getFallBackFieldContent("CardHolderTurn", 1); itemPicsLeft << "CardHolderTurn = "+CardHolderTurn; }
if(FoldButtonHover == "") { leftItems << "FoldButtonHover"; }
else if(FoldButtonHover != QString(currentDir+"NULL") && !QFile(FoldButtonHover).exists()) { itemPicsLeft << "FoldButtonHover = "+FoldButtonHover; }
if(CardHolderRiver == "") { CardHolderRiver = getFallBackFieldContent("CardHolderRiver", 1); leftItems << "CardHolderRiver"; }
else if(CardHolderRiver != QString(currentDir+"NULL") && !QFile(CardHolderRiver).exists()) { CardHolderRiver = getFallBackFieldContent("CardHolderRiver", 1); itemPicsLeft << "CardHolderRiver = "+CardHolderRiver; }
if(FoldButtonChecked == "") { leftItems << "FoldButtonChecked"; }
else if(FoldButtonChecked != QString(currentDir+"NULL") && !QFile(FoldButtonChecked).exists()) { itemPicsLeft << "FoldButtonChecked = "+FoldButtonChecked; }
if(FoldButtonDefault == "") { FoldButtonDefault = getFallBackFieldContent("FoldButtonDefault", 1); leftItems << "FoldButtonDefault"; }
else if(FoldButtonDefault != QString(currentDir+"NULL") && !QFile(FoldButtonDefault).exists()) { FoldButtonDefault = getFallBackFieldContent("FoldButtonDefault", 1); itemPicsLeft << "FoldButtonDefault = "+FoldButtonDefault; }
if(FoldButtonCheckedHover == "") { leftItems << "FoldButtonCheckedHover"; }
else if(FoldButtonCheckedHover != QString(currentDir+"NULL") && !QFile(FoldButtonCheckedHover).exists()) { itemPicsLeft << "FoldButtonCheckedHover = "+FoldButtonCheckedHover; }
if(FoldButtonHover == "") { FoldButtonHover = getFallBackFieldContent("FoldButtonHover", 1); leftItems << "FoldButtonHover"; }
else if(FoldButtonHover != QString(currentDir+"NULL") && !QFile(FoldButtonHover).exists()) { FoldButtonHover = getFallBackFieldContent("FoldButtonHover", 1); itemPicsLeft << "FoldButtonHover = "+FoldButtonHover; }
if(CheckCallButtonDefault == "") { leftItems << "CheckCallButtonDefault"; }
else if(CheckCallButtonDefault != QString(currentDir+"NULL") && !QFile(CheckCallButtonDefault).exists()) { itemPicsLeft << "CheckCallButtonDefault = "+CheckCallButtonDefault; }
if(FoldButtonChecked == "") { FoldButtonChecked = getFallBackFieldContent("FoldButtonChecked", 1); leftItems << "FoldButtonChecked"; }
else if(FoldButtonChecked != QString(currentDir+"NULL") && !QFile(FoldButtonChecked).exists()) { FoldButtonChecked = getFallBackFieldContent("FoldButtonChecked", 1); itemPicsLeft << "FoldButtonChecked = "+FoldButtonChecked; }
if(CheckCallButtonHover == "") { leftItems << "CheckCallButtonHover"; }
else if(CheckCallButtonHover != QString(currentDir+"NULL") && !QFile(CheckCallButtonHover).exists()) { itemPicsLeft << "CheckCallButtonHover = "+CheckCallButtonHover; }
if(FoldButtonCheckedHover == "") { FoldButtonCheckedHover = getFallBackFieldContent("FoldButtonCheckedHover", 1); leftItems << "FoldButtonCheckedHover"; }
else if(FoldButtonCheckedHover != QString(currentDir+"NULL") && !QFile(FoldButtonCheckedHover).exists()) { FoldButtonCheckedHover = getFallBackFieldContent("FoldButtonCheckedHover", 1); itemPicsLeft << "FoldButtonCheckedHover = "+FoldButtonCheckedHover; }
if(CheckCallButtonChecked == "") { leftItems << "CheckCallButtonChecked"; }
else if(CheckCallButtonChecked != QString(currentDir+"NULL") && !QFile(CheckCallButtonChecked).exists()) { itemPicsLeft << "CheckCallButtonChecked = "+CheckCallButtonChecked; }
if(CheckCallButtonDefault == "") { CheckCallButtonDefault = getFallBackFieldContent("CheckCallButtonDefault", 1); leftItems << "CheckCallButtonDefault"; }
else if(CheckCallButtonDefault != QString(currentDir+"NULL") && !QFile(CheckCallButtonDefault).exists()) { CheckCallButtonDefault = getFallBackFieldContent("CheckCallButtonDefault", 1); itemPicsLeft << "CheckCallButtonDefault = "+CheckCallButtonDefault; }
if(CheckCallButtonCheckedHover == "") { leftItems << "CheckCallButtonCheckedHover"; }
else if(CheckCallButtonCheckedHover != QString(currentDir+"NULL") && !QFile(CheckCallButtonCheckedHover).exists()) { itemPicsLeft << "CheckCallButtonCheckedHover = "+CheckCallButtonCheckedHover; }
if(CheckCallButtonHover == "") { CheckCallButtonHover = getFallBackFieldContent("CheckCallButtonHover", 1); leftItems << "CheckCallButtonHover"; }
else if(CheckCallButtonHover != QString(currentDir+"NULL") && !QFile(CheckCallButtonHover).exists()) { CheckCallButtonHover = getFallBackFieldContent("CheckCallButtonHover", 1); itemPicsLeft << "CheckCallButtonHover = "+CheckCallButtonHover; }
if(BetRaiseButtonDefault == "") { leftItems << "BetRaiseButtonDefault"; }
else if(BetRaiseButtonDefault != QString(currentDir+"NULL") && !QFile(BetRaiseButtonDefault).exists()) { itemPicsLeft << "BetRaiseButtonDefault = "+BetRaiseButtonDefault; }
if(CheckCallButtonChecked == "") { CheckCallButtonChecked = getFallBackFieldContent("CheckCallButtonChecked", 1); leftItems << "CheckCallButtonChecked"; }
else if(CheckCallButtonChecked != QString(currentDir+"NULL") && !QFile(CheckCallButtonChecked).exists()) { CheckCallButtonChecked = getFallBackFieldContent("CheckCallButtonChecked", 1); itemPicsLeft << "CheckCallButtonChecked = "+CheckCallButtonChecked; }
if(BetRaiseButtonHover == "") { leftItems << "BetRaiseButtonHover"; }
else if(BetRaiseButtonHover != QString(currentDir+"NULL") && !QFile(BetRaiseButtonHover).exists()) { itemPicsLeft << "BetRaiseButtonHover = "+BetRaiseButtonHover; }
if(CheckCallButtonCheckedHover == "") { CheckCallButtonCheckedHover = getFallBackFieldContent("CheckCallButtonCheckedHover", 1); leftItems << "CheckCallButtonCheckedHover"; }
else if(CheckCallButtonCheckedHover != QString(currentDir+"NULL") && !QFile(CheckCallButtonCheckedHover).exists()) { CheckCallButtonCheckedHover = getFallBackFieldContent("CheckCallButtonCheckedHover", 1); itemPicsLeft << "CheckCallButtonCheckedHover = "+CheckCallButtonCheckedHover; }
if(BetRaiseButtonChecked == "") { leftItems << "BetRaiseButtonChecked"; }
else if(BetRaiseButtonChecked != QString(currentDir+"NULL") && !QFile(BetRaiseButtonChecked).exists()) { itemPicsLeft << "BetRaiseButtonChecked = "+BetRaiseButtonChecked; }
if(BetRaiseButtonDefault == "") { BetRaiseButtonDefault = getFallBackFieldContent("BetRaiseButtonDefault", 1); leftItems << "BetRaiseButtonDefault"; }
else if(BetRaiseButtonDefault != QString(currentDir+"NULL") && !QFile(BetRaiseButtonDefault).exists()) { BetRaiseButtonDefault = getFallBackFieldContent("BetRaiseButtonDefault", 1); itemPicsLeft << "BetRaiseButtonDefault = "+BetRaiseButtonDefault; }
if(BetRaiseButtonCheckedHover == "") { leftItems << "BetRaiseButtonCheckedHover"; }
else if(BetRaiseButtonCheckedHover != QString(currentDir+"NULL") && !QFile(BetRaiseButtonCheckedHover).exists()) { itemPicsLeft << "BetRaiseButtonCheckedHover = "+BetRaiseButtonCheckedHover; }
if(BetRaiseButtonHover == "") { BetRaiseButtonHover = getFallBackFieldContent("BetRaiseButtonHover", 1); leftItems << "BetRaiseButtonHover"; }
else if(BetRaiseButtonHover != QString(currentDir+"NULL") && !QFile(BetRaiseButtonHover).exists()) { BetRaiseButtonHover = getFallBackFieldContent("BetRaiseButtonHover", 1); itemPicsLeft << "BetRaiseButtonHover = "+BetRaiseButtonHover; }
if(AllInButtonDefault == "") { leftItems << "AllInButtonDefault"; }
else if(AllInButtonDefault != QString(currentDir+"NULL") && !QFile(AllInButtonDefault).exists()) { itemPicsLeft << "AllInButtonDefault = "+AllInButtonDefault; }
if(BetRaiseButtonChecked == "") { BetRaiseButtonChecked = getFallBackFieldContent("BetRaiseButtonChecked", 1); leftItems << "BetRaiseButtonChecked"; }
else if(BetRaiseButtonChecked != QString(currentDir+"NULL") && !QFile(BetRaiseButtonChecked).exists()) { BetRaiseButtonChecked = getFallBackFieldContent("BetRaiseButtonChecked", 1); itemPicsLeft << "BetRaiseButtonChecked = "+BetRaiseButtonChecked; }
if(AllInButtonHover == "") { leftItems << "AllInButtonHover"; }
else if(AllInButtonHover != QString(currentDir+"NULL") && !QFile(AllInButtonHover).exists()) { itemPicsLeft << "AllInButtonHover = "+AllInButtonHover; }
if(BetRaiseButtonCheckedHover == "") { BetRaiseButtonCheckedHover = getFallBackFieldContent("BetRaiseButtonCheckedHover", 1); leftItems << "BetRaiseButtonCheckedHover"; }
else if(BetRaiseButtonCheckedHover != QString(currentDir+"NULL") && !QFile(BetRaiseButtonCheckedHover).exists()) { BetRaiseButtonCheckedHover = getFallBackFieldContent("BetRaiseButtonCheckedHover", 1); itemPicsLeft << "BetRaiseButtonCheckedHover = "+BetRaiseButtonCheckedHover; }
if(AllInButtonChecked == "") { leftItems << "AllInButtonChecked"; }
else if(AllInButtonChecked != QString(currentDir+"NULL") && !QFile(AllInButtonChecked).exists()) { itemPicsLeft << "AllInButtonChecked = "+AllInButtonChecked; }
if(AllInButtonDefault == "") { AllInButtonDefault = getFallBackFieldContent("AllInButtonDefault", 1); leftItems << "AllInButtonDefault"; }
else if(AllInButtonDefault != QString(currentDir+"NULL") && !QFile(AllInButtonDefault).exists()) { AllInButtonDefault = getFallBackFieldContent("AllInButtonDefault", 1); itemPicsLeft << "AllInButtonDefault = "+AllInButtonDefault; }
if(AllInButtonCheckedHover == "") { leftItems << "AllInButtonCheckedHover"; }
else if(AllInButtonCheckedHover != QString(currentDir+"NULL") && !QFile(AllInButtonCheckedHover).exists()) { itemPicsLeft << "AllInButtonCheckedHover = "+AllInButtonCheckedHover; }
if(AllInButtonHover == "") { AllInButtonHover = getFallBackFieldContent("AllInButtonHover", 1); leftItems << "AllInButtonHover"; }
else if(AllInButtonHover != QString(currentDir+"NULL") && !QFile(AllInButtonHover).exists()) { AllInButtonHover = getFallBackFieldContent("AllInButtonHover", 1); itemPicsLeft << "AllInButtonHover = "+AllInButtonHover; }
if(RadioButtonPressed == "") { leftItems << "RadioButtonPressed"; }
else if(RadioButtonPressed != QString(currentDir+"NULL") && !QFile(RadioButtonPressed).exists()) { itemPicsLeft << "RadioButtonPressed = "+RadioButtonPressed; }
if(AllInButtonChecked == "") { AllInButtonChecked = getFallBackFieldContent("AllInButtonChecked", 1); leftItems << "AllInButtonChecked"; }
else if(AllInButtonChecked != QString(currentDir+"NULL") && !QFile(AllInButtonChecked).exists()) { AllInButtonChecked = getFallBackFieldContent("AllInButtonChecked", 1); itemPicsLeft << "AllInButtonChecked = "+AllInButtonChecked; }
if(RadioButtonChecked == "") { leftItems << "RadioButtonChecked"; }
else if(RadioButtonChecked != QString(currentDir+"NULL") && !QFile(RadioButtonChecked).exists()) { itemPicsLeft << "RadioButtonChecked = "+RadioButtonChecked; }
if(AllInButtonCheckedHover == "") { AllInButtonCheckedHover = getFallBackFieldContent("AllInButtonCheckedHover", 1); leftItems << "AllInButtonCheckedHover"; }
else if(AllInButtonCheckedHover != QString(currentDir+"NULL") && !QFile(AllInButtonCheckedHover).exists()) { AllInButtonCheckedHover = getFallBackFieldContent("AllInButtonCheckedHover", 1); itemPicsLeft << "AllInButtonCheckedHover = "+AllInButtonCheckedHover; }
if(RadioButtonCheckedHover == "") { leftItems << "RadioButtonCheckedHover"; }
else if(RadioButtonCheckedHover != QString(currentDir+"NULL") && !QFile(RadioButtonCheckedHover).exists()) { itemPicsLeft << "RadioButtonCheckedHover = "+RadioButtonCheckedHover; }
if(RadioButtonPressed == "") { RadioButtonPressed = getFallBackFieldContent("RadioButtonPressed", 1); leftItems << "RadioButtonPressed"; }
else if(RadioButtonPressed != QString(currentDir+"NULL") && !QFile(RadioButtonPressed).exists()) { RadioButtonPressed = getFallBackFieldContent("RadioButtonPressed", 1); itemPicsLeft << "RadioButtonPressed = "+RadioButtonPressed; }
if(RadioButtonUnchecked == "") { leftItems << "RadioButtonUnchecked"; }
else if(RadioButtonUnchecked != QString(currentDir+"NULL") && !QFile(RadioButtonUnchecked).exists()) { itemPicsLeft << "RadioButtonUnchecked = "+RadioButtonUnchecked; }
if(RadioButtonChecked == "") { RadioButtonChecked = getFallBackFieldContent("RadioButtonChecked", 1); leftItems << "RadioButtonChecked"; }
else if(RadioButtonChecked != QString(currentDir+"NULL") && !QFile(RadioButtonChecked).exists()) { RadioButtonChecked = getFallBackFieldContent("RadioButtonChecked", 1); itemPicsLeft << "RadioButtonChecked = "+RadioButtonChecked; }
if(RadioButtonUncheckedHover == "") { leftItems << "RadioButtonUncheckedHover"; }
else if(RadioButtonUncheckedHover != QString(currentDir+"NULL") && !QFile(RadioButtonUncheckedHover).exists()) { itemPicsLeft << "RadioButtonUncheckedHover = "+RadioButtonUncheckedHover; }
if(RadioButtonCheckedHover == "") { RadioButtonCheckedHover = getFallBackFieldContent("RadioButtonCheckedHover", 1); leftItems << "RadioButtonCheckedHover"; }
else if(RadioButtonCheckedHover != QString(currentDir+"NULL") && !QFile(RadioButtonCheckedHover).exists()) { RadioButtonCheckedHover = getFallBackFieldContent("RadioButtonCheckedHover", 1); itemPicsLeft << "RadioButtonCheckedHover = "+RadioButtonCheckedHover; }
if(PlayerTopSeatActive == "") { leftItems << "PlayerTopSeatActive"; }
else if(PlayerTopSeatActive != QString(currentDir+"NULL") && !QFile(PlayerTopSeatActive).exists()) { itemPicsLeft << "PlayerTopSeatActive = "+PlayerTopSeatActive; }
if(RadioButtonUnchecked == "") { RadioButtonUnchecked = getFallBackFieldContent("RadioButtonUnchecked", 1); leftItems << "RadioButtonUnchecked"; }
else if(RadioButtonUnchecked != QString(currentDir+"NULL") && !QFile(RadioButtonUnchecked).exists()) { RadioButtonUnchecked = getFallBackFieldContent("RadioButtonUnchecked", 1); itemPicsLeft << "RadioButtonUnchecked = "+RadioButtonUnchecked; }
if(PlayerTopSeatInactive == "") { leftItems << "PlayerTopSeatInactive"; }
else if(PlayerTopSeatInactive != QString(currentDir+"NULL") && !QFile(PlayerTopSeatInactive).exists()) { itemPicsLeft << "PlayerTopSeatInactive = "+PlayerTopSeatInactive; }
if(RadioButtonUncheckedHover == "") { RadioButtonUncheckedHover = getFallBackFieldContent("RadioButtonUncheckedHover", 1); leftItems << "RadioButtonUncheckedHover"; }
else if(RadioButtonUncheckedHover != QString(currentDir+"NULL") && !QFile(RadioButtonUncheckedHover).exists()) { RadioButtonUncheckedHover = getFallBackFieldContent("RadioButtonUncheckedHover", 1); itemPicsLeft << "RadioButtonUncheckedHover = "+RadioButtonUncheckedHover; }
if(PlayerBottomSeatActive == "") { leftItems << "PlayerBottomSeatActive"; }
else if(PlayerBottomSeatActive != QString(currentDir+"NULL") && !QFile(PlayerBottomSeatActive).exists()) { itemPicsLeft << "PlayerBottomSeatActive = "+PlayerBottomSeatActive; }
if(PlayerTopSeatActive == "") { PlayerTopSeatActive = getFallBackFieldContent("PlayerTopSeatActive", 1); leftItems << "PlayerTopSeatActive"; }
else if(PlayerTopSeatActive != QString(currentDir+"NULL") && !QFile(PlayerTopSeatActive).exists()) { PlayerTopSeatActive = getFallBackFieldContent("PlayerTopSeatActive", 1); itemPicsLeft << "PlayerTopSeatActive = "+PlayerTopSeatActive; }
if(PlayerBottomSeatInactive == "") { leftItems << "PlayerBottomSeatInactive"; }
else if(PlayerBottomSeatInactive != QString(currentDir+"NULL") && !QFile(PlayerBottomSeatInactive).exists()) { itemPicsLeft << "PlayerBottomSeatInactive = "+PlayerBottomSeatInactive; }
if(PlayerTopSeatInactive == "") { PlayerTopSeatInactive = getFallBackFieldContent("PlayerTopSeatInactive", 1); leftItems << "PlayerTopSeatInactive"; }
else if(PlayerTopSeatInactive != QString(currentDir+"NULL") && !QFile(PlayerTopSeatInactive).exists()) { PlayerTopSeatInactive = getFallBackFieldContent("PlayerTopSeatInactive", 1); itemPicsLeft << "PlayerTopSeatInactive = "+PlayerTopSeatInactive; }
if(Table == "") { leftItems << "Table"; }
else if(Table != QString(currentDir+"NULL") && !QFile(Table).exists()) { itemPicsLeft << "Table = "+Table; }
if(PlayerBottomSeatActive == "") { PlayerBottomSeatActive = getFallBackFieldContent("PlayerBottomSeatActive", 1); leftItems << "PlayerBottomSeatActive"; }
else if(PlayerBottomSeatActive != QString(currentDir+"NULL") && !QFile(PlayerBottomSeatActive).exists()) { PlayerBottomSeatActive = getFallBackFieldContent("PlayerBottomSeatActive", 1); itemPicsLeft << "PlayerBottomSeatActive = "+PlayerBottomSeatActive; }
if(HandRanking == "") { leftItems << "HandRanking"; }
else if(HandRanking != QString(currentDir+"NULL") && !QFile(HandRanking).exists()) { itemPicsLeft << "HandRanking = "+HandRanking; }
if(PlayerBottomSeatInactive == "") { PlayerBottomSeatInactive = getFallBackFieldContent("PlayerBottomSeatInactive", 1); leftItems << "PlayerBottomSeatInactive"; }
else if(PlayerBottomSeatInactive != QString(currentDir+"NULL") && !QFile(PlayerBottomSeatInactive).exists()) { PlayerBottomSeatInactive = getFallBackFieldContent("PlayerBottomSeatInactive", 1); itemPicsLeft << "PlayerBottomSeatInactive = "+PlayerBottomSeatInactive; }
if(ToolBoxBackground == "") { leftItems << "ToolBoxBackground"; }
else if(ToolBoxBackground != QString(currentDir+"NULL") && !QFile(ToolBoxBackground).exists()) { itemPicsLeft << "ToolBoxBackground = "+ToolBoxBackground; }
if(Table == "") { Table = getFallBackFieldContent("Table", 1); leftItems << "Table"; }
else if(Table != QString(currentDir+"NULL") && !QFile(Table).exists()) { Table = getFallBackFieldContent("Table", 1); itemPicsLeft << "Table = "+Table; }
if(ShowMyCardsButtonDefault == "") { leftItems << "ShowMyCardsButtonDefault"; }
else if(ShowMyCardsButtonDefault != QString(currentDir+"NULL") && !QFile(ShowMyCardsButtonDefault).exists()) { itemPicsLeft << "ShowMyCardsButtonDefault = "+ShowMyCardsButtonDefault; }
if(HandRanking == "") { HandRanking = getFallBackFieldContent("HandRanking", 1); leftItems << "HandRanking"; }
else if(HandRanking != QString(currentDir+"NULL") && !QFile(HandRanking).exists()) { HandRanking = getFallBackFieldContent("HandRanking", 1); itemPicsLeft << "HandRanking = "+HandRanking; }
if(ShowMyCardsButtonHover == "") { leftItems << "ShowMyCardsButtonHover"; }
else if(ShowMyCardsButtonHover != QString(currentDir+"NULL") && !QFile(ShowMyCardsButtonHover).exists()) { itemPicsLeft << "ShowMyCardsButtonHover = "+ShowMyCardsButtonHover; }
if(ToolBoxBackground == "") { ToolBoxBackground = getFallBackFieldContent("ToolBoxBackground", 1); leftItems << "ToolBoxBackground"; }
else if(ToolBoxBackground != QString(currentDir+"NULL") && !QFile(ToolBoxBackground).exists()) { ToolBoxBackground = getFallBackFieldContent("ToolBoxBackground", 1); itemPicsLeft << "ToolBoxBackground = "+ToolBoxBackground; }
if(ShowMyCardsButtonDefault == "") { ShowMyCardsButtonDefault = getFallBackFieldContent("ShowMyCardsButtonDefault", 1); leftItems << "ShowMyCardsButtonDefault"; }
else if(ShowMyCardsButtonDefault != QString(currentDir+"NULL") && !QFile(ShowMyCardsButtonDefault).exists()) { ShowMyCardsButtonDefault = getFallBackFieldContent("ShowMyCardsButtonDefault", 1); itemPicsLeft << "ShowMyCardsButtonDefault = "+ShowMyCardsButtonDefault; }
if(ShowMyCardsButtonHover == "") { ShowMyCardsButtonHover = getFallBackFieldContent("ShowMyCardsButtonHover", 1); leftItems << "ShowMyCardsButtonHover"; }
else if(ShowMyCardsButtonHover != QString(currentDir+"NULL") && !QFile(ShowMyCardsButtonHover).exists()) { ShowMyCardsButtonHover = getFallBackFieldContent("ShowMyCardsButtonHover", 1); itemPicsLeft << "ShowMyCardsButtonHover = "+ShowMyCardsButtonHover; }
//I18N ACTION STRINGS
if(ActionAllInI18NString == "") { leftItems << "ActionAllInI18NString"; }
if(ActionRaiseI18NString == "") { leftItems << "ActionRaiseI18NString"; }
if(ActionBetI18NString == "") { leftItems << "ActionBetI18NString"; }
if(ActionCallI18NString == "") { leftItems << "ActionCallI18NString"; }
if(ActionCheckI18NString == "") { leftItems << "ActionCheckI18NString"; }
if(ActionFoldI18NString == "") { leftItems << "ActionFoldI18NString"; }
if(PotI18NString == "") { leftItems << "PotI18NString"; }
if(TotalI18NString == "") { leftItems << "TotalI18NString"; }
if(BetsI18NString == "") { leftItems << "BetsI18NString"; }
if(GameI18NString == "") { leftItems << "GameI18NString"; }
if(HandI18NString == "") { leftItems << "HandI18NString"; }
if(PreflopI18NString == "") { leftItems << "PreflopI18NString"; }
if(FlopI18NString == "") { leftItems << "FlopI18NString"; }
if(TurnI18NString == "") { leftItems << "TurnI18NString"; }
if(RiverI18NString == "") { leftItems << "RiverI18NString"; }
if(ActionAllInI18NString == "") { ActionAllInI18NString = "NULL"; leftItems << "ActionAllInI18NString"; }
if(ActionRaiseI18NString == "") { ActionRaiseI18NString = "NULL"; leftItems << "ActionRaiseI18NString"; }
if(ActionBetI18NString == "") { ActionBetI18NString = "NULL"; leftItems << "ActionBetI18NString"; }
if(ActionCallI18NString == "") { ActionCallI18NString = "NULL"; leftItems << "ActionCallI18NString"; }
if(ActionCheckI18NString == "") { ActionCheckI18NString = "NULL"; leftItems << "ActionCheckI18NString"; }
if(ActionFoldI18NString == "") { ActionFoldI18NString = "NULL"; leftItems << "ActionFoldI18NString"; }
if(PotI18NString == "") { PotI18NString = "NULL"; leftItems << "PotI18NString"; }
if(TotalI18NString == "") { TotalI18NString = "NULL"; leftItems << "TotalI18NString"; }
if(BetsI18NString == "") { BetsI18NString = "NULL"; leftItems << "BetsI18NString"; }
if(GameI18NString == "") { GameI18NString = "NULL"; leftItems << "GameI18NString"; }
if(HandI18NString == "") { HandI18NString = "NULL"; leftItems << "HandI18NString"; }
if(PreflopI18NString == "") { PreflopI18NString = "NULL"; leftItems << "PreflopI18NString"; }
if(FlopI18NString == "") { FlopI18NString = "NULL"; leftItems << "FlopI18NString"; }
if(TurnI18NString == "") { TurnI18NString = "NULL"; leftItems << "TurnI18NString"; }
if(RiverI18NString == "") { RiverI18NString = "NULL"; leftItems << "RiverI18NString"; }
// COLORS
if(FKeyIndicatorColor == "") { leftItems << "FKeyIndicatorColor"; }
if(ChanceLabelPossibleColor == "") { leftItems << "ChanceLabelPossibleColor"; }
if(ChanceLabelImpossibleColor == "") { leftItems << "ChanceLabelImpossibleColor"; }
if(ChatLogTextColor == "") { leftItems << "ChatLogTextColor"; }
if(ChatTextNickNotifyColor == "") { leftItems << "ChatTextNickNotifyColor"; }
if(ChatLogBgColor == "") { leftItems << "ChatLogBgColor"; }
if(ChatLogScrollBarBorderColor == "") { leftItems << "ChatLogScrollBarBorderColor"; }
if(ChatLogScrollBarBgColor == "") { leftItems << "ChatLogScrollBarBgColor"; }
if(ChatLogScrollBarHandleBorderColor == "") { leftItems << "ChatLogScrollBarHandleBorderColor"; }
if(ChatLogScrollBarHandleBgColor == "") { leftItems << "ChatLogScrollBarHandleBgColor"; }
if(ChatLogScrollBarArrowBorderColor == "") { leftItems << "ChatLogScrollBarArrowBorderColor"; }
if(ChatLogScrollBarArrowBgColor == "") { leftItems << "ChatLogScrollBarArrowBgColor"; }
if(LogWinnerMainPotColor == "") { leftItems << "LogWinnerMainPotColor"; }
if(LogWinnerSidePotColor == "") { leftItems << "LogWinnerSidePotColor"; }
if(LogPlayerSitsOutColor == "") { leftItems << "LogPlayerSitsOutColor"; }
if(LogNewGameAdminColor == "") { leftItems << "LogNewGameAdminColor"; }
if(TabWidgetBorderColor == "") { leftItems << "TabWidgetBorderColor"; }
if(TabWidgetBgColor == "") { leftItems << "TabWidgetBgColor"; }
if(TabWidgetTextColor == "") { leftItems << "TabWidgetTextColor"; }
if(MenuBgColor == "") { leftItems << "MenuBgColor"; }
if(MenuTextColor == "") { leftItems << "MenuTextColor"; }
if(BreakLobbyButtonBgColor == "") { leftItems << "BreakLobbyButtonBgColor"; }
if(BreakLobbyButtonTextColor == "") { leftItems << "BreakLobbyButtonTextColor"; }
if(BreakLobbyButtonBgDisabledColor == "") { leftItems << "BreakLobbyButtonBgDisabledColor"; }
if(BreakLobbyButtonTextDisabledColor == "") { leftItems << "BreakLobbyButtonTextDisabledColor"; }
if(BreakLobbyButtonBgBlinkColor == "") { leftItems << "BreakLobbyButtonBgBlinkColor"; }
if(BreakLobbyButtonTextBlinkColor == "") { leftItems << "BreakLobbyButtonTextBlinkColor"; }
if(PlayerCashTextColor == "") { leftItems << "PlayerCashTextColor"; }
if(PlayerBetTextColor == "") { leftItems << "PlayerBetTextColor"; }
if(PlayerNickTextColor == "") { leftItems << "PlayerNickTextColor"; }
if(BoardBigTextColor == "") { leftItems << "BoardBigTextColor"; }
if(BoardSmallTextColor == "") { leftItems << "BoardSmallTextColor"; }
if(SpeedTextColor == "") { leftItems << "SpeedTextColor"; }
if(VoteButtonBgColor == "") { leftItems << "VoteButtonBgColor"; }
if(VoteButtonTextColor == "") { leftItems << "VoteButtonTextColor"; }
if(BetInputTextColor == "") { leftItems << "BetInputTextColor"; }
if(BetInputBgColor == "") { leftItems << "BetInputBgColor"; }
if(BetInputDisabledTextColor == "") { leftItems << "BetInputDisabledTextColor"; }
if(BetInputDisabledBgColor == "") { leftItems << "BetInputDisabledBgColor"; }
if(FoldButtonTextColor == "") { leftItems << "FoldButtonTextColor"; }
if(FoldButtonCheckableTextColor == "") { leftItems << "FoldButtonCheckableTextColor"; }
if(CheckCallButtonTextColor == "") { leftItems << "CheckCallButtonTextColor"; }
if(CheckCallButtonCheckableTextColor == "") { leftItems << "CheckCallButtonCheckableTextColor"; }
if(BetRaiseButtonTextColor == "") { leftItems << "BetRaiseButtonTextColor"; }
if(BetRaiseButtonCheckableTextColor == "") { leftItems << "BetRaiseButtonCheckableTextColor"; }
if(AllInButtonTextColor == "") { leftItems << "AllInButtonTextColor"; }
if(AllInButtonCheckableTextColor == "") { leftItems << "AllInButtonCheckableTextColor"; }
if(BetSpeedSliderGrooveBgColor == "") { leftItems << "BetSpeedSliderGrooveBgColor"; }
if(BetSpeedSliderGrooveBorderColor == "") { leftItems << "BetSpeedSliderGrooveBorderColor"; }
if(BetSpeedSliderHandleBgColor == "") { leftItems << "BetSpeedSliderHandleBgColor"; }
if(BetSpeedSliderHandleBorderColor == "") { leftItems << "BetSpeedSliderHandleBorderColor"; }
if(ShowMyCardsButtonTextColor == "") { leftItems << "ShowMyCardsButtonTextColor"; }
if(FKeyIndicatorColor == "") { FKeyIndicatorColor = getFallBackFieldContent("FKeyIndicatorColor", 0); leftItems << "FKeyIndicatorColor"; }
if(ChanceLabelPossibleColor == "") { ChanceLabelPossibleColor = getFallBackFieldContent("ChanceLabelPossibleColor", 0); leftItems << "ChanceLabelPossibleColor"; }
if(ChanceLabelImpossibleColor == "") { ChanceLabelImpossibleColor = getFallBackFieldContent("ChanceLabelImpossibleColor", 0); leftItems << "ChanceLabelImpossibleColor"; }
if(ChatLogTextColor == "") { ChatLogTextColor = getFallBackFieldContent("ChatLogTextColor", 0); leftItems << "ChatLogTextColor"; }
if(ChatTextNickNotifyColor == "") { ChatTextNickNotifyColor = getFallBackFieldContent("ChatTextNickNotifyColor", 0); leftItems << "ChatTextNickNotifyColor"; }
if(ChatLogBgColor == "") { ChatLogBgColor = getFallBackFieldContent("ChatLogBgColor", 0); leftItems << "ChatLogBgColor"; }
if(ChatLogScrollBarBorderColor == "") { ChatLogScrollBarBorderColor = getFallBackFieldContent("ChatLogScrollBarBorderColor", 0); leftItems << "ChatLogScrollBarBorderColor"; }
if(ChatLogScrollBarBgColor == "") { ChatLogScrollBarBgColor = getFallBackFieldContent("ChatLogScrollBarBgColor", 0); leftItems << "ChatLogScrollBarBgColor"; }
if(ChatLogScrollBarHandleBorderColor == "") { ChatLogScrollBarHandleBorderColor = getFallBackFieldContent("ChatLogScrollBarHandleBorderColor", 0); leftItems << "ChatLogScrollBarHandleBorderColor"; }
if(ChatLogScrollBarHandleBgColor == "") { ChatLogScrollBarHandleBgColor = getFallBackFieldContent("ChatLogScrollBarHandleBgColor", 0); leftItems << "ChatLogScrollBarHandleBgColor"; }
if(ChatLogScrollBarArrowBorderColor == "") { ChatLogScrollBarArrowBorderColor = getFallBackFieldContent("ChatLogScrollBarArrowBorderColor", 0); leftItems << "ChatLogScrollBarArrowBorderColor"; }
if(ChatLogScrollBarArrowBgColor == "") { ChatLogScrollBarArrowBgColor = getFallBackFieldContent("ChatLogScrollBarArrowBgColor", 0); leftItems << "ChatLogScrollBarArrowBgColor"; }
if(LogWinnerMainPotColor == "") { LogWinnerMainPotColor = getFallBackFieldContent("LogWinnerMainPotColor", 0); leftItems << "LogWinnerMainPotColor"; }
if(LogWinnerSidePotColor == "") { LogWinnerSidePotColor = getFallBackFieldContent("LogWinnerSidePotColor", 0); leftItems << "LogWinnerSidePotColor"; }
if(LogPlayerSitsOutColor == "") { LogPlayerSitsOutColor = getFallBackFieldContent("LogPlayerSitsOutColor", 0); leftItems << "LogPlayerSitsOutColor"; }
if(LogNewGameAdminColor == "") { LogNewGameAdminColor = getFallBackFieldContent("LogNewGameAdminColor", 0); leftItems << "LogNewGameAdminColor"; }
if(TabWidgetBorderColor == "") { TabWidgetBorderColor = getFallBackFieldContent("TabWidgetBorderColor", 0); leftItems << "TabWidgetBorderColor"; }
if(TabWidgetBgColor == "") { TabWidgetBgColor = getFallBackFieldContent("TabWidgetBgColor", 0); leftItems << "TabWidgetBgColor"; }
if(TabWidgetTextColor == "") { TabWidgetTextColor = getFallBackFieldContent("TabWidgetTextColor", 0); leftItems << "TabWidgetTextColor"; }
if(MenuBgColor == "") { MenuBgColor = getFallBackFieldContent("MenuBgColor", 0); leftItems << "MenuBgColor"; }
if(MenuTextColor == "") { MenuTextColor = getFallBackFieldContent("MenuTextColor", 0); leftItems << "MenuTextColor"; }
if(BreakLobbyButtonBgColor == "") { BreakLobbyButtonBgColor = getFallBackFieldContent("BreakLobbyButtonBgColor", 0); leftItems << "BreakLobbyButtonBgColor"; }
if(BreakLobbyButtonTextColor == "") { BreakLobbyButtonTextColor = getFallBackFieldContent("BreakLobbyButtonTextColor", 0); leftItems << "BreakLobbyButtonTextColor"; }
if(BreakLobbyButtonBgDisabledColor == "") { BreakLobbyButtonBgDisabledColor = getFallBackFieldContent("BreakLobbyButtonBgDisabledColor", 0); leftItems << "BreakLobbyButtonBgDisabledColor"; }
if(BreakLobbyButtonTextDisabledColor == "") { BreakLobbyButtonTextDisabledColor = getFallBackFieldContent("BreakLobbyButtonTextDisabledColor", 0); leftItems << "BreakLobbyButtonTextDisabledColor"; }
if(BreakLobbyButtonBgBlinkColor == "") { BreakLobbyButtonBgBlinkColor = getFallBackFieldContent("BreakLobbyButtonBgBlinkColor", 0); leftItems << "BreakLobbyButtonBgBlinkColor"; }
if(BreakLobbyButtonTextBlinkColor == "") { BreakLobbyButtonTextBlinkColor = getFallBackFieldContent("BreakLobbyButtonTextBlinkColor", 0); leftItems << "BreakLobbyButtonTextBlinkColor"; }
if(PlayerCashTextColor == "") { PlayerCashTextColor = getFallBackFieldContent("PlayerCashTextColor", 0); leftItems << "PlayerCashTextColor"; }
if(PlayerBetTextColor == "") { PlayerBetTextColor = getFallBackFieldContent("PlayerBetTextColor", 0); leftItems << "PlayerBetTextColor"; }
if(PlayerNickTextColor == "") { PlayerNickTextColor = getFallBackFieldContent("PlayerNickTextColor", 0); leftItems << "PlayerNickTextColor"; }
if(BoardBigTextColor == "") { BoardBigTextColor = getFallBackFieldContent("BoardBigTextColor", 0); leftItems << "BoardBigTextColor"; }
if(BoardSmallTextColor == "") { BoardSmallTextColor = getFallBackFieldContent("BoardSmallTextColor", 0); leftItems << "BoardSmallTextColor"; }
if(SpeedTextColor == "") { SpeedTextColor = getFallBackFieldContent("SpeedTextColor", 0); leftItems << "SpeedTextColor"; }
if(VoteButtonBgColor == "") { VoteButtonBgColor = getFallBackFieldContent("VoteButtonBgColor", 0); leftItems << "VoteButtonBgColor"; }
if(VoteButtonTextColor == "") { VoteButtonTextColor = getFallBackFieldContent("VoteButtonTextColor", 0); leftItems << "VoteButtonTextColor"; }
if(BetInputTextColor == "") { BetInputTextColor = getFallBackFieldContent("BetInputTextColor", 0); leftItems << "BetInputTextColor"; }
if(BetInputBgColor == "") { BetInputBgColor = getFallBackFieldContent("BetInputBgColor", 0); leftItems << "BetInputBgColor"; }
if(BetInputDisabledTextColor == "") { BetInputDisabledTextColor = getFallBackFieldContent("BetInputDisabledTextColor", 0); leftItems << "BetInputDisabledTextColor"; }
if(BetInputDisabledBgColor == "") { BetInputDisabledBgColor = getFallBackFieldContent("BetInputDisabledBgColor", 0); leftItems << "BetInputDisabledBgColor"; }
if(FoldButtonTextColor == "") { FoldButtonTextColor = getFallBackFieldContent("FoldButtonTextColor", 0); leftItems << "FoldButtonTextColor"; }
if(FoldButtonCheckableTextColor == "") { FoldButtonCheckableTextColor = getFallBackFieldContent("FoldButtonCheckableTextColor", 0); leftItems << "FoldButtonCheckableTextColor"; }
if(CheckCallButtonTextColor == "") { CheckCallButtonTextColor = getFallBackFieldContent("CheckCallButtonTextColor", 0); leftItems << "CheckCallButtonTextColor"; }
if(CheckCallButtonCheckableTextColor == "") { CheckCallButtonCheckableTextColor = getFallBackFieldContent("CheckCallButtonCheckableTextColor", 0); leftItems << "CheckCallButtonCheckableTextColor"; }
if(BetRaiseButtonTextColor == "") { BetRaiseButtonTextColor = getFallBackFieldContent("BetRaiseButtonTextColor", 0); leftItems << "BetRaiseButtonTextColor"; }
if(BetRaiseButtonCheckableTextColor == "") { BetRaiseButtonCheckableTextColor = getFallBackFieldContent("BetRaiseButtonCheckableTextColor", 0); leftItems << "BetRaiseButtonCheckableTextColor"; }
if(AllInButtonTextColor == "") { AllInButtonTextColor = getFallBackFieldContent("AllInButtonTextColor", 0); leftItems << "AllInButtonTextColor"; }
if(AllInButtonCheckableTextColor == "") { AllInButtonCheckableTextColor = getFallBackFieldContent("AllInButtonCheckableTextColor", 0); leftItems << "AllInButtonCheckableTextColor"; }
if(BetSpeedSliderGrooveBgColor == "") { BetSpeedSliderGrooveBgColor = getFallBackFieldContent("BetSpeedSliderGrooveBgColor", 0); leftItems << "BetSpeedSliderGrooveBgColor"; }
if(BetSpeedSliderGrooveBorderColor == "") { BetSpeedSliderGrooveBorderColor = getFallBackFieldContent("BetSpeedSliderGrooveBorderColor", 0); leftItems << "BetSpeedSliderGrooveBorderColor"; }
if(BetSpeedSliderHandleBgColor == "") { BetSpeedSliderHandleBgColor = getFallBackFieldContent("BetSpeedSliderHandleBgColor", 0); leftItems << "BetSpeedSliderHandleBgColor"; }
if(BetSpeedSliderHandleBorderColor == "") { BetSpeedSliderHandleBorderColor = getFallBackFieldContent("BetSpeedSliderHandleBorderColor", 0); leftItems << "BetSpeedSliderHandleBorderColor"; }
if(ShowMyCardsButtonTextColor == "") { ShowMyCardsButtonTextColor = getFallBackFieldContent("ShowMyCardsButtonTextColor", 0); leftItems << "ShowMyCardsButtonTextColor"; }
// SIZE
if(ChatLogTextSize == "") { leftItems << "ChatLogTextSize"; }
if(ChatLogTextSize == "") { ChatLogTextSize = getFallBackFieldContent("ChatLogTextSize", 0); leftItems << "ChatLogTextSize"; }
//set loadedSuccessfull TRUE if everything works
if(leftItems.isEmpty() && itemPicsLeft.isEmpty() && PokerTHStyleFileVersion != "" && PokerTHStyleFileVersion.toInt() == POKERTH_GT_STYLE_FILE_VERSION)
if(leftItems.isEmpty() && itemPicsLeft.isEmpty() && PokerTHStyleFileVersion != "" && PokerTHStyleFileVersion.toInt() == POKERTH_GT_STYLE_FILE_VERSION) {
loadedSuccessfull = 1;
else
loadedSuccessfull = 0;
//if one or more items are left show detailed error message
if(!leftItems.isEmpty() && myW != 0) showLeftItemsErrorMessage(StyleDescription, leftItems, StyleMaintainerEMail);
else {
//if one or more pictures where not found show detailed error message
if(!itemPicsLeft.isEmpty() && myW != 0) showItemPicsLeftErrorMessage(StyleDescription, itemPicsLeft, StyleMaintainerEMail);
//check for style file version
if(PokerTHStyleFileVersion != "" && PokerTHStyleFileVersion.toInt() != POKERTH_GT_STYLE_FILE_VERSION) {
QString EMail;
if(StyleMaintainerEMail != "NULL") EMail = StyleMaintainerEMail;
QMessageBox::warning(myW, tr("Game Table Style Error"),
tr("Selected game table style \"%1\" seems to be outdated. \n The current PokerTH game table style version is \"%2\", but this style has version \"%3\" set. \n\nPlease contact the game table style builder %4.").arg(StyleDescription).arg(POKERTH_GT_STYLE_FILE_VERSION).arg(PokerTHStyleFileVersion).arg(EMail),
QMessageBox::Ok);
myState = OK;
}
else
loadedSuccessfull = 1;
//check for style file version
if(PokerTHStyleFileVersion != "" && PokerTHStyleFileVersion.toInt() != POKERTH_GT_STYLE_FILE_VERSION)
myState = OUTDATED;
else {
//if one or more items are left
if(!leftItems.isEmpty() && myW != 0) myState = FIELDS_EMPTY;
//if one or more pictures where not found
if(!itemPicsLeft.isEmpty() && myW != 0) myState = PICTURES_MISSING;
}
}
}
@@ -505,28 +507,39 @@ void GameTableStyleReader::readStyleFile(QString file) {
}
}
void GameTableStyleReader::showLeftItemsErrorMessage(QString style, QStringList failedItems, QString email)
void GameTableStyleReader::showLeftItemsErrorMessage()
{
QString items = failedItems.join(", ");
QString items = leftItems.join(", ");
QString EMail;
if(email != "NULL") EMail = email;
if(StyleMaintainerEMail != "NULL") EMail = StyleMaintainerEMail;
QMessageBox::warning(myW, tr("Game Table Style Error"),
tr("Selected game table style \"%1\" seems to be incomplete or defective. \n\nThe value(s) of \"%2\" is/are missing. \n\nPlease contact the game table style builder %3.").arg(style).arg(items).arg(EMail),
tr("Selected game table style \"%1\" seems to be incomplete or defective. \n\nThe value(s) of \"%2\" is/are missing. \n\nPlease contact the game table style builder %3.").arg(StyleDescription).arg(items).arg(EMail),
QMessageBox::Ok);
}
void GameTableStyleReader::showItemPicsLeftErrorMessage(QString style, QStringList picsLeft, QString email)
void GameTableStyleReader::showItemPicsLeftErrorMessage()
{
QString pics = picsLeft.join("\n");
QString pics = itemPicsLeft.join("\n");
QString EMail;
if(email != "NULL") EMail = email;
if(StyleMaintainerEMail != "NULL") EMail = StyleMaintainerEMail;
QMessageBox::warning(myW, tr("Game Table Style Error"),
tr("One or more pictures from current game table style \"%1\" were not found: \n\n\"%2\" \n\nPlease contact the game table style builder %3.").arg(style).arg(pics).arg(EMail),
tr("One or more pictures from current game table style \"%1\" were not found: \n\n\"%2\" \n\nPlease contact the game table style builder %3.").arg(StyleDescription).arg(pics).arg(EMail),
QMessageBox::Ok);
}
void GameTableStyleReader::showOutdatedErrorMessage()
{
QString EMail;
if(StyleMaintainerEMail != "NULL") EMail = StyleMaintainerEMail;
QMessageBox::warning(myW, tr("Game Table Style Error"),
tr("Selected game table style \"%1\" seems to be outdated. \n The current PokerTH game table style version is \"%2\", but this style has version \"%3\" set. \n\nPlease contact the game table style builder %4.").arg(StyleDescription).arg(POKERTH_GT_STYLE_FILE_VERSION).arg(PokerTHStyleFileVersion).arg(EMail),
QMessageBox::Ok);
}
void GameTableStyleReader::setTableBackground(gameTableImpl *gt)
{
gt->setStyleSheet("QMainWindow { background-image: url(\""+Table+"\"); background-position: bottom center; background-origin: content; background-repeat: no-repeat;}");
@@ -588,10 +601,10 @@ void GameTableStyleReader::setMenuBarStyle(QMenuBar *mb)
void GameTableStyleReader::setBreakButtonStyle(QPushButton *bb, int state)
{
switch(state) {
// default
// default
case 0: bb->setStyleSheet("QPushButton:enabled { background-color: #"+BreakLobbyButtonBgColor+"; color: #"+BreakLobbyButtonTextColor+";} QPushButton:disabled { background-color: #"+BreakLobbyButtonBgDisabledColor+"; color: #"+BreakLobbyButtonTextDisabledColor+"; font-weight: 900;}");
break;
// blink
// blink
case 1: bb->setStyleSheet("QPushButton { background-color: #"+BreakLobbyButtonBgBlinkColor+"; color: "+BreakLobbyButtonTextBlinkColor+";}");
break;
@@ -626,7 +639,7 @@ void GameTableStyleReader::setPlayerSeatInactiveStyle(QGroupBox *ps)
void GameTableStyleReader::setPlayerSeatActiveStyle(QGroupBox *ps)
{
// check if seat is on top or bottom line
// check if seat is on top or bottom line
if(ps->objectName() == "groupBox2" || ps->objectName() == "groupBox1" || ps->objectName() == "groupBox0" || ps->objectName() == "groupBox9" || ps->objectName() == "groupBox8") {
ps->setStyleSheet("QGroupBox { border:none; background-image: url(\""+PlayerBottomSeatActive+"\") }");
}
@@ -650,7 +663,7 @@ QString GameTableStyleReader::getActionPic(int action)
{
QString myAppDataPath = QString::fromUtf8(myConfig->readConfigString("AppDataDir").c_str());
// 1 = fold, 2 = check, 3 = call, 4 = bet, 5 = raise, 6 = allin, 7 = winner
// 1 = fold, 2 = check, 3 = call, 4 = bet, 5 = raise, 6 = allin, 7 = winner
switch(action) {
case 1: {
if(myConfig->readConfigInt("DontTranslateInternationalPokerStringsFromStyle") || ActionFoldI18NPic.endsWith("NULL"))
@@ -826,3 +839,56 @@ void GameTableStyleReader::setSliderStyle(QSlider *s)
s->setStyleSheet("QSlider::groove:horizontal { border: 1px solid #"+BetSpeedSliderGrooveBorderColor+"; height: 3px; background: #"+BetSpeedSliderGrooveBgColor+"; margin: 4px 0; border-radius: 2px; } QSlider::handle:horizontal { background: #"+BetSpeedSliderHandleBgColor+"; border: 1px solid #"+BetSpeedSliderHandleBorderColor+"; width: 12px; margin: -2px 0; border-radius: 4px;}");
}
QString GameTableStyleReader::getFallBackFieldContent(QString field, int type)
{
QFile myFile(QFile(QString::fromUtf8(myConfig->readConfigString("AppDataDir").c_str())+"gfx/gui/table/default/defaulttablestyle.xml").fileName());
myFile.open(QIODevice::ReadOnly);
QByteArray thisContent = myFile.readAll();
//start reading the file and fill vars
string tempString1("");
TiXmlDocument doc;
doc.Parse(thisContent.constData());
if(doc.RootElement()) {
TiXmlHandle docHandle( &doc );
TiXmlElement *CardDeckElement = docHandle.FirstChild( "PokerTH" ).FirstChild( "CardDeck" ).ToElement();
if(CardDeckElement) {
QMessageBox::warning(myW, tr("Game Table Style Error"),
tr("A card deck style was selected instead of a game table style.\nPlease select a game table style and try again!"),
QMessageBox::Ok);
}
else {
TiXmlElement* itemsList = docHandle.FirstChild( "PokerTH" ).FirstChild( "TableStyle" ).FirstChild().ToElement();
for( ; itemsList; itemsList=itemsList->NextSiblingElement()) {
const char *tmpStr1 = itemsList->Attribute("value");
if (tmpStr1) {
tempString1 = tmpStr1;
if(itemsList->ValueStr() == field.toStdString()) {
if(type == 1) return QString(QString::fromUtf8(myConfig->readConfigString("AppDataDir").c_str())+"gfx/gui/table/default/"+QString::fromUtf8(tempString1.c_str()));
else return QString::fromUtf8(tempString1.c_str());
}
}
}
}
}
return QString("");
}
QString GameTableStyleReader::getMyStateToolTipInfo()
{
switch (myState) {
case OK: return QString(tr("Everything OK!"));
break;
case PICTURES_MISSING: return QString(tr("Some pictures are missing, please contact style maintainer for this issue."));
break;
case FIELDS_EMPTY: return QString(tr("Some style fields are missing, please contact style maintainer for this issue."));
break;
case OUTDATED: return QString(tr("This style is outdated, please contact style maintainer for this issue."));
break;
default: return QString("");
}
}
+17 -9
View File
@@ -23,6 +23,7 @@
#include "tinyxml.h"
#include "configfile.h"
#include "gametableimpl.h"
#include "game_defs.h"
#include <string>
#include <QtCore>
#include <QtGui>
@@ -30,15 +31,16 @@
class gameTableImpl;
class GameTableStyleReader : public QObject {
Q_OBJECT
Q_OBJECT
public:
GameTableStyleReader(ConfigFile *c, QWidget *w);
~GameTableStyleReader();
void readStyleFile(QString);
void showLeftItemsErrorMessage(QString, QStringList, QString);
void showItemPicsLeftErrorMessage(QString, QStringList, QString);
void showLeftItemsErrorMessage();
void showItemPicsLeftErrorMessage();
void showOutdatedErrorMessage();
QString getStyleDescription() const { return StyleDescription; }
QString getStyleMaintainerName() const { return StyleMaintainerName; }
@@ -75,6 +77,7 @@ public:
bool getFallBack() const { return fallBack; }
bool getLoadedSuccessfull() const { return loadedSuccessfull; }
StyleState getState() const { return myState; }
//set pictures
void setTableBackground(gameTableImpl*);
@@ -124,15 +127,18 @@ public:
QString getTotalI18NString() const { return TotalI18NString; }
QString getPotI18NString() const { return PotI18NString; }
QString getFallBackFieldContent(QString field, int type); // type: 0 = string, 1= picture
QString getMyStateToolTipInfo();
private:
//style values
// INFOS
// INFOS
QString StyleDescription;
QString StyleMaintainerName;
QString StyleMaintainerEMail;
QString StyleCreateDate;
QString PokerTHStyleFileVersion;
// WINDOWS SETTINGS
// WINDOWS SETTINGS
QString IfFixedWindowSize;
QString FixedWindowWidth;
QString FixedWindowHeight;
@@ -140,7 +146,7 @@ private:
QString MinimumWindowHeight;
QString MaximumWindowWidth;
QString MaximumWindowHeight;
// PICS
// PICS
QString Preview;
QString ActionAllInI18NPic;
QString ActionRaiseI18NPic;
@@ -187,7 +193,7 @@ private:
QString ShowMyCardsButtonDefault;
QString ShowMyCardsButtonHover;
// I18N ACTION STRINGS
// I18N ACTION STRINGS
QString ActionAllInI18NString;
QString ActionRaiseI18NString;
QString ActionBetI18NString;
@@ -204,7 +210,7 @@ private:
QString TurnI18NString;
QString RiverI18NString;
// COLORS
// COLORS
QString FKeyIndicatorColor;
QString ChanceLabelPossibleColor;
QString ChanceLabelImpossibleColor;
@@ -258,7 +264,7 @@ private:
QString BetSpeedSliderHandleBorderColor;
QString ShowMyCardsButtonTextColor;
// SIZES
// SIZES
QString ChatLogTextSize;
//internal
@@ -288,6 +294,8 @@ private:
bool fallBack;
bool loadedSuccessfull;
StyleState myState;
};
#endif