diff options
author | Ted Gould <ted@canonical.com> | 2009-08-19 22:42:15 -0500 |
---|---|---|
committer | Ted Gould <ted@canonical.com> | 2009-08-19 22:42:15 -0500 |
commit | db8ada09e2f254026f318b38cd45ae1cd765f584 (patch) | |
tree | dc71d63ab5f4315faf986115d0b6792a3e09b763 | |
parent | 17745461f669047872c12a6c7db7b05a9ccb0417 (diff) | |
download | ayatana-indicator-messages-db8ada09e2f254026f318b38cd45ae1cd765f584.tar.gz ayatana-indicator-messages-db8ada09e2f254026f318b38cd45ae1cd765f584.tar.bz2 ayatana-indicator-messages-db8ada09e2f254026f318b38cd45ae1cd765f584.zip |
Ah, where casting kills. You can cast anything to the right value even though it's not. Nice opaque errors you get for that.
-rw-r--r-- | src/messages-service.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/messages-service.c b/src/messages-service.c index f8f1aaf..395bf32 100644 --- a/src/messages-service.c +++ b/src/messages-service.c @@ -532,10 +532,11 @@ check_eclipses (AppMenuItem * ai) GList * llitem; for (llitem = launcherList; llitem != NULL; llitem = llitem->next) { - const gchar * lidesktop = launcher_menu_item_get_desktop(LAUNCHER_MENU_ITEM(llitem->data)); + launcherList_t * ll = (launcherList_t *)llitem->data; + const gchar * lidesktop = launcher_menu_item_get_desktop(ll->menuitem); if (!g_strcmp0(aidesktop, lidesktop)) { - launcher_menu_item_set_eclipsed(LAUNCHER_MENU_ITEM(llitem->data), TRUE); + launcher_menu_item_set_eclipsed(ll->menuitem, TRUE); break; } } @@ -553,10 +554,11 @@ remove_eclipses (AppMenuItem * ai) GList * llitem; for (llitem = launcherList; llitem != NULL; llitem = llitem->next) { - const gchar * lidesktop = launcher_menu_item_get_desktop(LAUNCHER_MENU_ITEM(llitem->data)); + launcherList_t * ll = (launcherList_t *)llitem->data; + const gchar * lidesktop = launcher_menu_item_get_desktop(ll->menuitem); if (!g_strcmp0(aidesktop, lidesktop)) { - launcher_menu_item_set_eclipsed(LAUNCHER_MENU_ITEM(llitem->data), FALSE); + launcher_menu_item_set_eclipsed(ll->menuitem, FALSE); break; } } |