summaryrefslogtreecommitdiffstats
path: root/video/out/x11_common.c
diff options
context:
space:
mode:
authorDudemanguy <random342@airmail.cc>2023-01-08 13:16:47 -0600
committerDudemanguy <random342@airmail.cc>2023-01-08 20:42:42 +0000
commite4e0e7dfcf3a79f7bb510e11d059bcf8d1e93bd6 (patch)
tree8a26c42915f9d7f1a32a1162a4b96aaefcab4296 /video/out/x11_common.c
parente43393c4da0c72dd974cc5ff08952f7614b3958f (diff)
downloadmpv-e4e0e7dfcf3a79f7bb510e11d059bcf8d1e93bd6.tar.bz2
mpv-e4e0e7dfcf3a79f7bb510e11d059bcf8d1e93bd6.tar.xz
vo: change vo_platform_init to bool
There's several functions that are used for initializing mpv on a certain platform (x11, wayland, etc.). These currently are all int, but they actually return 1 and 0 like a boolean. This gets a bit confusing because actual vo preinit functions return 0 and -1 instead. Just make these all bool instead and return true/false to make it clearer.
Diffstat (limited to 'video/out/x11_common.c')
-rw-r--r--video/out/x11_common.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/video/out/x11_common.c b/video/out/x11_common.c
index 37149148b9..c61bab7497 100644
--- a/video/out/x11_common.c
+++ b/video/out/x11_common.c
@@ -596,7 +596,7 @@ static void vo_x11_get_bounding_monitors(struct vo_x11_state *x11, long b[4])
XFree(screens);
}
-int vo_x11_init(struct vo *vo)
+bool vo_x11_init(struct vo *vo)
{
char *dispName;
@@ -685,11 +685,11 @@ int vo_x11_init(struct vo *vo)
vo_x11_update_geometry(vo);
- return 1;
+ return true;
error:
vo_x11_uninit(vo);
- return 0;
+ return false;
}
static const struct mp_keymap keymap[] = {