Reflect trash state in iconNameForUrl
ClosedPublic

Authored by broulik on Mar 27 2017, 4:54 PM.

Details

Summary

When doing iconNameForUrl("trash:/") reflect the state of the trash (full or empty)

Test Plan

Did KIO::iconNameForUrl("trash:/") with empty trash, it was "user-trash", then I trashed a file and it returned "user-trash-full", see also D5198

Diff Detail

Repository
R241 KIO
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
broulik created this revision.Mar 27 2017, 4:54 PM
Restricted Application added a project: Frameworks. · View Herald TranscriptMar 27 2017, 4:54 PM
Restricted Application added a subscriber: Frameworks. · View Herald Transcript
bshah accepted this revision.Mar 27 2017, 4:55 PM
This revision is now accepted and ready to land.Mar 27 2017, 4:55 PM
bshah added a comment.Mar 27 2017, 4:56 PM

Err.. sorry.. accepted wrong revision. Looks good but ignore me

bshah resigned from this revision.Mar 27 2017, 4:57 PM
This revision now requires review to proceed.Mar 27 2017, 4:57 PM
markg added a subscriber: markg.Mar 27 2017, 5:08 PM

Hmm, i don't know about the performance penalty you get when using KConfig...
It "looks" ok, but that's without knowing the above.

+1, ship it is for someone else.

dfaure accepted this revision.Mar 27 2017, 5:10 PM

Yep it means parsing a file, but that file is exactly 2 lines long and this is only done when asking about trash:/ so I think it's fine.

This revision is now accepted and ready to land.Mar 27 2017, 5:10 PM
This revision was automatically updated to reflect the committed changes.