summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2018-08-07 04:00:49 +0200
committerGitHub <noreply@github.com>2018-08-07 04:00:49 +0200
commite218d79cc2d60468b42a56c4d76b4339ac8efd90 (patch)
tree1b2553d2f0fd85dedf0483648223a7eb5439f7c9
parentMerge pull request #946 from lioncash/compress (diff)
parentgame_list: Join declarations and assignments in onTextChanged() (diff)
downloadyuzu-e218d79cc2d60468b42a56c4d76b4339ac8efd90.tar
yuzu-e218d79cc2d60468b42a56c4d76b4339ac8efd90.tar.gz
yuzu-e218d79cc2d60468b42a56c4d76b4339ac8efd90.tar.bz2
yuzu-e218d79cc2d60468b42a56c4d76b4339ac8efd90.tar.lz
yuzu-e218d79cc2d60468b42a56c4d76b4339ac8efd90.tar.xz
yuzu-e218d79cc2d60468b42a56c4d76b4339ac8efd90.tar.zst
yuzu-e218d79cc2d60468b42a56c4d76b4339ac8efd90.zip
-rw-r--r--src/yuzu/game_list.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/yuzu/game_list.cpp b/src/yuzu/game_list.cpp
index 71e24a9e2..a0e16641d 100644
--- a/src/yuzu/game_list.cpp
+++ b/src/yuzu/game_list.cpp
@@ -162,15 +162,15 @@ void GameList::onTextChanged(const QString& newText) {
}
search_field->setFilterResult(rowCount, rowCount);
} else {
- QStandardItem* child_file;
- QString file_path, file_name, file_title, file_programmid;
int result_count = 0;
for (int i = 0; i < rowCount; ++i) {
- child_file = item_model->item(i, 0);
- file_path = child_file->data(GameListItemPath::FullPathRole).toString().toLower();
- file_name = file_path.mid(file_path.lastIndexOf("/") + 1);
- file_title = child_file->data(GameListItemPath::TitleRole).toString().toLower();
- file_programmid =
+ const QStandardItem* child_file = item_model->item(i, 0);
+ const QString file_path =
+ child_file->data(GameListItemPath::FullPathRole).toString().toLower();
+ QString file_name = file_path.mid(file_path.lastIndexOf('/') + 1);
+ const QString file_title =
+ child_file->data(GameListItemPath::TitleRole).toString().toLower();
+ const QString file_programmid =
child_file->data(GameListItemPath::ProgramIdRole).toString().toLower();
// Only items which filename in combination with its title contains all words