From 70bbb18a9444824a8ec2b9a7ff57fc848e017b6e Mon Sep 17 00:00:00 2001 From: Josh Ferrell Date: Mon, 26 Jan 2026 14:23:12 -0500 Subject: Add regex and case sensitivity options to FilterEdit --- examples/triage/entry.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'examples/triage/entry.cpp') diff --git a/examples/triage/entry.cpp b/examples/triage/entry.cpp index addb5960..dfee4a2f 100644 --- a/examples/triage/entry.cpp +++ b/examples/triage/entry.cpp @@ -141,13 +141,14 @@ void GenericEntryModel::sort(int col, Qt::SortOrder order) } -void GenericEntryModel::setFilter(const std::string& filterText) +void GenericEntryModel::setFilter(const std::string& filterText, FilterOptions options) { beginResetModel(); m_entries.clear(); + bool caseSensitive = options.testFlag(FilterOption::CaseSensitiveOption); for (auto& entry : m_allEntries) { - if (FilteredView::match(entry->GetSymbol()->GetFullName(), filterText)) + if (FilteredView::match(entry->GetSymbol()->GetFullName(), filterText, caseSensitive)) m_entries.push_back(entry); } performSort(m_sortCol, m_sortOrder); @@ -250,9 +251,9 @@ void EntryTreeView::entryDoubleClicked(const QModelIndex& cur) } -void EntryTreeView::setFilter(const std::string& filterText) +void EntryTreeView::setFilter(const std::string& filterText, FilterOptions options) { - m_model->setFilter(filterText); + m_model->setFilter(filterText, options); } -- cgit v1.3.1