Use a GtkAlignment rather than a GtkDrawingArea to draw the swatch in to
2005-05-11 Owen Taylor <otaylor@redhat.com> * gtk/gtkcolorbutton.c: Use a GtkAlignment rather than a GtkDrawingArea to draw the swatch in to avoid having an extraneous window.
This commit is contained in:
parent
dda40ca71a
commit
aada841db8
@ -1,3 +1,9 @@
|
|||||||
|
2005-05-11 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* tests/testgtk.c (on_alpha_window_expose): Fix to use
|
||||||
|
gdk_cairo_create(). (create_alpha_window): Hook up "response"
|
||||||
|
to close the window.
|
||||||
|
|
||||||
2005-05-11 Owen Taylor <otaylor@redhat.com>
|
2005-05-11 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* gtk/gtkcolorbutton.c: Use a GtkAlignment rather than a GtkDrawingArea
|
* gtk/gtkcolorbutton.c: Use a GtkAlignment rather than a GtkDrawingArea
|
||||||
|
@ -1,3 +1,9 @@
|
|||||||
|
2005-05-11 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* tests/testgtk.c (on_alpha_window_expose): Fix to use
|
||||||
|
gdk_cairo_create(). (create_alpha_window): Hook up "response"
|
||||||
|
to close the window.
|
||||||
|
|
||||||
2005-05-11 Owen Taylor <otaylor@redhat.com>
|
2005-05-11 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* gtk/gtkcolorbutton.c: Use a GtkAlignment rather than a GtkDrawingArea
|
* gtk/gtkcolorbutton.c: Use a GtkAlignment rather than a GtkDrawingArea
|
||||||
|
@ -1,3 +1,9 @@
|
|||||||
|
2005-05-11 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
|
* tests/testgtk.c (on_alpha_window_expose): Fix to use
|
||||||
|
gdk_cairo_create(). (create_alpha_window): Hook up "response"
|
||||||
|
to close the window.
|
||||||
|
|
||||||
2005-05-11 Owen Taylor <otaylor@redhat.com>
|
2005-05-11 Owen Taylor <otaylor@redhat.com>
|
||||||
|
|
||||||
* gtk/gtkcolorbutton.c: Use a GtkAlignment rather than a GtkDrawingArea
|
* gtk/gtkcolorbutton.c: Use a GtkAlignment rather than a GtkDrawingArea
|
||||||
|
@ -160,7 +160,7 @@ on_alpha_window_expose (GtkWidget *widget,
|
|||||||
cairo_pattern_t *pattern;
|
cairo_pattern_t *pattern;
|
||||||
int radius;
|
int radius;
|
||||||
|
|
||||||
cr = gdk_drawable_create_cairo_context (widget->window);
|
cr = gdk_cairo_create (widget->window);
|
||||||
|
|
||||||
radius = MIN (widget->allocation.width, widget->allocation.height) / 2;
|
radius = MIN (widget->allocation.width, widget->allocation.height) / 2;
|
||||||
pattern = cairo_pattern_create_radial (widget->allocation.width / 2,
|
pattern = cairo_pattern_create_radial (widget->allocation.width / 2,
|
||||||
@ -391,6 +391,10 @@ create_alpha_window (GtkWidget *widget)
|
|||||||
g_signal_connect (window, "destroy",
|
g_signal_connect (window, "destroy",
|
||||||
G_CALLBACK (gtk_widget_destroyed),
|
G_CALLBACK (gtk_widget_destroyed),
|
||||||
&window);
|
&window);
|
||||||
|
|
||||||
|
g_signal_connect (window, "response",
|
||||||
|
G_CALLBACK (gtk_widget_destroy),
|
||||||
|
NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!GTK_WIDGET_VISIBLE (window))
|
if (!GTK_WIDGET_VISIBLE (window))
|
||||||
|
Loading…
Reference in New Issue
Block a user