Mercurial > pidgin.yaz
comparison pidgin/eggtrayicon.c @ 29471:d83ee160ffb6
propagate from branch 'im.pidgin.pidgin' (head eb9385f349a20856b9d3f9911dbc8024caa44052)
to branch 'im.pidgin.pidgin.next.minor' (head 439fb2dd7a285d9ca645f65f36ef0f037abe7311)
author | Elliott Sales de Andrade <qulogic@pidgin.im> |
---|---|
date | Wed, 19 Aug 2009 00:46:04 +0000 |
parents | 211b59ac6345 |
children |
comparison
equal
deleted
inserted
replaced
29470:7a3458436140 | 29471:d83ee160ffb6 |
---|---|
398 } | 398 } |
399 | 399 |
400 static gboolean | 400 static gboolean |
401 transparent_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data) | 401 transparent_expose_event (GtkWidget *widget, GdkEventExpose *event, gpointer user_data) |
402 { | 402 { |
403 gdk_window_clear_area (widget->window, event->area.x, event->area.y, | 403 GtkWidget *focus_child = NULL; |
404 event->area.width, event->area.height); | 404 gint border_width, x, y, width, height; |
405 return FALSE; | 405 gboolean retval = FALSE; |
406 | |
407 gdk_window_clear_area (widget->window, event->area.x, event->area.y, | |
408 event->area.width, event->area.height); | |
409 | |
410 if (GTK_WIDGET_CLASS (parent_class)->expose_event) | |
411 retval = GTK_WIDGET_CLASS (parent_class)->expose_event (widget, event); | |
412 | |
413 if (GTK_CONTAINER (widget)->focus_child) | |
414 focus_child = GTK_CONTAINER (GTK_CONTAINER (widget)->focus_child)->focus_child; | |
415 if (focus_child && GTK_WIDGET_HAS_FOCUS (focus_child)) | |
416 { | |
417 border_width = GTK_CONTAINER (widget)->border_width; | |
418 | |
419 x = widget->allocation.x + border_width; | |
420 y = widget->allocation.y + border_width; | |
421 | |
422 width = widget->allocation.width - 2 * border_width; | |
423 height = widget->allocation.height - 2 * border_width; | |
424 | |
425 gtk_paint_focus (widget->style, widget->window, | |
426 GTK_WIDGET_STATE (widget), | |
427 &event->area, widget, "tray_icon", | |
428 x, y, width, height); | |
429 } | |
430 | |
431 return retval; | |
406 } | 432 } |
407 | 433 |
408 static void | 434 static void |
409 make_transparent_again (GtkWidget *widget, GtkStyle *previous_style, | 435 make_transparent_again (GtkWidget *widget, GtkStyle *previous_style, |
410 gpointer user_data) | 436 gpointer user_data) |