summaryrefslogtreecommitdiffstats
path: root/osdep/macosx_application.m
diff options
context:
space:
mode:
authorder richter <der.richter@gmx.de>2020-12-13 17:13:18 +0100
committerJan Ekström <jeebjp@gmail.com>2020-12-19 21:37:55 +0200
commitaf264029483656e04458a678849165f0340433ab (patch)
treed09a264ac37f67089b7baeb6003efeaed985119a /osdep/macosx_application.m
parent93d071dbd8fb8b9561e1830754c40f3de87cf3ca (diff)
downloadmpv-af264029483656e04458a678849165f0340433ab.tar.bz2
mpv-af264029483656e04458a678849165f0340433ab.tar.xz
mac: use visible frame rectangle for window geometry calculation
currently we use the whole screen rectangle to calculate the window geometry. this doesn't take the menu bar or the Dock into account. by default use the visible screen rectangle instead. this is also a change in behaviour, since the window can't be placed outside of this rectangle anymore. also add an option to change to the old behaviour, because it can still be useful in certain cases, like placing the window directly underneath the menu bar when used a desktop background. Fixes #8272
Diffstat (limited to 'osdep/macosx_application.m')
-rw-r--r--osdep/macosx_application.m2
1 files changed, 2 insertions, 0 deletions
diff --git a/osdep/macosx_application.m b/osdep/macosx_application.m
index 95c6a3f953..bb8b67b575 100644
--- a/osdep/macosx_application.m
+++ b/osdep/macosx_application.m
@@ -65,6 +65,8 @@ const struct m_sub_options macos_conf = {
{"macos-force-dedicated-gpu", OPT_FLAG(macos_force_dedicated_gpu)},
{"macos-app-activation-policy", OPT_CHOICE(macos_app_activation_policy,
{"regular", 0}, {"accessory", 1}, {"prohibited", 2})},
+ {"macos-geometry-calculation", OPT_CHOICE(macos_geometry_calculation,
+ {"visible", FRAME_VISIBLE}, {"whole", FRAME_WHOLE})},
{"cocoa-cb-sw-renderer", OPT_CHOICE(cocoa_cb_sw_renderer,
{"auto", -1}, {"no", 0}, {"yes", 1})},
{"cocoa-cb-10bit-context", OPT_FLAG(cocoa_cb_10bit_context)},