From 958c50be61e5962595e47ca213db3b3594b335d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Miguel?= Date: Sun, 23 Apr 2023 13:10:37 +0100 Subject: [PATCH] I see no reason why the rotation variable is an unsigned instead of a uint8_t which saves memory --- app/src/screen.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/screen.h b/app/src/screen.h index 4fca04d88d..7e9fb9ac33 100644 --- a/app/src/screen.h +++ b/app/src/screen.h @@ -51,7 +51,7 @@ struct sc_screen { struct sc_size windowed_content_size; // client rotation: 0, 1, 2 or 3 (x90 degrees counterclockwise) - unsigned rotation; + uint8_t rotation; // rectangle of the content (excluding black borders) struct SDL_Rect rect; bool has_frame; @@ -132,7 +132,7 @@ sc_screen_resize_to_pixel_perfect(struct sc_screen *screen); // set the display rotation (0, 1, 2 or 3, x90 degrees counterclockwise) void -sc_screen_set_rotation(struct sc_screen *screen, unsigned rotation); +sc_screen_set_rotation(struct sc_screen *screen, uint8_t rotation); // react to SDL events // If this function returns false, scrcpy must exit with an error.