comparison src/buddy.c @ 1420:9be6790092dc

[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 <tailor@pidgin.im>
author Eric Warmenhoven <eric@warmenhoven.org>
date Tue, 23 Jan 2001 12:08:21 +0000
parents 42955549cdd9
children f16e17d42b43
comparison
equal deleted inserted replaced
1419:b37ed5eb0317 1420:9be6790092dc
2014 2014
2015 static void move_blist_window(GtkWidget *w, GdkEventConfigure *e, void *dummy) 2015 static void move_blist_window(GtkWidget *w, GdkEventConfigure *e, void *dummy)
2016 { 2016 {
2017 int x, y, width, height; 2017 int x, y, width, height;
2018 int save = 0; 2018 int save = 0;
2019 gdk_window_get_root_origin(blist->window, &x, &y); 2019 gdk_window_get_position(blist->window, &x, &y);
2020 gdk_window_get_size(blist->window, &width, &height); 2020 gdk_window_get_size(blist->window, &width, &height);
2021 2021
2022 if(e->send_event) { /* Is a position event */ 2022 if(e->send_event) { /* Is a position event */
2023 if (blist_pos.x != x || blist_pos.y != y) 2023 if (blist_pos.x != x || blist_pos.y != y)
2024 save = 1; 2024 save = 1;
2025 blist_pos.x = x; 2025 blist_pos.x = x;
2026 blist_pos.y = y; 2026 blist_pos.y = y;
2027 } else { /* Is a size event */ 2027 } else { /* Is a size event */
2028 if (blist_pos.width != width || blist_pos.width != width) 2028 if (blist_pos.xoff != x || blist_pos.yoff != y || blist_pos.width != width)
2029 save = 1; 2029 save = 1;
2030
2030 blist_pos.width = width; 2031 blist_pos.width = width;
2031 blist_pos.height = height; 2032 blist_pos.height = height;
2033 blist_pos.xoff = x;
2034 blist_pos.yoff = y;
2032 } 2035 }
2033 2036
2034 if (save) 2037 if (save)
2035 save_prefs(); 2038 save_prefs();
2036 2039
2456 2459
2457 gtk_window_set_title(GTK_WINDOW(blist), _("Gaim - Buddy List")); 2460 gtk_window_set_title(GTK_WINDOW(blist), _("Gaim - Buddy List"));
2458 2461
2459 if (general_options & OPT_GEN_SAVED_WINDOWS) { 2462 if (general_options & OPT_GEN_SAVED_WINDOWS) {
2460 if (blist_pos.width != 0) { /* Sanity check! */ 2463 if (blist_pos.width != 0) { /* Sanity check! */
2461 gtk_widget_set_uposition(blist, blist_pos.x, blist_pos.y); 2464 gtk_widget_set_uposition(blist, blist_pos.x - blist_pos.xoff,
2465 blist_pos.y - blist_pos.yoff);
2462 gtk_widget_set_usize(blist, blist_pos.width, blist_pos.height); 2466 gtk_widget_set_usize(blist, blist_pos.width, blist_pos.height);
2463 } 2467 }
2464 } 2468 }
2465 } 2469 }
2466 2470