Probably this related to gnome theme or russian language or both.
In libnautilus-private/nautilus-trash-monitor.c:238 in update_info_cb there is following code:
empty = TRUE;
if (G_IS_THEMED_ICON (icon)) { names = g_themed_icon_get_names (G_THEMED_ICON (icon)); for (i = 0; names[i] != NULL; i++) { if (strcmp (names[i], NAUTILUS_ICON_TRASH_FULL) == 0) { empty = FALSE; break; } }
}
if (trash_monitor->details->empty != empty) {
/* Change emptyness status and notify
via signal everyone who cares. */
}
I wonder why this code checks trashcan icon to see if the trash is full. Isn't there some trashcan API?!
Let's look into code which works: trashapplet from gnome-applets. Yes there is such API, g_file_query_info(GFileInfo.G_FILE_ATTRIBUTE_TRASH_ITEM_COUNT):
info = g_file_query_info (applet->trash, G_FILE_ATTRIBUTE_STANDARD_ICON"," G_FILE_ATTRIBUTE_TRASH_ITEM_COUNT, 0, NULL, &error);
Probably this related to gnome theme or russian language or both. private/ nautilus- trash-monitor. c:238 in update_info_cb there is following code:
In libnautilus-
empty = TRUE;
names = g_themed_ icon_get_ names (G_THEMED_ICON (icon));
for (i = 0; names[i] != NULL; i++) {
if (strcmp (names[i], NAUTILUS_ ICON_TRASH_ FULL) == 0) {
empty = FALSE;
break;
}
} monitor- >details- >empty != empty) {
if (G_IS_THEMED_ICON (icon)) {
}
if (trash_
/* Change emptyness status and notify
via signal everyone who cares. */
}
I wonder why this code checks trashcan icon to see if the trash is full. Isn't there some trashcan API?!
Let's look into code which works: trashapplet from gnome-applets. Yes there is such API, g_file_ query_info( GFileInfo. G_FILE_ ATTRIBUTE_ TRASH_ITEM_ COUNT):
info = g_file_query_info (applet->trash,
G_FILE_ ATTRIBUTE_ STANDARD_ ICON","
G_FILE_ ATTRIBUTE_ TRASH_ITEM_ COUNT,
0, NULL, &error);
icon = g_file_ info_get_ icon (info); info_get_ attribute_ uint32 (info,
G_FILE_ ATTRIBUTE_ TRASH_ITEM_ COUNT);
items = g_file_
if (items != applet->items) {
/* Update UI here. */
}