diff options
author | Jason Ekstrand <jason@jlekstrand.net> | 2013-12-02 21:01:53 -0600 |
---|---|---|
committer | Kristian Høgsberg <krh@bitplanet.net> | 2013-12-02 22:17:58 -0800 |
commit | 918f2dd4cfb8b177f67b45653efbbe4325cbe9dc (patch) | |
tree | 3bd3635fc459c545c5ee34adba64656c9bf743d5 /src/input.c | |
parent | fdca95c7db067132b5670cbaa56c4088c2be3f1f (diff) | |
download | weston-918f2dd4cfb8b177f67b45653efbbe4325cbe9dc.tar.gz |
Remove the weston_view.geometry.width/height fields
This has a couple of additional implications for the internal weston API:
1) weston_view_configure no longer exists. Use weston_view_set_position
instead.
2) The weston_surface.configure callback no longer takes a width and
height. If you need these, surface.width/height are set before
configure is called. If you need to know when the width/height
changes, you must track that yourself.
Diffstat (limited to 'src/input.c')
-rw-r--r-- | src/input.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/input.c b/src/input.c index 01eafc26..dcbb1fc5 100644 --- a/src/input.c +++ b/src/input.c @@ -1431,12 +1431,12 @@ notify_touch(struct weston_seat *seat, uint32_t time, int touch_id, static void pointer_cursor_surface_configure(struct weston_surface *es, - int32_t dx, int32_t dy, int32_t width, int32_t height) + int32_t dx, int32_t dy) { struct weston_pointer *pointer = es->configure_private; int x, y; - if (width == 0) + if (es->width == 0) return; assert(es == pointer->sprite->surface); @@ -1447,7 +1447,7 @@ pointer_cursor_surface_configure(struct weston_surface *es, x = wl_fixed_to_int(pointer->x) - pointer->hotspot_x; y = wl_fixed_to_int(pointer->y) - pointer->hotspot_y; - weston_view_configure(pointer->sprite, x, y, width, height); + weston_view_set_position(pointer->sprite, x, y); empty_region(&es->pending.input); @@ -1507,8 +1507,7 @@ pointer_set_cursor(struct wl_client *client, struct wl_resource *resource, pointer->hotspot_y = y; if (surface->buffer_ref.buffer) - pointer_cursor_surface_configure(surface, 0, 0, surface->width, - surface->height); + pointer_cursor_surface_configure(surface, 0, 0); } static void |