0
0
mirror of https://github.com/mpv-player/mpv.git synced 2024-09-20 12:02:23 +02:00

cocoa: make --ontop also cover dock+menubar

This only shows any differences when mpv isn't frontmost and is in fullscreen.
Cmd+Tab overlay is still at a higher level as to avoid complete usability fail.
This commit is contained in:
Stefano Pigozzi 2013-10-12 20:57:28 +02:00
parent f312528ebc
commit 8d5f800567

View File

@ -235,7 +235,9 @@ static void vo_set_level(struct vo *vo, int ontop)
{
struct vo_cocoa_state *s = vo->cocoa;
if (ontop) {
s->window_level = NSNormalWindowLevel + 1;
// +1 is not enough as that will show the icon layer on top of the
// menubar when the application is not frontmost. so use +2
s->window_level = NSMainMenuWindowLevel + 2;
} else {
s->window_level = NSNormalWindowLevel;
}