2007-04-25 Emmanuele Bassi <ebassi@openedhand.com>

Merge from clutter.git/master

	* clutter/glx/clutter-event-glx.c:
	* clutter/glx/clutter-stage-glx.c: Implement the _NET_WM_PING
	protocol handling on the main stage window.

	* clutter/clutter-stage.h:
	* clutter/clutter-stage.c:
	* clutter/clutter-main.c: Handle CLUTTER_DELETE events internally,
	by calling clutter_main_quit(), and remove the ::delete-event
	signal from ClutterStage; clean up the signal emission sequence
	for the events: emit the ::event signal before emitting any signal
	and the ::event-after signal after the signal has been emitted; move
	the signal emission calls inside ClutterStage so we can call
	g_signal_emit() instead of g_signal_emit_by_name(), thus sparing us
	a lookup for each event.

	* examples/test.c: Remove ::delete-event signal handling.
This commit is contained in:
Emmanuele Bassi
2007-04-25 14:22:24 +00:00
parent 296649e865
commit a7a511ce79
10 changed files with 184 additions and 80 deletions

View File

@ -79,22 +79,6 @@ key_release_cb (ClutterStage *stage,
g_print ("key-release-event\n");
}
static gboolean
delete_event_cb (ClutterStage *stage,
ClutterEvent *event,
gpointer data)
{
static gboolean res = FALSE;
g_print ("delete-event: %s\n",
res == FALSE ? "first attempt" : "second attempt");
res = !res;
return res;
}
int
main (int argc, char *argv[])
{
@ -107,8 +91,6 @@ main (int argc, char *argv[])
clutter_init (&argc, &argv);
stage = clutter_stage_get_default ();
g_signal_connect (stage, "delete-event",
G_CALLBACK (delete_event_cb), NULL);
g_signal_connect (stage, "key-press-event",
G_CALLBACK (key_press_cb), NULL);
g_signal_connect (stage, "key-release-event",