#NEWLINE# def __exportForReferencing( menu , node ) : #NEWLINE# #INDENT# bookmarks = GafferUI . Bookmarks . acquire ( node , category = 'reference' ) #NEWLINE# path = Gaffer . FileSystemPath ( bookmarks . getDefault ( menu ) ) #NEWLINE# path . setFilter ( Gaffer . FileSystemPath . createStandardFilter ( [ 'grf' ] ) ) #NEWLINE# dialogue = GafferUI . PathChooserDialogue ( path , title = 'Export for referencing' , confirmLabel = 'Export' , leaf = True , bookmarks = bookmarks ) #NEWLINE# path = dialogue . waitForPath ( parentWindow = menu . ancestor ( GafferUI . Window ) ) #NEWLINE# if ( not path ) : #NEWLINE# #INDENT# return #NEWLINE# #UNINDENT# path = str ( node ) #NEWLINE# if ( not path . endswith ( '.grf' ) ) : #NEWLINE# #INDENT# path += '.grf' #NEWLINE# #UNINDENT# node . exportForReference ( path )