summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFilippo Argiolas <filippo.argiolas@gmail.com>2009-04-06 16:39:02 +0200
committerFilippo Argiolas <filippo.argiolas@gmail.com>2009-04-06 16:39:02 +0200
commitbe5eb9a9cd1aca2a73686f51b3dac36e1b6299f5 (patch)
tree04770ae492936634b963f735111b1469398261e4
parente7ad4f869c911af2d53f2a0b0bc4f13942dfe7bc (diff)
Enfoce warnings, remove unneeded headers
-rw-r--r--configure.ac2
-rw-r--r--src/cheese-stage.c14
-rw-r--r--src/cheese-texture.c6
3 files changed, 7 insertions, 15 deletions
diff --git a/configure.ac b/configure.ac
index b96f896..04d5886 100644
--- a/configure.ac
+++ b/configure.ac
@@ -5,6 +5,8 @@ AC_PROG_CC
AC_HEADER_STDC
AM_PROG_LIBTOOL
+CFLAGS="${CFLAGS} -Wall -Werror"
+
GNOME_MAINTAINER_MODE_DEFINES
GNOME_COMPILE_WARNINGS
diff --git a/src/cheese-stage.c b/src/cheese-stage.c
index 60e7a14..7d1b067 100644
--- a/src/cheese-stage.c
+++ b/src/cheese-stage.c
@@ -18,14 +18,9 @@
* Boston, MA 02111-1307, USA.
*/
-#include <X11/Xlib.h>
-
#include "cheese-texture.h"
-#include <X11/extensions/Xcomposite.h>
#include <clutter/clutter.h>
-#include <clutter/x11/clutter-x11.h>
-#include <clutter/glx/clutter-glx.h>
#include <gst/gst.h>
#include <gst/interfaces/xoverlay.h>
@@ -56,7 +51,7 @@ create_window (GstBus * bus, GstMessage * message, gpointer data)
if (count < N_ACTORS) {
g_object_get (G_OBJECT (actor[count]), "window", &win, NULL);
- g_message ("adding actor: %d win: %d", count, win);
+ g_message ("adding actor: %d win: %ld", count, win);
gst_x_overlay_set_xwindow_id (GST_X_OVERLAY (GST_MESSAGE_SRC (message)),
win);
count++;
@@ -120,8 +115,6 @@ main (int argc, char *argv[])
gint xpos = 0;
gint ypos = 0;
- Display *disp;
-
ClutterActor *stage;
ClutterColor color;
ClutterActor *actor[N_ACTORS];
@@ -129,11 +122,6 @@ main (int argc, char *argv[])
clutter_init (&argc, &argv);
gst_init (&argc, &argv);
- disp = clutter_x11_get_default_display ();
- if (!clutter_x11_has_composite_extension ()) {
- g_error ("XComposite extension missing");
- }
-
stage = clutter_stage_get_default ();
clutter_actor_set_size (CLUTTER_ACTOR (stage),
diff --git a/src/cheese-texture.c b/src/cheese-texture.c
index 1893a45..bdf9671 100644
--- a/src/cheese-texture.c
+++ b/src/cheese-texture.c
@@ -58,16 +58,18 @@ on_x_event_filter (XEvent * xev, ClutterEvent * cev, gpointer data)
g_object_get (self, "window", &window, NULL);
if (window == None)
- return;
+ return CLUTTER_X11_FILTER_CONTINUE;
switch (xev->type) {
case MapNotify:
g_message ("stage mapped %ld", xev->xmap.window);
XMapWindow (xev->xmap.display, window);
+ XSync (xev->xmap.display, FALSE);
break;
case UnmapNotify:
g_message ("stage unmapped %ld", xev->xmap.window);
XUnmapWindow (xev->xmap.display, window);
+ XSync (xev->xmap.display, FALSE);
break;
default:
break;
@@ -95,7 +97,7 @@ static void
cheese_texture_class_init (CheeseTextureClass * klass)
{
GObjectClass *gobject_class = G_OBJECT_CLASS (klass);
- ClutterActorClass *actor_class = CLUTTER_ACTOR_CLASS (klass);
+/* ClutterActorClass *actor_class = CLUTTER_ACTOR_CLASS (klass); */
g_type_class_add_private (klass, sizeof (CheeseTexturePrivate));