Review Request 112023: Disable move/copy actions for non-writeable UMS collections.
Frank Meerkoetter
frank at meerkoetter.org
Sat Aug 17 10:02:57 UTC 2013
> On Aug. 12, 2013, 4:57 p.m., Matěj Laitl wrote:
> > src/core/collections/Collection.h, lines 125-135
> > <http://git.reviewboard.kde.org/r/112023/diff/1/?file=178093#file178093line125>
> >
> > Hmm, I don't like the combination of 2 bools to signify 3 possible values (because you introduce one invalid combination).
> >
> > What about making it:
> > Enum WritableType {
> > Writable,
> > TemporarilyNotWritable,
> > NotWritable // permanently
> > }
> > WritableType writableType() const;
>
> Frank Meerkoetter wrote:
> Sure, i'll update the patch
I have a question about your proposal.
Your intention is to replace isWriteable() and isWriteableType() with writeableType() which returns an enum?
- Frank
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/112023/#review37599
-----------------------------------------------------------
On Aug. 11, 2013, 8:08 p.m., Frank Meerkoetter wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/112023/
> -----------------------------------------------------------
>
> (Updated Aug. 11, 2013, 8:08 p.m.)
>
>
> Review request for Amarok.
>
>
> Description
> -------
>
> The fix in https://git.reviewboard.kde.org/r/111991/ fixes isWriteable() for UMS collections. This has the effect that if an UMS-collection is actually non-writeable the copy/move operations will be missing from the TreeView/Filebrowser context menus. There is no clue to the user what is going on.
>
> This patch is introducing a new method to the Collection interface so we can differentiate between collections that are non-writeable by principle and collections that just happen to be non-writeable right now (for what ever reason).
>
> I use this changed collection interface to disable move/copy actions (as opposed to hide) for non-writeable UMS-colllections. This should give the user at least a hint what is going on.
>
> Unfortunately i haven't found a way to display a tooltip ("Currently readonly"). The action is offering an setTooltip() method but now effect was observed.
>
>
> Diffs
> -----
>
> src/browsers/CollectionTreeView.cpp 7e93c9a
> src/browsers/filebrowser/FileView.cpp ad200eb
> src/core-impl/collections/umscollection/UmsCollection.h 749ff81
> src/core-impl/collections/umscollection/UmsCollection.cpp 028966e
> src/core/collections/Collection.h 94d24d7
> src/core/collections/Collection.cpp 01a2e8c
>
> Diff: http://git.reviewboard.kde.org/r/112023/diff/
>
>
> Testing
> -------
>
> I have tested with an USB-stick that is writeable and another one that is non-writeable. I have also observed that for the FileBrowser the "Local collection" is still shown as active.
>
>
>
> Thanks,
>
> Frank Meerkoetter
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/amarok-devel/attachments/20130817/91570a1f/attachment.html>
More information about the Amarok-devel
mailing list