Closed Bug 666234 Opened 13 years ago Closed 6 years ago

Trash icon is different from the one in the file manager

Categories

(Thunderbird :: Theme, defect)

All
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INVALID

People

(Reporter: andreasn, Unassigned)

References

Details

Currently we ship our own trash icon. This trash icon is different than the one shipped by the system (like seen in Nautilus for example). One of the reasons we do this is because we can't expect a trash icon from GTK+, and that is one of our dependencies. However, most (all?) modern distros that ship with either GNOME or KDE also ship with an icon theme following the icon-naming-specification [1].
Can we take advantage of this?

1. http://standards.freedesktop.org/icon-naming-spec/icon-naming-spec-latest.html
Blocks: 665873
We don't use our own trash icon, we are using 'gtk-delete'. Nautilus is using 'user-trash-full'.

Should we switch to 'user-trash-full'?
I think we need to figure out if it's possible to use some kind of fallback system. If the system is a proper GNOME or KDE system, then use user-trash-full, if it's some other kind of odd desktop, or not really a desktop at all, fall back to the GTK+ name. Not quite sure how to do this yet though.
so I tried to do something like

treechildren::-moz-tree-image(folderNameCol, specialFolder-Trash) {
  list-style-image: url("chrome://messenger/skin/icons/folder-pane.png");
  -moz-image-region: rect(176px 16px 192px 0px) !important;
  list-style-image: url("moz-icon://stock/user-trash?size=menu");
}

in the naive thought that if user-trash wasn't found, it would use the list-style-image previosly declared, but that ended up blank instead...
Some kind of background-image also feels like a dead end.
This is because of the -moz-image-region: rect(176px 16px 192px 0px) !important;
You have to add a -moz-image-region: auto !important; after the list-style-image: url("moz-icon://stock/user-trash?size=menu");

But this is useless because the second definition will be always used also when the icon isn't found.

I don't know of a function for a if exists, then use foo, else use bar in CSS.
Resolving as invalid because we use our own monochrome icons and don't want to use the system icons.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.