mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-06-26 16:43:55 -07:00
Pass QTime objects instead of references (#5209)
- References seem to go to 0 in newer Qt versions(?) https://doc.qt.io/qt-6/qtime.html > QTime objects should be passed by value rather than by reference to const; they simply package int.
This commit is contained in:
parent
d2bc7f6ac0
commit
e33ff37c82
2 changed files with 2 additions and 2 deletions
|
|
@ -276,7 +276,7 @@ int DlgFilterGames::getMaxPlayersFilterMax() const
|
||||||
return maxPlayersFilterMaxSpinBox->value();
|
return maxPlayersFilterMaxSpinBox->value();
|
||||||
}
|
}
|
||||||
|
|
||||||
const QTime &DlgFilterGames::getMaxGameAge() const
|
QTime DlgFilterGames::getMaxGameAge() const
|
||||||
{
|
{
|
||||||
int index = maxGameAgeComboBox->currentIndex();
|
int index = maxGameAgeComboBox->currentIndex();
|
||||||
if (index < 0 || index >= gameAgeMap.size()) { // index is out of bounds
|
if (index < 0 || index >= gameAgeMap.size()) { // index is out of bounds
|
||||||
|
|
|
||||||
|
|
@ -67,7 +67,7 @@ public:
|
||||||
int getMaxPlayersFilterMin() const;
|
int getMaxPlayersFilterMin() const;
|
||||||
int getMaxPlayersFilterMax() const;
|
int getMaxPlayersFilterMax() const;
|
||||||
void setMaxPlayersFilter(int _maxPlayersFilterMin, int _maxPlayersFilterMax);
|
void setMaxPlayersFilter(int _maxPlayersFilterMin, int _maxPlayersFilterMax);
|
||||||
const QTime &getMaxGameAge() const;
|
QTime getMaxGameAge() const;
|
||||||
const QMap<QTime, QString> gameAgeMap;
|
const QMap<QTime, QString> gameAgeMap;
|
||||||
bool getShowOnlyIfSpectatorsCanWatch() const;
|
bool getShowOnlyIfSpectatorsCanWatch() const;
|
||||||
bool getShowSpectatorPasswordProtected() const;
|
bool getShowSpectatorPasswordProtected() const;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue