# HG changeset patch # User Ka-Hing Cheung # Date 1186626460 0 # Node ID f36fc45b7866afacf2a65c20110b5431f16ee94f # Parent 42161f9233bf3fe98c8305d2af55b12eeda9cdff really make restoring size and position work diff -r 42161f9233bf -r f36fc45b7866 pidgin/gtkconv.c --- a/pidgin/gtkconv.c Sun Aug 05 19:41:08 2007 +0000 +++ b/pidgin/gtkconv.c Thu Aug 09 02:27:40 2007 +0000 @@ -8324,11 +8324,6 @@ if (gdk_window_get_state(w->window) & GDK_WINDOW_STATE_MAXIMIZED) return FALSE; - /* don't save if nothing changed */ - if (x == purple_prefs_get_int(PIDGIN_PREFS_ROOT "/conversations/im/x") && - y == purple_prefs_get_int(PIDGIN_PREFS_ROOT "/conversations/im/y")) - return FALSE; /* carry on normally */ - /* don't save off-screen positioning */ if (x + event->width < 0 || y + event->height < 0 || @@ -8376,10 +8371,10 @@ static void pidgin_conv_restore_position(PidginWindow *win) { pidgin_conv_set_position_size(win, - purple_prefs_get_int(PIDGIN_PREFS_ROOT "/conversations/x"), - purple_prefs_get_int(PIDGIN_PREFS_ROOT "/conversations/y"), - purple_prefs_get_int(PIDGIN_PREFS_ROOT "/conversations/width"), - purple_prefs_get_int(PIDGIN_PREFS_ROOT "/conversations/height")); + purple_prefs_get_int(PIDGIN_PREFS_ROOT "/conversations/im/x"), + purple_prefs_get_int(PIDGIN_PREFS_ROOT "/conversations/im/y"), + purple_prefs_get_int(PIDGIN_PREFS_ROOT "/conversations/im/width"), + purple_prefs_get_int(PIDGIN_PREFS_ROOT "/conversations/im/height")); } PidginWindow * @@ -9028,6 +9023,7 @@ PidginWindow *win; win = pidgin_conv_window_new(); + g_signal_connect(G_OBJECT(win->window), "configure_event", G_CALLBACK(gtk_conv_configure_cb), NULL);