D25732: Add only canonical paths to dirWatcher

Elvis Angelaccio noreply at phabricator.kde.org
Mon Jan 6 15:36:45 GMT 2020


elvisangelaccio requested changes to this revision.
elvisangelaccio added a comment.
This revision now requires changes to proceed.


  Just minor nitpicks, looks good otherwise.

INLINE COMMENTS

> kdirectorycontentscounter.cpp:89
>  {
> -    if (!m_dirWatcher->contains(path)) {
> -        m_dirWatcher->addDir(path);
> -        m_watchedDirs.insert(path);
> +    QString resolved = QFileInfo(path).canonicalFilePath();
> +

Missing `const`. I'd also call this variable `resolvedPath` or `canonicalPath`.

> kdirectorycontentscounter.cpp:113
>  
> -    if (!m_dirWatcher->contains(path)) {
> -        m_dirWatcher->addDir(path);
> -        m_watchedDirs.insert(path);
> +    QString resolved = QFileInfo(path).canonicalFilePath();
> +

Same here

REPOSITORY
  R318 Dolphin

REVISION DETAIL
  https://phabricator.kde.org/D25732

To: hoffmannrobert, dfaure, #dolphin, elvisangelaccio
Cc: elvisangelaccio, kfm-devel, pberestov, iasensio, fprice, MrPepe, fbampaloukas, alexde, Codezela, feverfew, meven, spoorun, navarromorales, firef, ngraham, andrebarros, emmanuelp, mikesomov
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.kde.org/mailman/private/kfm-devel/attachments/20200106/cef70ce4/attachment.htm>


More information about the kfm-devel mailing list