Comment 5 for bug 715611

Revision history for this message
Andrea Grandi (andreagrandi) wrote :

It's quite easy to implement (at least in Qt :P ).

We should use the QFileSystemWatcher class and call the method "addPath" passing the ~/.Trash/ folder as parameter.
Each time we delete file and they go to the trash or if we empty the trash, the "directoryChanged" signal is called.
When signal is called we simply check: if the directory is empty then we use the empty icon, else we use the full trash icon.

I would be glad to implement it, but I really don't know where it would fit in the whole unity-2d code. Any idea?

p.s: Better to keep discussing development details here or do you prefer if I do it on #ayatana@Freenode ?