stop at the end of local game. needs start button to start next game
This commit is contained in:
@@ -59,7 +59,7 @@
|
|||||||
using namespace std;
|
using namespace std;
|
||||||
|
|
||||||
mainWindowImpl::mainWindowImpl(ConfigFile *c, QMainWindow *parent)
|
mainWindowImpl::mainWindowImpl(ConfigFile *c, QMainWindow *parent)
|
||||||
: QMainWindow(parent), myChat(NULL), myConfig(c), gameSpeed(0), myActionIsBet(0), myActionIsRaise(0), pushButtonBetRaiseIsChecked(FALSE), pushButtonCallCheckIsChecked(FALSE), pushButtonFoldIsChecked(FALSE), pushButtonAllInIsChecked(FALSE), myButtonsAreCheckable(FALSE), breakAfterCurrentHand(FALSE)
|
: QMainWindow(parent), myChat(NULL), myConfig(c), gameSpeed(0), myActionIsBet(0), myActionIsRaise(0), pushButtonBetRaiseIsChecked(FALSE), pushButtonCallCheckIsChecked(FALSE), pushButtonFoldIsChecked(FALSE), pushButtonAllInIsChecked(FALSE), myButtonsAreCheckable(FALSE), breakAfterCurrentHand(FALSE), currentGameOver(FALSE)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
@@ -1174,7 +1174,7 @@ void mainWindowImpl::refreshSet() {
|
|||||||
if( (*it_c)->getMySet() == 0 )
|
if( (*it_c)->getMySet() == 0 )
|
||||||
setLabelArray[(*it_c)->getMyID()]->setText("");
|
setLabelArray[(*it_c)->getMyID()]->setText("");
|
||||||
else
|
else
|
||||||
setLabelArray[(*it_c)->getMyID()]->setText("Set: "+QString::number((*it_c)->getMySet(),10)+" $");
|
setLabelArray[(*it_c)->getMyID()]->setText("Bet: "+QString::number((*it_c)->getMySet(),10)+" $");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -2775,12 +2775,22 @@ void mainWindowImpl::postRiverRunAnimation6() {
|
|||||||
if ((*it_c)->getMyCash() > 0) playersPositiveCashCounter++;
|
if ((*it_c)->getMyCash() > 0) playersPositiveCashCounter++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if (playersPositiveCashCounter==1) {
|
if (playersPositiveCashCounter==1) {
|
||||||
|
|
||||||
callNewGameDialog();
|
if( !DEBUG_MODE ) {
|
||||||
//Bei Cancel nichts machen!!!
|
currentGameOver = TRUE;
|
||||||
|
|
||||||
|
pushButton_break->setDisabled(FALSE);
|
||||||
|
QFontMetrics tempMetrics = this->fontMetrics();
|
||||||
|
int width = tempMetrics.width(tr("Start"));
|
||||||
|
pushButton_break->setMinimumSize(width+10,20);
|
||||||
|
pushButton_break->setText(tr("Start"));
|
||||||
|
blinkingStartButtonAnimationTimer->start(500);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
callNewGameDialog();
|
||||||
|
//Bei Cancel nichts machen!!!
|
||||||
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -3040,7 +3050,15 @@ void mainWindowImpl::breakButtonClicked() {
|
|||||||
pushButton_break->setMinimumSize(width+10,20);
|
pushButton_break->setMinimumSize(width+10,20);
|
||||||
|
|
||||||
pushButton_break->setText(tr("Stop"));
|
pushButton_break->setText(tr("Stop"));
|
||||||
startNewHand();
|
|
||||||
|
if(currentGameOver) {
|
||||||
|
currentGameOver = FALSE;
|
||||||
|
callNewGameDialog();
|
||||||
|
//Bei Cancel nichts machen!!!
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
startNewHand();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -460,7 +460,8 @@ private:
|
|||||||
bool myButtonsAreCheckable;
|
bool myButtonsAreCheckable;
|
||||||
|
|
||||||
bool breakAfterCurrentHand;
|
bool breakAfterCurrentHand;
|
||||||
|
bool currentGameOver;
|
||||||
|
|
||||||
bool flipHolecardsAllInAlreadyDone;
|
bool flipHolecardsAllInAlreadyDone;
|
||||||
|
|
||||||
QColor active;
|
QColor active;
|
||||||
|
|||||||
Reference in New Issue
Block a user