mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 12:54:40 +01:00
don't skip other validations for string match
This commit is contained in:
parent
c1d7cde34d
commit
a394624974
1 changed files with 6 additions and 5 deletions
|
|
@ -351,13 +351,14 @@ class ProjectSortFilterProxy(QtCore.QSortFilterProxyModel):
|
|||
return True
|
||||
|
||||
string_pattern = self.filterRegularExpression().pattern()
|
||||
if string_pattern:
|
||||
return string_pattern.lower() in project_name.lower()
|
||||
if (
|
||||
string_pattern
|
||||
and string_pattern.lower() not in project_name.lower()
|
||||
):
|
||||
return False
|
||||
|
||||
# Current project keep always visible
|
||||
default = super(ProjectSortFilterProxy, self).filterAcceptsRow(
|
||||
source_row, source_parent
|
||||
)
|
||||
default = super().filterAcceptsRow(source_row, source_parent)
|
||||
if not default:
|
||||
return default
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue