# HG changeset patch # User Eric Warmenhoven # Date 980251701 0 # Node ID 9be6790092dcd521043365c90525651e0747b720 # Parent b37ed5eb0317a7764aeea02c04eac0ed74e3ded2 [gaim-migrate @ 1430] backing out the change mishan sent in. it's not working right for me for some reason and i don't feel like trying to figure out why right now. committer: Tailor Script diff -r b37ed5eb0317 -r 9be6790092dc src/applet.c --- a/src/applet.c Sun Jan 21 02:55:14 2001 +0000 +++ b/src/applet.c Tue Jan 23 12:08:21 2001 +0000 @@ -244,7 +244,7 @@ GNOME_Panel_OrientType orient = applet_widget_get_panel_orient( APPLET_WIDGET(applet) ); pad = 5; - gdk_window_get_root_origin(gtk_widget_get_parent_window(appletframe), &x, &y); + gdk_window_get_position(gtk_widget_get_parent_window(appletframe), &x, &y); if (for_blist) { if (general_options & OPT_GEN_SAVED_WINDOWS) { buddy_req.width = blist_pos.width; @@ -286,7 +286,7 @@ if (general_options & OPT_GEN_NEAR_APPLET) gtk_widget_set_uposition ( blist, al.x, al.y ); else if (general_options & OPT_GEN_SAVED_WINDOWS) - gtk_widget_set_uposition(blist, blist_pos.x, blist_pos.y); + gtk_widget_set_uposition(blist, blist_pos.x - blist_pos.xoff, blist_pos.y - blist_pos.yoff); } void AppletClicked( GtkWidget *sender, GdkEventButton *ev, gpointer data ){ diff -r b37ed5eb0317 -r 9be6790092dc src/buddy.c --- a/src/buddy.c Sun Jan 21 02:55:14 2001 +0000 +++ b/src/buddy.c Tue Jan 23 12:08:21 2001 +0000 @@ -2016,7 +2016,7 @@ { int x, y, width, height; int save = 0; - gdk_window_get_root_origin(blist->window, &x, &y); + gdk_window_get_position(blist->window, &x, &y); gdk_window_get_size(blist->window, &width, &height); if(e->send_event) { /* Is a position event */ @@ -2025,10 +2025,13 @@ blist_pos.x = x; blist_pos.y = y; } else { /* Is a size event */ - if (blist_pos.width != width || blist_pos.width != width) + if (blist_pos.xoff != x || blist_pos.yoff != y || blist_pos.width != width) save = 1; + blist_pos.width = width; blist_pos.height = height; + blist_pos.xoff = x; + blist_pos.yoff = y; } if (save) @@ -2458,7 +2461,8 @@ if (general_options & OPT_GEN_SAVED_WINDOWS) { if (blist_pos.width != 0) { /* Sanity check! */ - gtk_widget_set_uposition(blist, blist_pos.x, blist_pos.y); + gtk_widget_set_uposition(blist, blist_pos.x - blist_pos.xoff, + blist_pos.y - blist_pos.yoff); gtk_widget_set_usize(blist, blist_pos.width, blist_pos.height); } } diff -r b37ed5eb0317 -r 9be6790092dc src/gaim.h --- a/src/gaim.h Sun Jan 21 02:55:14 2001 +0000 +++ b/src/gaim.h Tue Jan 23 12:08:21 2001 +0000 @@ -148,6 +148,8 @@ int y; int width; int height; + int xoff; + int yoff; }; diff -r b37ed5eb0317 -r 9be6790092dc src/gaimrc.c --- a/src/gaimrc.c Sun Jan 21 02:55:14 2001 +0000 +++ b/src/gaimrc.c Tue Jan 23 12:08:21 2001 +0000 @@ -652,6 +652,8 @@ blist_pos.y = atoi(p->value[1]); blist_pos.width = atoi(p->value[2]); blist_pos.height = atoi(p->value[3]); + blist_pos.xoff = atoi(p->value[4]); + blist_pos.yoff = atoi(p->value[5]); } } @@ -673,8 +675,9 @@ fprintf(f, "\treport_idle { %d }\n", report_idle); fprintf(f, "\tweb_browser { %d }\n", web_browser); fprintf(f, "\tweb_command { %s }\n", web_command); - fprintf(f, "\tblist_pos { %d } { %d } { %d } { %d }\n", - blist_pos.x, blist_pos.y, blist_pos.width, blist_pos.height); + fprintf(f, "\tblist_pos { %d } { %d } { %d } { %d } { %d } { %d }\n", + blist_pos.x, blist_pos.y, blist_pos.width, blist_pos.height, + blist_pos.xoff, blist_pos.yoff); fprintf(f, "}\n"); }