Running astyle.
This commit is contained in:
@@ -1498,8 +1498,7 @@ void gameLobbyDialogImpl::changeNickListFilter(int state)
|
|||||||
if(lastNickListFilterState == 0) {
|
if(lastNickListFilterState == 0) {
|
||||||
myNickListSortFilterProxyModel->setLastFilterStateCountry(false);
|
myNickListSortFilterProxyModel->setLastFilterStateCountry(false);
|
||||||
myNickListSortFilterProxyModel->setLastFilterStateAlpha(true);
|
myNickListSortFilterProxyModel->setLastFilterStateAlpha(true);
|
||||||
}
|
} else if(lastNickListFilterState == 1) {
|
||||||
else if(lastNickListFilterState == 1) {
|
|
||||||
myNickListSortFilterProxyModel->setLastFilterStateCountry(true);
|
myNickListSortFilterProxyModel->setLastFilterStateCountry(true);
|
||||||
myNickListSortFilterProxyModel->setLastFilterStateAlpha(false);
|
myNickListSortFilterProxyModel->setLastFilterStateAlpha(false);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -67,8 +67,7 @@ bool MyNickListSortFilterProxyModel::lessThan(const QModelIndex &left, const QMo
|
|||||||
QString leftCountryAndName(sourceModel()->data(left, 33).toString().toUpper()+sourceModel()->data(left, Qt::DisplayRole).toString().toLower());
|
QString leftCountryAndName(sourceModel()->data(left, 33).toString().toUpper()+sourceModel()->data(left, Qt::DisplayRole).toString().toLower());
|
||||||
QString rightCountryAndName(sourceModel()->data(right, 33).toString().toUpper()+sourceModel()->data(right, Qt::DisplayRole).toString().toLower());
|
QString rightCountryAndName(sourceModel()->data(right, 33).toString().toUpper()+sourceModel()->data(right, Qt::DisplayRole).toString().toLower());
|
||||||
return leftCountryAndName < rightCountryAndName;
|
return leftCountryAndName < rightCountryAndName;
|
||||||
}
|
} else if(lastFilterStateAlpha) {
|
||||||
else if(lastFilterStateAlpha) {
|
|
||||||
return QSortFilterProxyModel::lessThan(left, right);
|
return QSortFilterProxyModel::lessThan(left, right);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -28,8 +28,12 @@ public:
|
|||||||
MyNickListSortFilterProxyModel(QObject *parent = 0);
|
MyNickListSortFilterProxyModel(QObject *parent = 0);
|
||||||
|
|
||||||
void setFilterState(int state);
|
void setFilterState(int state);
|
||||||
void setLastFilterStateCountry( bool country ) { lastFilterStateCountry = country;}
|
void setLastFilterStateCountry( bool country ) {
|
||||||
void setLastFilterStateAlpha( bool alpha ) { lastFilterStateAlpha = alpha;}
|
lastFilterStateCountry = country;
|
||||||
|
}
|
||||||
|
void setLastFilterStateAlpha( bool alpha ) {
|
||||||
|
lastFilterStateAlpha = alpha;
|
||||||
|
}
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
bool filterAcceptsRow(int sourceRow, const QModelIndex &sourceParent) const;
|
bool filterAcceptsRow(int sourceRow, const QModelIndex &sourceParent) const;
|
||||||
|
|||||||
@@ -78,7 +78,9 @@ public:
|
|||||||
void setMySqliteLogFileName(std::string theValue) {
|
void setMySqliteLogFileName(std::string theValue) {
|
||||||
mySqliteLogFileName = theValue;
|
mySqliteLogFileName = theValue;
|
||||||
}
|
}
|
||||||
std::string getMySqliteLogFileName() { return mySqliteLogFileName; }
|
std::string getMySqliteLogFileName() {
|
||||||
|
return mySqliteLogFileName;
|
||||||
|
}
|
||||||
|
|
||||||
signals:
|
signals:
|
||||||
void signalLogPlayerActionMsg(QString playerName, int action, int setValue);
|
void signalLogPlayerActionMsg(QString playerName, int action, int setValue);
|
||||||
|
|||||||
Reference in New Issue
Block a user