diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2020-03-23 18:31:05 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2020-03-23 18:31:05 +0000 |
| commit | 5ffee087481ddf3ad6e3b8e74c6acd3f0d736d82 (patch) | |
| tree | 444bd2eee8fa5ec7ccd59ab1ce8988e452e81a48 | |
| parent | Merge branch 'master' into scroll-damage-performance (diff) | |
shm: add shm_can_scroll()
| -rw-r--r-- | shm.c | 7 | ||||
| -rw-r--r-- | shm.h | 1 |
2 files changed, 8 insertions, 0 deletions
@@ -281,8 +281,15 @@ shm_fini(void) } bool +shm_can_scroll(void) +{ + return can_punch_hole; +} + +bool shm_scroll(struct wl_shm *shm, struct buffer *buf, int rows) { + assert(can_punch_hole); assert(buf->busy); assert(buf->pix); assert(buf->wl_buf); @@ -32,6 +32,7 @@ struct buffer *shm_get_buffer( struct wl_shm *shm, int width, int height, unsigned long cookie); void shm_fini(void); +bool shm_can_scroll(void); bool shm_scroll(struct wl_shm *shm, struct buffer *buf, int rows); void shm_purge(struct wl_shm *shm, unsigned long cookie); |
