forked from AuroraMiddleware/gtk
tests: Avoid a use of ::map-event
We can use the ::map signal here instead.
This commit is contained in:
parent
1e8a336993
commit
3cb93a479a
@ -147,8 +147,7 @@ tick_callback (GtkWidget *widget,
|
||||
}
|
||||
|
||||
static gboolean
|
||||
on_map_event (GtkWidget *widget,
|
||||
GdkEventAny *event)
|
||||
on_map (GtkWidget *widget)
|
||||
{
|
||||
gtk_widget_add_tick_callback (window, tick_callback, NULL, NULL);
|
||||
|
||||
@ -200,8 +199,8 @@ main(int argc, char **argv)
|
||||
g_signal_connect (window, "destroy",
|
||||
G_CALLBACK (gtk_main_quit), NULL);
|
||||
|
||||
g_signal_connect (window, "map-event",
|
||||
G_CALLBACK (on_map_event), NULL);
|
||||
g_signal_connect (window, "map",
|
||||
G_CALLBACK (on_map), NULL);
|
||||
on_frame (0.);
|
||||
|
||||
display = gtk_widget_get_display (window);
|
||||
|
@ -29,9 +29,7 @@ place_popup (GtkWidget *parent,
|
||||
}
|
||||
|
||||
static gboolean
|
||||
on_map_event (GtkWidget *parent,
|
||||
GdkEvent *event,
|
||||
gpointer data)
|
||||
on_map (GtkWidget *parent)
|
||||
{
|
||||
GtkWidget *popup, *da;
|
||||
|
||||
@ -59,7 +57,7 @@ main (int argc, char *argv[])
|
||||
window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
|
||||
|
||||
g_signal_connect (window, "destroy", gtk_main_quit, NULL);
|
||||
g_signal_connect (window, "map-event", G_CALLBACK (on_map_event), NULL);
|
||||
g_signal_connect (window, "map", G_CALLBACK (on_map), NULL);
|
||||
|
||||
gtk_widget_show (window);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user