Next steps for voting to kick a user.
This commit is contained in:
@@ -589,7 +589,7 @@ gameTableImpl::gameTableImpl(ConfigFile *c, QMainWindow *parent)
|
||||
connect(this, SIGNAL(signalPostRiverRunAnimation1()), this, SLOT(postRiverRunAnimation1()));
|
||||
connect(this, SIGNAL(signalFlipHolecardsAllIn()), this, SLOT(flipHolecardsAllIn()));
|
||||
connect(this, SIGNAL(signalNextRoundCleanGui()), this, SLOT(nextRoundCleanGui()));
|
||||
connect(this, SIGNAL(signalStartVoteOnKick(int, int, int)), this, SLOT(startVoteOnKick(int, int, int)));
|
||||
connect(this, SIGNAL(signalStartVoteOnKick(unsigned, int, int)), this, SLOT(startVoteOnKick(unsigned, int, int)));
|
||||
connect(this, SIGNAL(signalChangeVoteOnKickButtonsState(bool)), this, SLOT(changeVoteOnKickButtonsState(bool)));
|
||||
connect(this, SIGNAL(signalEndVoteOnKick()), this, SLOT(endVoteOnKick()));
|
||||
|
||||
@@ -3099,7 +3099,7 @@ void gameTableImpl::triggerVoteOnKick(int id) {
|
||||
}
|
||||
}
|
||||
|
||||
void gameTableImpl::startVoteOnKick(int playerId, int timeoutSec, int numVotesNeededToKick)
|
||||
void gameTableImpl::startVoteOnKick(unsigned playerId, int timeoutSec, int numVotesNeededToKick)
|
||||
{
|
||||
if(tabWidget_Left->widget(2) != tab_Kick)
|
||||
tabWidget_Left->insertTab(2, tab_Kick, QString(tr("Kick")));
|
||||
@@ -3109,7 +3109,7 @@ void gameTableImpl::startVoteOnKick(int playerId, int timeoutSec, int numVotesNe
|
||||
pushButton_voteOnKickYes->hide();
|
||||
voteOnKickTimeoutSecs = timeoutSec;
|
||||
|
||||
playerAboutToKickId = playerId;
|
||||
playerAboutToBeKickedId = playerId;
|
||||
refreshVotesMonitor(1, numVotesNeededToKick);
|
||||
|
||||
startVoteOnKickTimeout();
|
||||
@@ -3124,7 +3124,7 @@ void gameTableImpl::changeVoteOnKickButtonsState(bool showHide)
|
||||
{
|
||||
if(showHide) {
|
||||
|
||||
PlayerInfo info(myStartWindow->getSession()->getClientPlayerInfo(playerAboutToKickId));
|
||||
PlayerInfo info(myStartWindow->getSession()->getClientPlayerInfo(playerAboutToBeKickedId));
|
||||
label_kickUser->setText(tr("Do you want to kick <b>%1</b><br>from this game?").arg(QString::fromUtf8(info.playerName.c_str())));
|
||||
|
||||
pushButton_voteOnKickNo->show();
|
||||
@@ -3176,7 +3176,7 @@ void gameTableImpl::nextVoteOnKickTimeoutAnimationFrame()
|
||||
|
||||
void gameTableImpl::refreshVotesMonitor(int currentVotes, int numVotesNeededToKick)
|
||||
{
|
||||
PlayerInfo info(myStartWindow->getSession()->getClientPlayerInfo(playerAboutToKickId));
|
||||
PlayerInfo info(myStartWindow->getSession()->getClientPlayerInfo(playerAboutToBeKickedId));
|
||||
label_votesMonitor->setText(tr("Player <b>%1</b> has %2 votes<br>against him. %3 votes needed to kick.").arg(QString::fromUtf8(info.playerName.c_str())).arg(currentVotes).arg(numVotesNeededToKick));
|
||||
}
|
||||
|
||||
|
||||
@@ -119,7 +119,7 @@ signals:
|
||||
|
||||
void signalNextRoundCleanGui();
|
||||
|
||||
void signalStartVoteOnKick(int playerId, int timeoutSec, int numVotesNeededToKick);
|
||||
void signalStartVoteOnKick(unsigned playerId, int timeoutSec, int numVotesNeededToKick);
|
||||
void signalChangeVoteOnKickButtonsState(bool showHide);
|
||||
void signalEndVoteOnKick();
|
||||
|
||||
@@ -409,7 +409,7 @@ private:
|
||||
int myLastPreActionBetValue;
|
||||
|
||||
int voteOnKickTimeoutSecs;
|
||||
int playerAboutToKickId;
|
||||
unsigned playerAboutToBeKickedId;
|
||||
// StyleSheetReader *myStyleSheetReader;
|
||||
|
||||
friend class GuiWrapper;
|
||||
|
||||
@@ -102,10 +102,10 @@ void GuiWrapper::nextRoundCleanGui() { myW->signalNextRoundCleanGui(); }
|
||||
void GuiWrapper::meInAction() { myW->signalMeInAction(); }
|
||||
void GuiWrapper::updateMyButtonsState() { myW->signalUpdateMyButtonsState(); }
|
||||
void GuiWrapper::disableMyButtons() { myW->signalDisableMyButtons(); }
|
||||
void GuiWrapper::startTimeoutAnimation(int playerId, int timeoutSec) { myW->signalStartTimeoutAnimation(playerId, timeoutSec); }
|
||||
void GuiWrapper::stopTimeoutAnimation(int playerId) { myW->signalStopTimeoutAnimation(playerId); }
|
||||
void GuiWrapper::startTimeoutAnimation(int playerNum, int timeoutSec) { myW->signalStartTimeoutAnimation(playerNum, timeoutSec); }
|
||||
void GuiWrapper::stopTimeoutAnimation(int playerNum) { myW->signalStopTimeoutAnimation(playerNum); }
|
||||
|
||||
void GuiWrapper::startVoteOnKick(int playerId, int timeoutSec, int numVotesNeededToKick) { myW->signalStartVoteOnKick(playerId, timeoutSec, numVotesNeededToKick); }
|
||||
void GuiWrapper::startVoteOnKick(unsigned playerId, int timeoutSec, int numVotesNeededToKick) { myW->signalStartVoteOnKick(playerId, timeoutSec, numVotesNeededToKick); }
|
||||
void GuiWrapper::changeVoteOnKickButtonsState(bool showHide) { myW->changeVoteOnKickButtonsState(showHide); }
|
||||
void GuiWrapper::refreshVotesMonitor(int currentVotes, int numVotesNeededToKick) { myW->refreshVotesMonitor(currentVotes, numVotesNeededToKick); }
|
||||
void GuiWrapper::endVoteOnKick() { myW->signalEndVoteOnKick(); }
|
||||
|
||||
@@ -93,10 +93,10 @@ public:
|
||||
void meInAction();
|
||||
void disableMyButtons();
|
||||
void updateMyButtonsState();
|
||||
void startTimeoutAnimation(int playerId, int timeoutSec);
|
||||
void stopTimeoutAnimation(int playerId);
|
||||
void startTimeoutAnimation(int playerNum, int timeoutSec);
|
||||
void stopTimeoutAnimation(int playerNum);
|
||||
|
||||
void startVoteOnKick(int playerId, int timeoutSec, int numVotesNeededToKick);
|
||||
void startVoteOnKick(unsigned playerId, int timeoutSec, int numVotesNeededToKick);
|
||||
void changeVoteOnKickButtonsState(bool showHide);
|
||||
void refreshVotesMonitor(int currentVotes, int numVotesNeededToKick);
|
||||
void endVoteOnKick();
|
||||
|
||||
Reference in New Issue
Block a user