summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar bunnei2018-08-06 22:00:49 -0400
committerGravatar GitHub2018-08-06 22:00:49 -0400
commite218d79cc2d60468b42a56c4d76b4339ac8efd90 (patch)
tree1b2553d2f0fd85dedf0483648223a7eb5439f7c9 /src
parentMerge pull request #946 from lioncash/compress (diff)
parentgame_list: Join declarations and assignments in onTextChanged() (diff)
downloadyuzu-e218d79cc2d60468b42a56c4d76b4339ac8efd90.tar.gz
yuzu-e218d79cc2d60468b42a56c4d76b4339ac8efd90.tar.xz
yuzu-e218d79cc2d60468b42a56c4d76b4339ac8efd90.zip
Merge pull request #943 from lioncash/decl
game_list: Join declarations and assignments in onTextChanged()
Diffstat (limited to 'src')
-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) {
162 } 162 }
163 search_field->setFilterResult(rowCount, rowCount); 163 search_field->setFilterResult(rowCount, rowCount);
164 } else { 164 } else {
165 QStandardItem* child_file;
166 QString file_path, file_name, file_title, file_programmid;
167 int result_count = 0; 165 int result_count = 0;
168 for (int i = 0; i < rowCount; ++i) { 166 for (int i = 0; i < rowCount; ++i) {
169 child_file = item_model->item(i, 0); 167 const QStandardItem* child_file = item_model->item(i, 0);
170 file_path = child_file->data(GameListItemPath::FullPathRole).toString().toLower(); 168 const QString file_path =
171 file_name = file_path.mid(file_path.lastIndexOf("/") + 1); 169 child_file->data(GameListItemPath::FullPathRole).toString().toLower();
172 file_title = child_file->data(GameListItemPath::TitleRole).toString().toLower(); 170 QString file_name = file_path.mid(file_path.lastIndexOf('/') + 1);
173 file_programmid = 171 const QString file_title =
172 child_file->data(GameListItemPath::TitleRole).toString().toLower();
173 const QString file_programmid =
174 child_file->data(GameListItemPath::ProgramIdRole).toString().toLower(); 174 child_file->data(GameListItemPath::ProgramIdRole).toString().toLower();
175 175
176 // Only items which filename in combination with its title contains all words 176 // Only items which filename in combination with its title contains all words