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

Method pathChanged

Gui/SequenceFileDialog.cpp:1707–1728  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1705}
1706
1707void
1708SequenceFileDialog::pathChanged(const QString &newPath)
1709{
1710 if ( newPath.isEmpty() ) {
1711 _upButton->setEnabled(false);
1712 } else {
1713 _upButton->setEnabled(true);
1714 }
1715
1716 _favoriteView->selectUrl( QUrl::fromLocalFile(newPath) );
1717 setHistory( _lookInCombobox->history() );
1718
1719 if ( (_currentHistoryLocation < 0) || ( _history.value(_currentHistoryLocation) != QDir::toNativeSeparators(newPath) ) ) {
1720 while ( _currentHistoryLocation >= 0 && _currentHistoryLocation + 1 < _history.count() ) {
1721 _history.removeLast();
1722 }
1723 _history.append( QDir::toNativeSeparators(newPath) );
1724 ++_currentHistoryLocation;
1725 }
1726 _nextButton->setEnabled(_history.size() - _currentHistoryLocation > 1);
1727 _previousButton->setEnabled(_currentHistoryLocation > 0);
1728}
1729
1730void
1731SequenceFileDialog::setHistory(const QStringList &paths)

Callers

nothing calls this directly

Calls 9

toNativeSeparatorsFunction · 0.85
selectUrlMethod · 0.80
appendMethod · 0.80
isEmptyMethod · 0.45
setEnabledMethod · 0.45
historyMethod · 0.45
valueMethod · 0.45
countMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected