summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Lioncash2018-07-18 16:52:12 -0400
committerGravatar Lioncash2018-07-18 16:52:14 -0400
commitd17e172d924417517c75085f1c2b20d4dedd7670 (patch)
treeb4552adf9a44deb150b400ac7d85febbbed3520c
parentMerge pull request #681 from lioncash/const (diff)
downloadyuzu-d17e172d924417517c75085f1c2b20d4dedd7670.tar.gz
yuzu-d17e172d924417517c75085f1c2b20d4dedd7670.tar.xz
yuzu-d17e172d924417517c75085f1c2b20d4dedd7670.zip
game_list: Make ContainsAllWords an internally linked non-member function
This function actually depends on no internal class state, so it doesn't even need to be a part of the class interface.
Diffstat (limited to '')
-rw-r--r--src/yuzu/game_list.cpp2
-rw-r--r--src/yuzu/game_list.h1
2 files changed, 1 insertions, 2 deletions
diff --git a/src/yuzu/game_list.cpp b/src/yuzu/game_list.cpp
index 5f43eb177..31d997353 100644
--- a/src/yuzu/game_list.cpp
+++ b/src/yuzu/game_list.cpp
@@ -138,7 +138,7 @@ GameList::SearchField::SearchField(GameList* parent) : QWidget{parent} {
138 * @param userinput String containing all words getting checked 138 * @param userinput String containing all words getting checked
139 * @return true if the haystack contains all words of userinput 139 * @return true if the haystack contains all words of userinput
140 */ 140 */
141bool GameList::ContainsAllWords(const QString& haystack, const QString& userinput) const { 141static bool ContainsAllWords(const QString& haystack, const QString& userinput) {
142 const QStringList userinput_split = 142 const QStringList userinput_split =
143 userinput.split(' ', QString::SplitBehavior::SkipEmptyParts); 143 userinput.split(' ', QString::SplitBehavior::SkipEmptyParts);
144 144
diff --git a/src/yuzu/game_list.h b/src/yuzu/game_list.h
index 14db3956d..3bc14f07f 100644
--- a/src/yuzu/game_list.h
+++ b/src/yuzu/game_list.h
@@ -89,7 +89,6 @@ private:
89 89
90 void PopupContextMenu(const QPoint& menu_location); 90 void PopupContextMenu(const QPoint& menu_location);
91 void RefreshGameDirectory(); 91 void RefreshGameDirectory();
92 bool ContainsAllWords(const QString& haystack, const QString& userinput) const;
93 92
94 SearchField* search_field; 93 SearchField* search_field;
95 GMainWindow* main_window = nullptr; 94 GMainWindow* main_window = nullptr;