Stop relying on ARRAY_LENGTH being defined in wayland-util.h

Time to break a bad habit.
dev
Kristian Høgsberg 13 years ago
parent f461eee2b0
commit 5717b6dbf1
  1. 2
      clients/simple-touch.c
  2. 2
      clients/window.h
  3. 1
      src/compositor.h

@ -32,6 +32,8 @@
#include <wayland-client.h> #include <wayland-client.h>
#include "../shared/os-compatibility.h" #include "../shared/os-compatibility.h"
#define ARRAY_LENGTH(a) (sizeof (a) / sizeof (a)[0])
struct touch { struct touch {
struct wl_display *display; struct wl_display *display;
struct wl_registry *registry; struct wl_registry *registry;

@ -28,6 +28,8 @@
#include <cairo.h> #include <cairo.h>
#include "../shared/config-parser.h" #include "../shared/config-parser.h"
#define ARRAY_LENGTH(a) (sizeof (a) / sizeof (a)[0])
struct window; struct window;
struct widget; struct widget;
struct display; struct display;

@ -37,6 +37,7 @@
#include "../shared/config-parser.h" #include "../shared/config-parser.h"
#include "weston-egl-ext.h" #include "weston-egl-ext.h"
#define ARRAY_LENGTH(a) (sizeof (a) / sizeof (a)[0])
struct weston_transform { struct weston_transform {
struct weston_matrix matrix; struct weston_matrix matrix;

Loading…
Cancel
Save