MCPcopy Create free account
hub / github.com/NatronGitHub/Natron / onOpenFileButtonClicked

Method onOpenFileButtonClicked

Gui/KnobGuiFile.cpp:824–842  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

822}
823
824void
825KnobGuiPath::onOpenFileButtonClicked()
826{
827 std::vector<std::string> filters;
828 SequenceFileDialog dialog( _mainContainer, filters, false, SequenceFileDialog::eFileDialogModeDir, _lastOpened.toStdString(), getGui(), true );
829
830 if ( dialog.exec() ) {
831 std::string dirPath = dialog.selectedDirectory();
832 updateLastOpened( QString::fromUtf8( dirPath.c_str() ) );
833
834 KnobPathPtr knob = _knob.lock();
835 if (!knob) {
836 return;
837 }
838 std::string oldValue = knob->getValue();
839
840 pushUndoCommand( new KnobUndoCommand<std::string>( shared_from_this(), oldValue, dirPath ) );
841 }
842}
843
844bool
845KnobGuiPath::addNewUserEntry(QStringList& row)

Callers

nothing calls this directly

Calls 7

getGuiFunction · 0.85
pushUndoCommandFunction · 0.85
toStdStringMethod · 0.80
selectedDirectoryMethod · 0.80
execMethod · 0.45
lockMethod · 0.45
getValueMethod · 0.45

Tested by

no test coverage detected