aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTed Gould <ted@canonical.com>2009-08-19 21:49:55 -0500
committerTed Gould <ted@canonical.com>2009-08-19 21:49:55 -0500
commitb8adb87bc06248378bc0d72a53c21d566a31e2b4 (patch)
treef7bfd8424e80460a39f65aada8e5198d82d7e934 /src
parentcfb0854e7c6bfa7cc9ac5ffdcd6672ad812ecfa0 (diff)
downloadayatana-indicator-messages-b8adb87bc06248378bc0d72a53c21d566a31e2b4.tar.gz
ayatana-indicator-messages-b8adb87bc06248378bc0d72a53c21d566a31e2b4.tar.bz2
ayatana-indicator-messages-b8adb87bc06248378bc0d72a53c21d566a31e2b4.zip
Adding in a couple function to deal with disappearing launchers.
Diffstat (limited to 'src')
-rw-r--r--src/messages-service.c26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/messages-service.c b/src/messages-service.c
index 3f2974e..c3b3db9 100644
--- a/src/messages-service.c
+++ b/src/messages-service.c
@@ -46,6 +46,8 @@ static void server_name_changed (AppMenuItem * appitem, gchar * name, gpointer d
static void im_time_changed (ImMenuItem * imitem, glong seconds, gpointer data);
static void resort_menu (DbusmenuMenuitem * menushell);
static void indicator_removed (IndicateListener * listener, IndicateListenerServer * server, IndicateListenerIndicator * indicator, gchar * type, gpointer data);
+static void check_eclipses (AppMenuItem * ai);
+static void remove_eclipses (AppMenuItem * ai);
typedef struct _serverList_t serverList_t;
struct _serverList_t {
@@ -194,6 +196,7 @@ static void
server_name_changed (AppMenuItem * appitem, gchar * name, gpointer data)
{
serverList = g_list_sort(serverList, serverList_sort);
+ check_eclipses(appitem);
resort_menu(DBUSMENU_MENUITEM(data));
return;
}
@@ -268,6 +271,8 @@ server_removed (IndicateListener * listener, IndicateListenerServer * server, gc
serverList_t * sltp = (serverList_t *)lookup->data;
+ remove_eclipses(sltp->menuitem);
+
while (sltp->imList) {
imList_t * imitem = (imList_t *)sltp->imList->data;
indicator_removed(listener, server, imitem->indicator, "message", data);
@@ -514,6 +519,27 @@ indicator_removed (IndicateListener * listener, IndicateListenerServer * server,
return;
}
+/* Check to see if a new desktop file causes
+ any of the launchers to be eclipsed by a running
+ process */
+static void
+check_eclipses (AppMenuItem * ai)
+{
+
+
+ return;
+}
+
+/* Remove any eclipses that might have been caused
+ by this app item that is now retiring */
+static void
+remove_eclipses (AppMenuItem * ai)
+{
+
+
+ return;
+}
+
gboolean
build_launcher (gpointer data)
{