summaryrefslogtreecommitdiff
path: root/weston-ivi-shell/src/ivi-controller.c
diff options
context:
space:
mode:
authorEugen Friedrich <efriedrich@de.adit-jv.com>2023-01-20 11:21:24 +0100
committerEugen Friedrich <efriedrich@de.adit-jv.com>2023-01-20 11:21:24 +0100
commit90a904b0ad57b5a4149a366307b54249bc109854 (patch)
tree8376783a71f5618876bdc6686add3a1ddde25585 /weston-ivi-shell/src/ivi-controller.c
parent40596515569210b603caff702568681659c05fec (diff)
parent4c7d574af5cfba7a06c6d5575ee699ee8381fab8 (diff)
downloadwayland-ivi-extension-90a904b0ad57b5a4149a366307b54249bc109854.tar.gz
Merge remote-tracking branch 'upstream/pull/141'
* upstream/pull/141 CMakeLists: update libweston to version 8 Remove unused function decodeEscapesequences Remove unused function importSceneFromTXTHelper Add missing include of endian.h Fix crash in controller_screenshot_notify Reviewed-by: Eugen Friedrich <efriedrich@de.adit-jv.com> Reviewed-by: Harsha M M <harsha.manjulamallikarjun@in.bosch.com> Tested-by: Doan Ngoc Au <au.doanngoc@vn.bosch.com>
Diffstat (limited to 'weston-ivi-shell/src/ivi-controller.c')
-rw-r--r--weston-ivi-shell/src/ivi-controller.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/weston-ivi-shell/src/ivi-controller.c b/weston-ivi-shell/src/ivi-controller.c
index cabd31b..629e673 100644
--- a/weston-ivi-shell/src/ivi-controller.c
+++ b/weston-ivi-shell/src/ivi-controller.c
@@ -86,6 +86,7 @@ struct screenshot_frame_listener {
struct wl_listener frame_listener;
struct wl_listener output_destroyed;
struct wl_resource *screenshot;
+ struct weston_output *output;
};
struct screen_id_info {
@@ -1206,7 +1207,7 @@ controller_screenshot_notify(struct wl_listener *listener, void *data)
struct screenshot_frame_listener *l =
wl_container_of(listener, l, frame_listener);
- struct weston_output *output = data;
+ struct weston_output *output = l->output;
int32_t width = 0;
int32_t height = 0;
int32_t stride = 0;
@@ -1336,6 +1337,8 @@ controller_screen_screenshot(struct wl_client *client,
return;
}
+ l->output = iviscrn->output;
+
wl_resource_set_implementation(l->screenshot, NULL, l,
screenshot_frame_listener_destroy);
l->output_destroyed.notify = screenshot_output_destroyed;