mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-02 19:43:55 -07:00
assign new arrow id when arrow is moved to transformed card (#5012)
* add timeout to settingscache * assign new arrow id when arrow is moved to transformed card fixes bug introduced in #4907 fixes #5008
This commit is contained in:
parent
e8c7fba8b0
commit
f174614496
7 changed files with 30 additions and 11 deletions
|
|
@ -32,6 +32,7 @@ RemoteClient::RemoteClient(QObject *parent)
|
|||
{
|
||||
|
||||
clearNewClientFeatures();
|
||||
maxTimeout = SettingsCache::instance().getTimeOut();
|
||||
int keepalive = SettingsCache::instance().getKeepAlive();
|
||||
timer = new QTimer(this);
|
||||
timer->setInterval(keepalive * 1000);
|
||||
|
|
|
|||
|
|
@ -89,7 +89,7 @@ private slots:
|
|||
void submitForgotPasswordChallengeResponse(const Response &response);
|
||||
|
||||
private:
|
||||
static const int maxTimeout = 5;
|
||||
int maxTimeout;
|
||||
int timeRunning, lastDataReceived;
|
||||
QByteArray inputBuffer;
|
||||
bool messageInProgress;
|
||||
|
|
|
|||
|
|
@ -195,6 +195,7 @@ SettingsCache::SettingsCache()
|
|||
|
||||
lang = settings->value("personal/lang").toString();
|
||||
keepalive = settings->value("personal/keepalive", 3).toInt();
|
||||
timeout = settings->value("personal/timeout", 5).toInt();
|
||||
|
||||
// tip of the day settings
|
||||
showTipsOnStartup = settings->value("tipOfDay/showTips", true).toBool();
|
||||
|
|
|
|||
|
|
@ -134,6 +134,7 @@ private:
|
|||
bool spectatorsCanSeeEverything;
|
||||
bool createGameAsSpectator;
|
||||
int keepalive;
|
||||
int timeout;
|
||||
void translateLegacySettings();
|
||||
QString getSafeConfigPath(QString configEntry, QString defaultPath) const;
|
||||
QString getSafeConfigFilePath(QString configEntry, QString defaultPath) const;
|
||||
|
|
@ -434,6 +435,10 @@ public:
|
|||
{
|
||||
return keepalive;
|
||||
}
|
||||
int getTimeOut() const
|
||||
{
|
||||
return timeout;
|
||||
}
|
||||
int getMaxFontSize() const
|
||||
{
|
||||
return maxFontSize;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue