Fix bugs Alex found:

2000-12-04  Havoc Pennington  <hp@redhat.com>

        Fix bugs Alex found:

	* gtk/gtktooltips.c (gtk_tooltips_force_window): nuke connection
	to "draw"

	* gtk/gtkdnd.c (gtk_drag_highlight): nuke connection to "draw"

	* gtk/gtkcolorsel.c (palette_new): nuke connection to "draw"

	* gtk/gtklistitem.c (gtk_list_item_expose): Put the old _draw()
	implementation in here, apparently the expose() implementation was
	dead code.
This commit is contained in:
Havoc Pennington 2000-12-04 16:11:51 +00:00 committed by Havoc Pennington
parent 15c81f52d3
commit 9cca191b6a
11 changed files with 135 additions and 29 deletions

View File

@ -1,3 +1,18 @@
2000-12-04 Havoc Pennington <hp@redhat.com>
Fix bugs Alex found:
* gtk/gtktooltips.c (gtk_tooltips_force_window): nuke connection
to "draw"
* gtk/gtkdnd.c (gtk_drag_highlight): nuke connection to "draw"
* gtk/gtkcolorsel.c (palette_new): nuke connection to "draw"
* gtk/gtklistitem.c (gtk_list_item_expose): Put the old _draw()
implementation in here, apparently the expose() implementation was
dead code.
2000-12-04 Alexander Larsson <alexl@redhat.com>
* gdk/linux-fb/gdkpango-fb.c (pango_fb_font_get_metrics):

View File

@ -1,3 +1,18 @@
2000-12-04 Havoc Pennington <hp@redhat.com>
Fix bugs Alex found:
* gtk/gtktooltips.c (gtk_tooltips_force_window): nuke connection
to "draw"
* gtk/gtkdnd.c (gtk_drag_highlight): nuke connection to "draw"
* gtk/gtkcolorsel.c (palette_new): nuke connection to "draw"
* gtk/gtklistitem.c (gtk_list_item_expose): Put the old _draw()
implementation in here, apparently the expose() implementation was
dead code.
2000-12-04 Alexander Larsson <alexl@redhat.com>
* gdk/linux-fb/gdkpango-fb.c (pango_fb_font_get_metrics):

View File

@ -1,3 +1,18 @@
2000-12-04 Havoc Pennington <hp@redhat.com>
Fix bugs Alex found:
* gtk/gtktooltips.c (gtk_tooltips_force_window): nuke connection
to "draw"
* gtk/gtkdnd.c (gtk_drag_highlight): nuke connection to "draw"
* gtk/gtkcolorsel.c (palette_new): nuke connection to "draw"
* gtk/gtklistitem.c (gtk_list_item_expose): Put the old _draw()
implementation in here, apparently the expose() implementation was
dead code.
2000-12-04 Alexander Larsson <alexl@redhat.com>
* gdk/linux-fb/gdkpango-fb.c (pango_fb_font_get_metrics):

View File

@ -1,3 +1,18 @@
2000-12-04 Havoc Pennington <hp@redhat.com>
Fix bugs Alex found:
* gtk/gtktooltips.c (gtk_tooltips_force_window): nuke connection
to "draw"
* gtk/gtkdnd.c (gtk_drag_highlight): nuke connection to "draw"
* gtk/gtkcolorsel.c (palette_new): nuke connection to "draw"
* gtk/gtklistitem.c (gtk_list_item_expose): Put the old _draw()
implementation in here, apparently the expose() implementation was
dead code.
2000-12-04 Alexander Larsson <alexl@redhat.com>
* gdk/linux-fb/gdkpango-fb.c (pango_fb_font_get_metrics):

View File

@ -1,3 +1,18 @@
2000-12-04 Havoc Pennington <hp@redhat.com>
Fix bugs Alex found:
* gtk/gtktooltips.c (gtk_tooltips_force_window): nuke connection
to "draw"
* gtk/gtkdnd.c (gtk_drag_highlight): nuke connection to "draw"
* gtk/gtkcolorsel.c (palette_new): nuke connection to "draw"
* gtk/gtklistitem.c (gtk_list_item_expose): Put the old _draw()
implementation in here, apparently the expose() implementation was
dead code.
2000-12-04 Alexander Larsson <alexl@redhat.com>
* gdk/linux-fb/gdkpango-fb.c (pango_fb_font_get_metrics):

View File

@ -1,3 +1,18 @@
2000-12-04 Havoc Pennington <hp@redhat.com>
Fix bugs Alex found:
* gtk/gtktooltips.c (gtk_tooltips_force_window): nuke connection
to "draw"
* gtk/gtkdnd.c (gtk_drag_highlight): nuke connection to "draw"
* gtk/gtkcolorsel.c (palette_new): nuke connection to "draw"
* gtk/gtklistitem.c (gtk_list_item_expose): Put the old _draw()
implementation in here, apparently the expose() implementation was
dead code.
2000-12-04 Alexander Larsson <alexl@redhat.com>
* gdk/linux-fb/gdkpango-fb.c (pango_fb_font_get_metrics):

View File

