16
0
mirror of https://github.com/MaSzyna-EU07/maszyna.git synced 2026-07-23 05:09:19 +02:00

launcher: vehicle picker filtering

This commit is contained in:
milek7
2019-09-22 20:50:35 +02:00
parent e043a39b52
commit 8dd71f1fe6
4 changed files with 111 additions and 7 deletions

View File

@@ -24,5 +24,23 @@ private:
std::array<char, 128> search_query = { 0 };
vehicles_bank bank;
struct search_info
{
enum
{
TEXT,
YEAR_MIN,
YEAR_MAX
} mode = TEXT;
bool alternative = false;
bool negation = false;
std::string text;
int number;
};
std::vector<search_info> parse_search_query(const std::string &str);
bool skin_filter(const skin_set *skin, std::vector<search_info> &info_list);
};
} // namespace ui