D15929: Add a 'Properties' entry in the Places panel context menu

Anthony Fieroni noreply at phabricator.kde.org
Fri Oct 5 08:38:46 BST 2018


anthonyfieroni added inline comments.

INLINE COMMENTS

> placesitemmodel.cpp:65
> +    m_sourceModel(DolphinPlacesModelSingleton::instance().placesModel()),
> +    m_parent(parent)
>  {

Not needed

> placesitemmodel.cpp:313
> +
> +        if (drive->driveType() != Solid::StorageDrive::HardDisk) {
> +            return nullptr;

Check for device against nullptr again.

> placesitemmodel.cpp:338
> +    if (item->udi().isEmpty()) {
> +        dialog = new KPropertiesDialog(item->url(), (QWidget *)m_parent);
> +    } else {

Don't use parent when it is not needed, Qt::WA_DeleteOnClose is fair enough.

> placesitemmodel.cpp:342
> +        Solid::StorageAccess* access = device.as<Solid::StorageAccess>();
> +        dialog = new KPropertiesDialog(QUrl("file://" + access->filePath()), (QWidget *)m_parent);
> +    }

Same as above.

> placesitemmodel.h:237
> +
> +    QObject* m_parent;
>  };

Not needed.

> placespanel.cpp:176
>      const bool isTrash = (item->url().scheme() == QLatin1String("trash"));
> +
>      if (isDevice) {

Remove unrelated changes.

> placespanel.cpp:217
> +        }
> +
> +    }

Remove white-space line

REPOSITORY
  R318 Dolphin

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

To: thsurrel, #dolphin, #plasma, #vdg
Cc: anthonyfieroni, elvisangelaccio, cfeck, ngraham, abetts, kfm-devel, feverfew, spoorun, navarromorales, firef, andrebarros, emmanuelp
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.kde.org/mailman/private/kfm-devel/attachments/20181005/5a13e831/attachment.htm>


More information about the kfm-devel mailing list