@ -1,3 +1,18 @@
2000-12-04 Havoc Pennington <hp@redhat.com>
Fix bugs Alex found:
* gtk/gtktooltips.c (gtk_tooltips_force_window): nuke connection
to "draw"
* gtk/gtkdnd.c (gtk_drag_highlight): nuke connection to "draw"
* gtk/gtkcolorsel.c (palette_new): nuke connection to "draw"
* gtk/gtklistitem.c (gtk_list_item_expose): Put the old _draw()
implementation in here, apparently the expose() implementation was
dead code.
2000-12-04 Alexander Larsson <alexl@redhat.com>
* gdk/linux-fb/gdkpango-fb.c (pango_fb_font_get_metrics):

View File

@ -621,14 +621,6 @@ palette_press (GtkWidget *drawing_area,
gtk_widget_queue_clear (priv->last_palette);
}
static void
palette_draw (GtkWidget *drawing_area,
GdkRectangle *area,
gpointer data)
{
palette_paint (drawing_area, area, data);
}
static void
palette_unset_color (GtkWidget *drawing_area)
{
@ -819,7 +811,6 @@ palette_new (GtkColorSelection *colorsel)
gtk_object_set_data (GTK_OBJECT (retval), "color_set", GINT_TO_POINTER (0));
gtk_widget_set_events (retval, GDK_BUTTON_PRESS_MASK | GDK_EXPOSURE_MASK);
gtk_signal_connect (GTK_OBJECT (retval), "draw", palette_draw, colorsel);
gtk_signal_connect (GTK_OBJECT (retval), "expose_event", palette_expose, colorsel);
gtk_signal_connect (GTK_OBJECT (retval), "button_press_event", palette_press, colorsel);

View File

@ -810,9 +810,6 @@ gtk_drag_highlight_expose (GtkWidget *widget,
void
gtk_drag_highlight (GtkWidget *widget)
{
gtk_signal_connect_after (GTK_OBJECT (widget), "draw",
GTK_SIGNAL_FUNC (gtk_drag_highlight_paint),
NULL);
gtk_signal_connect (GTK_OBJECT (widget), "expose_event",
GTK_SIGNAL_FUNC (gtk_drag_highlight_expose),
NULL);

View File

@ -482,36 +482,53 @@ gtk_list_item_expose (GtkWidget *widget,
GdkEventExpose *event)
{
GtkBin *bin;
GdkEventExpose child_event;
g_return_val_if_fail (widget != NULL, FALSE);
g_return_val_if_fail (GTK_IS_LIST_ITEM (widget), FALSE);
g_return_val_if_fail (event != NULL, FALSE);
if (GTK_WIDGET_DRAWABLE (widget))
{
bin = GTK_BIN (widget);
if (!GTK_WIDGET_IS_SENSITIVE (widget))
gdk_window_set_background (widget->window, &widget->style->bg[GTK_STATE_INSENSITIVE]);
else if (widget->state == GTK_STATE_NORMAL)
gdk_window_set_background (widget->window, &widget->style->base[GTK_STATE_NORMAL]);
if (widget->state == GTK_STATE_NORMAL)
{
gdk_window_set_back_pixmap (widget->window, NULL, TRUE);
gdk_window_clear_area (widget->window, event->area.x, event->area.y,
event->area.width, event->area.height);
}
else
gdk_window_set_background (widget->window, &widget->style->bg[widget->state]);
gdk_window_clear_area (widget->window, event->area.x, event->area.y,
event->area.width, event->area.height);
{
gtk_paint_flat_box (widget->style, widget->window,
widget->state, GTK_SHADOW_ETCHED_OUT,
&event->area, widget, "listitem",
0, 0, -1, -1);
}
if (bin->child)
{
GdkEventExpose child_event;
child_event = *event;
if (GTK_WIDGET_NO_WINDOW (bin->child) &&
gtk_widget_intersect (bin->child, &event->area, &child_event.area))
gtk_widget_event (bin->child, (GdkEvent*) &child_event);
}
gtk_widget_draw_focus (widget);
if (GTK_WIDGET_HAS_FOCUS (widget))
{
if (GTK_IS_LIST (widget->parent) && GTK_LIST (widget->parent)->add_mode)
gtk_paint_focus (widget->style, widget->window,
NULL, widget, "add-mode",
0, 0,
widget->allocation.width - 1,
widget->allocation.height - 1);
else
gtk_paint_focus (widget->style, widget->window,
NULL, widget, NULL,
0, 0,
widget->allocation.width - 1,
widget->allocation.height - 1);
}
}
return FALSE;

View File

@ -173,10 +173,6 @@ gtk_tooltips_force_window (GtkTooltips *tooltips)
"expose_event",
GTK_SIGNAL_FUNC (gtk_tooltips_paint_window),
GTK_OBJECT (tooltips));
gtk_signal_connect_object (GTK_OBJECT (tooltips->tip_window),
"draw",
GTK_SIGNAL_FUNC (gtk_tooltips_paint_window),
GTK_OBJECT (tooltips));
tooltips->tip_label = gtk_label_new (NULL);
gtk_label_set_line_wrap (GTK_LABEL (tooltips->tip_label), TRUE);