Commit 15bed4b1 authored by Jiri (George) Lebl's avatar Jiri (George) Lebl Committed by George Lebl

implemented abort_applet_id corba call.

Mon Mar 16 17:56:08 1998  George Lebl  <jirka@5z.com>

        * panel.c,mico-glue.cc: implemented abort_applet_id
          corba call.
parent 85111f65
Mon Mar 16 17:56:08 1998 George Lebl <jirka@5z.com>
* panel.c,mico-glue.cc: implemented abort_applet_id
corba call.
Mon Mar 16 17:26:03 1998 George Lebl <jirka@5z.com>
* launcher.c: a few fixes, dumped the params field
......
Mon Mar 16 17:56:08 1998 George Lebl <jirka@5z.com>
* panel.c,mico-glue.cc: implemented abort_applet_id
corba call.
Mon Mar 16 17:26:03 1998 George Lebl <jirka@5z.com>
* launcher.c: a few fixes, dumped the params field
......
......@@ -41,7 +41,7 @@ public:
return id;
}
void applet_abort_id (CORBA::Short id) {
/*FIXME: implement, kill of that EXTERN_PENDING*/
::applet_abort_id (id);
}
void applet_request_glob_cfg (char *&globcfgpath) {
char *globcfg=NULL;
......
......@@ -379,16 +379,12 @@ move_applet_callback(GtkWidget *widget, gpointer data)
panel_widget_applet_drag_start(panel,info->widget);
}
static void
remove_applet_callback(GtkWidget *widget, gpointer data)
panel_clean_applet(AppletInfo *info)
{
AppletInfo *info;
gchar *id;
gint pos;
PanelWidget *panel;
info = data;
g_return_if_fail(info != NULL);
if(info->type == APPLET_EXTERN)
send_applet_shutdown_applet(info->id,info->applet_id);
......@@ -399,19 +395,28 @@ remove_applet_callback(GtkWidget *widget, gpointer data)
panel_widget_remove(panel,info->widget);
gtk_widget_unref(info->widget);
info->widget = NULL;
/* this should be handeled by the applet itself (hopefully)
if(info->assoc)
gtk_widget_unref(info->assoc);
*/
if(info->menu)
gtk_widget_unref(info->menu);
info->menu = NULL;
g_free(info->id);
if(info->id) g_free(info->id);
info->id=NULL;
if(info->params) g_free(info->params);
info->params=NULL;
}
static void
remove_applet_callback(GtkWidget *widget, gpointer data)
{
AppletInfo *info = data;
panel_clean_applet(info);
}
static void
applet_callback_callback(GtkWidget *widget, gpointer data)
{
......@@ -614,6 +619,21 @@ applet_get_panel(int id)
return -1;
}
void
applet_abort_id(int id)
{
AppletInfo *info = get_applet_by_id(id);
/*only reserved spots can be canceled, if an applet
wants to chance a pending applet it needs to first
user reserve spot to obtain id and make it EXTERN_RESERVED*/
if(info->type != APPLET_EXTERN_RESERVED)
return;
panel_clean_applet(info);
}
int
applet_get_pos(int id)
{
......
......@@ -6,9 +6,6 @@
BEGIN_GNOME_DECLS
#define MENU_ID "Menu"
/*FIXME: maybe add a temporary launcher but these will be provided by the
filemanager*/
/*#define LAUNCHER_ID "Launcher"*/
#define DRAWER_ID "Drawer"
#define LOGOUT_ID "Logout"
#define EXTERN_ID "Extern"
......@@ -101,14 +98,14 @@ void panel_quit(void);
void apply_global_config(void);
/*stuff for corba*/
void reparent_window_id (unsigned long winid, int id);
int applet_request_id (const char * ior, const char *path, char **cfgpath,
char **globcfgpath);
void applet_request_glob_cfg (char **globcfgpath);
void reserve_applet_spot (const char *id, const char *path, int panel,
int pos, char *cfgpath, AppletType type);
/*stuff for corba*/
void applet_abort_id(int id);
int applet_get_panel(int id);
int applet_get_pos(int id);
void applet_show_menu(int id);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment