android gui tweaks and bugfix for crash on windows/linux

This commit is contained in:
doitux
2012-05-28 18:45:02 +02:00
parent db359fe80b
commit 4f9a7941de
5 changed files with 26 additions and 8 deletions
@@ -44,10 +44,10 @@ gameLobbyDialogImpl::gameLobbyDialogImpl(startWindowImpl *parent, ConfigFile *c)
myAppDataPath = QString::fromUtf8(myConfig->readConfigString("AppDataDir").c_str());
//wait start game message
waitStartGameMsgBox = new MyMessageBox(this);
waitStartGameMsgBox = new MyMessageBox(this);
waitStartGameMsgBox->setText(tr("Starting game. Please wait ..."));
#ifndef ANDROID
waitRejoinStartGameMsgBox->setWindowModality(Qt::NonModal);
waitStartGameMsgBox->setWindowModality(Qt::NonModal);
#endif
#ifdef __APPLE__
waitStartGameMsgBox->setWindowFlags(Qt::WindowSystemMenuHint | Qt::CustomizeWindowHint | Qt::Dialog);
@@ -55,10 +55,10 @@ gameLobbyDialogImpl::gameLobbyDialogImpl(startWindowImpl *parent, ConfigFile *c)
waitStartGameMsgBox->setStandardButtons(QMessageBox::NoButton);
//wait start game message for rejoin
waitRejoinStartGameMsgBox = new MyMessageBox(this);
waitRejoinStartGameMsgBox = new MyMessageBox(this);
waitRejoinStartGameMsgBox->setText(tr("Waiting for the start of the next hand to rejoin the game ..."));
#ifndef ANDROID
waitRejoinStartGameMsgBox->setWindowModality(Qt::NonModal);
waitRejoinStartGameMsgBox->setWindowModality(Qt::NonModal);
#endif
#ifdef __APPLE__
waitRejoinStartGameMsgBox->setWindowFlags(Qt::WindowSystemMenuHint | Qt::CustomizeWindowHint | Qt::Dialog);
+11
View File
@@ -303,6 +303,17 @@ gameTableImpl::gameTableImpl(ConfigFile *c, QMainWindow *parent)
playerTipLabelArray[8] = label_playerTip8;
playerTipLabelArray[9] = label_playerTip9;
#ifdef GUI_800x480
int j;
for (i=0; i<MAX_NUMBER_OF_PLAYERS; ++i) {
for (j=1; j<=5; ++j) {
playerStarsArray[j][i]->hide();
}
playerTipLabelArray[i]->hide();
}
#endif
// playerNameLabelArray init
playerNameLabelArray[0] = label_PlayerName0;
playerNameLabelArray[1] = label_PlayerName1;
@@ -315,7 +315,7 @@
</item>
</layout>
</widget>
<widget class="QWidget" name="page_8">
<widget class="QWidget" name="page_styles">
<layout class="QGridLayout" name="gridLayout_12">
<property name="margin">
<number>4</number>
@@ -807,7 +807,7 @@ p, li { white-space: pre-wrap; }
</item>
</layout>
</widget>
<widget class="QWidget" name="page_6">
<widget class="QWidget" name="page_sound">
<layout class="QGridLayout">
<property name="margin">
<number>4</number>
@@ -39,6 +39,13 @@ settingsDialogImpl::settingsDialogImpl(QWidget *parent, ConfigFile *c, selectAva
#endif
setupUi(this);
#ifdef ANDROID
stackedWidget->removeWidget(page_styles);
stackedWidget->removeWidget(page_sound);
listWidget->takeItem(1);
listWidget->takeItem(1);
#endif
if(!SQLITE_LOG) {//temporarely remove sql log features
pushButton_deleteLog->hide();
pushButton_saveLogAs->hide();
+2 -2
View File
@@ -1364,7 +1364,7 @@ void GameTableStyleReader::setBreakButtonStyle(QPushButton *bb, int state)
// default
case 0:
#ifdef GUI_800x480
bb->setStyleSheet("QPushButton:enabled { background-color: #"+BreakLobbyButtonBgColor+"; color: #"+BreakLobbyButtonTextColor+"; font-size: 26px} QPushButton:disabled { background-color: #"+BreakLobbyButtonBgDisabledColor+"; color: #"+BreakLobbyButtonTextDisabledColor+"; font-weight: 900; font-size: 26px}");
bb->setStyleSheet("QPushButton:enabled { padding: 10px; background-color: #"+BreakLobbyButtonBgColor+"; color: #"+BreakLobbyButtonTextColor+"; font-size: 26px} QPushButton:disabled { padding: 10px; background-color: #"+BreakLobbyButtonBgDisabledColor+"; color: #"+BreakLobbyButtonTextDisabledColor+"; font-weight: 900; font-size: 26px}");
#else
bb->setStyleSheet("QPushButton:enabled { background-color: #"+BreakLobbyButtonBgColor+"; color: #"+BreakLobbyButtonTextColor+";} QPushButton:disabled { background-color: #"+BreakLobbyButtonBgDisabledColor+"; color: #"+BreakLobbyButtonTextDisabledColor+"; font-weight: 900;}");
#endif
@@ -1372,7 +1372,7 @@ void GameTableStyleReader::setBreakButtonStyle(QPushButton *bb, int state)
// blink
case 1:
#ifdef GUI_800x480
bb->setStyleSheet("QPushButton { background-color: #"+BreakLobbyButtonBgBlinkColor+"; color: "+BreakLobbyButtonTextBlinkColor+"; font-size: 26px}");
bb->setStyleSheet("QPushButton { padding: 10px; background-color: #"+BreakLobbyButtonBgBlinkColor+"; color: "+BreakLobbyButtonTextBlinkColor+"; font-size: 26px}");
#else
bb->setStyleSheet("QPushButton { background-color: #"+BreakLobbyButtonBgBlinkColor+"; color: "+BreakLobbyButtonTextBlinkColor+";}");
#endif