Skip to content

Commit

Permalink
Merge pull request #5671 from murraystevenson/pathListingWidgetDragNo…
Browse files Browse the repository at this point in the history
…neFix

PathListingWidget : Do not change pointer when dragging a value of `None`
  • Loading branch information
johnhaddon authored Feb 15, 2024
2 parents c5a25c6 + d64e5e6 commit c685e16
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions Changes.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ Fixes
- PythonCommand : Fixed misleading results for `repr( variables )` and `str( variables )`, which would suggest the dictionary was empty when it was not.
- CompoundObject : Fixed crashes in Python bindings caused by passing `None` as a key.
- Windows : Fixed "{path} was unexpected at this time." startup error when environment variables such as `PATH` contain `"` characters.
- PathListingWidget : Fixed bug which caused the pointer to be stuck displaying the "values" icon after dragging cells with no value.

Build
-----
Expand Down
6 changes: 4 additions & 2 deletions python/GafferUI/PathListingWidget.py
Original file line number Diff line number Diff line change
Expand Up @@ -734,9 +734,11 @@ def __dragBegin( self, widget, event ) :

index = self.__indexAt( event.line.p0 )
if index is not None :
GafferUI.Pointer.setCurrent( "values" )
value = self.getColumns()[index.column()].cellData( path ).value
if value is not None :
GafferUI.Pointer.setCurrent( "values" )

return self.getColumns()[index.column()].cellData( path ).value
return value

return None

Expand Down

0 comments on commit c685e16

Please sign in to comment.