pidgin/gtkstatusbox.c

branch
cpw.qulogic.gtk3-required
changeset 33152
b6c76bcadbe8
parent 33132
24afd2b22579
child 33158
ad941796372e
equal deleted inserted replaced
33151:bf6111db26df 33152:b6c76bcadbe8
1940 1940
1941 *minimum_height = MAX(*minimum_height, 34) + border_width * 2; 1941 *minimum_height = MAX(*minimum_height, 34) + border_width * 2;
1942 *natural_height = MAX(*natural_height, 34) + border_width * 2; 1942 *natural_height = MAX(*natural_height, 34) + border_width * 2;
1943 1943
1944 /* If the gtkimhtml is visible, then add some additional padding */ 1944 /* If the gtkimhtml is visible, then add some additional padding */
1945 gtk_widget_get_preferred_height(PIDGIN_STATUS_BOX(widget)->vbox, 1945 if (PIDGIN_STATUS_BOX(widget)->imhtml_visible) {
1946 &box_min_height, &box_nat_height); 1946 gtk_widget_get_preferred_height(PIDGIN_STATUS_BOX(widget)->vbox,
1947 1947 &box_min_height, &box_nat_height);
1948 if (box_min_height > 1) 1948
1949 *minimum_height += box_min_height + border_width * 2; 1949 if (box_min_height > 1)
1950 1950 *minimum_height += box_min_height + border_width * 2;
1951 if (box_nat_height > 1) 1951
1952 *natural_height += box_nat_height + border_width * 2; 1952 if (box_nat_height > 1)
1953 *natural_height += box_nat_height + border_width * 2;
1954 }
1953 } 1955 }
1954 1956
1955 /* From gnome-panel */ 1957 /* From gnome-panel */
1956 static void 1958 static void
1957 do_colorshift (GdkPixbuf *dest, GdkPixbuf *src, int shift) 1959 do_colorshift (GdkPixbuf *dest, GdkPixbuf *src, int shift)
2037 } 2039 }
2038 gtk_widget_size_allocate(status_box->icon_box, &icon_alc); 2040 gtk_widget_size_allocate(status_box->icon_box, &icon_alc);
2039 } 2041 }
2040 gtk_widget_size_allocate(status_box->toggle_button, &parent_alc); 2042 gtk_widget_size_allocate(status_box->toggle_button, &parent_alc);
2041 gtk_widget_set_allocation(GTK_WIDGET(status_box), allocation); 2043 gtk_widget_set_allocation(GTK_WIDGET(status_box), allocation);
2042 purple_debug_info("pidgin", "statusbox allocation: width = %d, height = %d\n",
2043 allocation->width, allocation->height);
2044 } 2044 }
2045 2045
2046 static gboolean 2046 static gboolean
2047 pidgin_status_box_draw(GtkWidget *widget, cairo_t *cr) 2047 pidgin_status_box_draw(GtkWidget *widget, cairo_t *cr)
2048 { 2048 {

mercurial