MCPcopy Create free account
hub / github.com/KDE/kdevelop / scheduleDelayedBranchChanged

Method scheduleDelayedBranchChanged

plugins/git/gitplugin.cpp:1876–1889  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1874}
1875
1876void GitPlugin::WatchedFile::scheduleDelayedBranchChanged(const GitPlugin* plugin)
1877{
1878 Q_ASSERT(plugin);
1879
1880 if (!m_timer) {
1881 m_timer.reset(new QTimer);
1882 m_timer->setSingleShot(true);
1883 m_timer->setInterval(1000);
1884 m_timer->callOnTimeout(plugin, &GitPlugin::delayedBranchChanged);
1885 }
1886 // During a git rebase, multiple changes to the HEAD file can occur within the timer interval.
1887 // Restart the timer and emit the signal once in the end to avoid freezing the KDevelop UI.
1888 m_timer->start();
1889}
1890
1891auto GitPlugin::findWatchedFile(const QString& filePath) -> std::vector<WatchedFileAndListeners>::iterator
1892{

Callers 1

fileChangedMethod · 0.80

Calls 2

resetMethod · 0.45
startMethod · 0.45

Tested by

no test coverage detected