MCPcopy Create free account
hub / github.com/MrKepzie/Natron / triggerAutoSave

Method triggerAutoSave

Engine/Project.cpp:621–643  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

619}
620
621void
622Project::triggerAutoSave()
623{
624 ///Should only be called in the main-thread, that is upon user interaction.
625 assert( QThread::currentThread() == qApp->thread() );
626
627 if ( getApp()->isBackground() || !appPTR->isLoaded() || isProjectClosing() ) {
628 return;
629 }
630
631 if ( !hasProjectBeenSavedByUser() && !appPTR->getCurrentSettings()->isAutoSaveEnabledForUnsavedProjects() ) {
632 return;
633 }
634
635 {
636 QMutexLocker l(&_imp->isLoadingProjectMutex);
637 if (_imp->isLoadingProject) {
638 return;
639 }
640 }
641
642 _imp->autoSaveTimer->start( appPTR->getCurrentSettings()->getAutoSaveDelayMS() );
643}
644
645void
646Project::onAutoSaveTimerTriggered()

Callers 15

onOverlayPenUpMethod · 0.45
onOverlayKeyUpMethod · 0.45
undoMethod · 0.45
redoMethod · 0.45
evaluateMethod · 0.45
autoSaveAndRedrawMethod · 0.45
newHistogramHereMethod · 0.45
closeTabMethod · 0.45
splitInternalMethod · 0.45
moveTabMethod · 0.45
RemoveNodeCommandClass · 0.45

Calls 7

getAppFunction · 0.85
isLoadedMethod · 0.80
getCurrentSettingsMethod · 0.80
startMethod · 0.80
getAutoSaveDelayMSMethod · 0.80
isBackgroundMethod · 0.45

Tested by

no test coverage detected