Skip to content

Commit

Permalink
MatchPatternPathFilterWidget : Conf property menu
Browse files Browse the repository at this point in the history
  • Loading branch information
ericmehl committed Jun 14, 2023
1 parent de1f63f commit 0d48347
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
1 change: 1 addition & 0 deletions Changes.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ API
---

- CatalogueUI : Made ImageListing widget public so it can be customized using the API.
- MatchPatternPathFilterWidget : Made the entries in the property menu configurable.

Build
-----
Expand Down
5 changes: 4 additions & 1 deletion python/GafferUI/MatchPatternPathFilterWidget.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,12 +134,15 @@ def __updateFilterMatchPatterns( self ) :

def __propertyMenuDefinition( self ) :

## \todo Make this configurable
propertiesAndLabels = (
( "name", "Name" ),
( "fileSystem:owner", "Owner" ),
)

with IECore.IgnoredExceptions( KeyError ) :
propertyFilters = self.pathFilter().userData()["UI"]["propertyFilters"]
propertiesAndLabels = [ ( k, v.value ) for k, v in propertyFilters.items() ]

menuDefinition = IECore.MenuDefinition()
for property, label in propertiesAndLabels :
menuDefinition.append(
Expand Down

0 comments on commit 0d48347

Please sign in to comment.