From be629fe8501941138da849cf1179ad67cd5570cb Mon Sep 17 00:00:00 2001 From: Peter Penz Date: Thu, 8 Sep 2011 18:57:52 +0200 Subject: Version control: Apply text-color if an item is versioned --- src/views/versioncontrol/updateitemstatesthread.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src/views/versioncontrol/updateitemstatesthread.cpp') diff --git a/src/views/versioncontrol/updateitemstatesthread.cpp b/src/views/versioncontrol/updateitemstatesthread.cpp index e6bd761cc..1fa3a6255 100644 --- a/src/views/versioncontrol/updateitemstatesthread.cpp +++ b/src/views/versioncontrol/updateitemstatesthread.cpp @@ -55,12 +55,8 @@ void UpdateItemStatesThread::run() Q_ASSERT(!m_itemStates.isEmpty()); Q_ASSERT(m_plugin); - // The items from m_itemStates may be located in different directory levels. The version - // plugin requires the root directory for KVersionControlPlugin::beginRetrieval(). Instead - // of doing an expensive search, we utilize the knowledge of the implementation of - // VersionControlObserver::addDirectory() to be sure that the last item contains the root. QMutexLocker itemLocker(&m_itemMutex); - const QString directory = m_itemStates.last().item.url().directory(KUrl::AppendTrailingSlash); + const QString directory = m_itemStates.first().item.url().directory(KUrl::AppendTrailingSlash); itemLocker.unlock(); QMutexLocker pluginLocker(m_globalPluginMutex); -- cgit v1.3