┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/views/versioncontrol/updateitemstatesthread.cpp
AgeCommit message (Collapse)Author
2024-04-04versioncontrol: make observer the sole owner of pluginsMéven Car
Also properly shutdown thread.
2024-03-24versioncontrol: Prevent a use-after-free in UpdateItemStatesThreadMéven Car
UpdateItemStatesThread kept a pointer reference to m_plugin whose lifetime was tied to VersionControlObserver parents. On application shutdown it could happen the thread is still running when the Observer is destroyed. Make the plugin pointer a weak reference, allowing to stop the thread when the plugin is gone. BUG: 477425
2023-07-05Add explicit moc includes to sources for moc-covered headersFriedrich W. H. Kossebau
* speeds up incremental builds as changes to a header will not always need the full mocs_compilation.cpp for all the target's headers rebuild, while having a moc file sourced into a source file only adds minor extra costs, due to small own code and the used headers usually already covered by the source file, being for the same class/struct * seems to not slow down clean builds, due to empty mocs_compilation.cpp resulting in those quickly processed, while the minor extra cost of the sourced moc files does not outweigh that in summary. Measured times actually improved by some percent points. (ideally CMake would just skip empty mocs_compilation.cpp & its object file one day) * enables compiler to see all methods of a class in same compilation unit to do some sanity checks * potentially more inlining in general, due to more in the compilation unit * allows to keep using more forward declarations in the header, as with the moc code being sourced into the cpp file there definitions can be ensured and often are already for the needs of the normal class methods
2023-02-05Add clang-format and format code as in FrameworksSerg Podtynnyi
2020-08-25Output of licensedigger + manual cleanup afterwards.Elvis Angelaccio
Unfortunately licensedigger does not strip the trailing * characters. While at it, use a common style for all source files.
2018-03-03Remove unused #includeRoman Inflianskas
Summary: I used CLion inspection to hunt all unused #include Reviewers: #dolphin, elvisangelaccio, markg Reviewed By: #dolphin, elvisangelaccio, markg Subscribers: markg, elvisangelaccio, #dolphin Differential Revision: https://phabricator.kde.org/D10985
2017-11-21Modernize: Use nullptr everywhereKevin Funk
2015-02-25Move the KVersionControlPlugin2 interface from konqlib to Dolphin and remove ↵Emmanuel Pescosta
the deprecated KVersionControlPlugin interface from konqlib REVIEW: 122687
2014-10-15Replaced the ItemState structure with QPair<KFileItem, ↵Emmanuel Pescosta
KVersionControlPlugin2::ItemVersion>
2014-06-29Remove the automoc noiseChristophe Giboudeaux
2014-05-13Merge remote-tracking branch 'origin/master' into frameworksFrank Reininghaus
Since the master branch had never been merged into frameworks since the creation of the frameworks branch, I had to fix a couple of merge conflicts and make another change in order to make it build - I hope I did not get anything wrong. We should probably merge master into frameworks on a regular basis from now on. CCMAIL:[email protected] Conflicts: dolphin/src/dolphinmainwindow.cpp dolphin/src/search/dolphinfacetswidget.cpp dolphin/src/statusbar/dolphinstatusbar.cpp dolphin/src/views/dolphinview.cpp
2014-05-05Allow compiling Dolphin with KF5Alex Richardson
This does not work properly yet, there are probably quite a few bad signal/ slot connections due to KUrl -> QUrl. However dolphin starts without crashing. Accessibility is not ported since that changed quite a lot from Qt4 -> Qt5 and I have no idea how it is supposed to be used. This is the first commit for review 117395
2014-04-25Fix memory leak with Dropbox version control plugin.Emmanuel Pescosta
In the current version we only call endRetrieval when beginRetrieval was successfully in UpdateItemStatesThread::run(). This causes some problems with version control plugins (like Dropbox plugin), which have to do cleanups in endRetrieval. Now we always call endRetrieval after beginRetrieval when updating the version states. FIXED-IN: 4.13.1 REVIEW: 117753
2014-02-11Remove some unused functions.Emmanuel Pescosta
void KFileItemModel::slotClear(const KUrl& url) bool UpdateItemsThread::lockPlugin() <- Done with QMutexLocker void UpdateItemsThread::unlockPlugin() REVIEW: 115627
2014-01-16Remove the "retrieved items" code from UpdateItemStatesThread and ↵Emmanuel Pescosta
VersionControlObserver. Showing an error message, makes no sense in this case - the user can see it when all items are "unversioned". The plugins still have the ability to show error/warning messages on real errors. (and only where it makes sense ;) REVIEW: 114992 FIXED-IN: 4.13
2014-01-15Use the QMap iterator instead of foreach(key, map.keys()) in ↵Emmanuel Pescosta
UpdateItemStatesThread::run() and in VersionControlObserver::slotThreadFinished(). So we get O(n) complexity instead of O(n*logn), and O(1) memory instead of O(n). Thanks to Thiago Macieira for providing this information. FIXED-IN: 4.13 REVIEW: 115018
2013-09-29Show the right version states for expanded items.Emmanuel Pescosta
BUG: 267171 FIXED-IN: 4.11.3 REVIEW: 112980
2013-01-15We don't need the mutex guarding m_itemStates in theSimeon Bird
UpdateItemStatesThread, because m_itemStates is only accessed by the when the thread is done, and set before the thread starts. Also combine the setData function with the constructor.
2012-10-19Fix race condition and deadlock in the version pluginSimeon Bird
when listing directories is slow. BUG: 302264 FIXED-IN: 4.9.3
2011-09-10Provide KVersionControlPlugin version 2Peter Penz
Based on the work of Vishesh Yadav some extensions where required for the KVersionControlPlugin interface that have found there way now into KVersionControlPlugin2. Beside some interface cleanups it is now possible that a version control plugin may also provide context actions for directories or files that are not versioned yet. REVIEW: 102541
2011-09-08Version control: Apply text-color if an item is versionedPeter Penz
2011-02-09Coding style update for pointer comparisonPeter Penz
Most developers seem to prefer if (ptr) ... if (!ptr) ... in comparison to if (ptr != 0) ... if (ptr == 0) ... Adjusted the Dolphin-code to use the "most-prefered style" to make contributors happy.
2011-02-04Update e-mail address from [email protected] to [email protected]Peter Penz
2010-07-24Sourcecode hierarchy cleanup: Move folders "tooltips" and "versioncontrol" ↵Peter Penz
into "views" svn path=/trunk/KDE/kdebase/apps/; revision=1154151