* [PATCH 1/1] Fix safeAreaInsets not being available on OS X 10.13
@ 2024-04-28 11:57 Tobias Markus
2024-04-28 12:14 ` Akihiko Odaki
0 siblings, 1 reply; 2+ messages in thread
From: Tobias Markus @ 2024-04-28 11:57 UTC (permalink / raw)
To: qemu-devel; +Cc: peter.maydell, philmd, akihiko.odaki, kraxel, marcandre.lureau
Hello,
to prefix this: I previously filed
https://gitlab.com/qemu-project/qemu/-/issues/2314 for this compilation
error and I'm quite aware that QEMU only supports the most recent two
versions of Mac OS X by default. However, given the small change
required for this to work, I hope you can make an exception and include
the attached patch into QEMU.
It would really help me continue to run QEMU on my legacy MacOS X 10.13
version.
Thanks in advance!
Kind regards,
Tobias Markus
Resolves: https://gitlab.com/qemu-project/qemu/-/issues/2314
Signed-off-by: Tobias Markus <tobbi.bugs@googlemail.com>
---
ui/cocoa.m | 2 ++
1 file changed, 2 insertions(+)
diff --git a/ui/cocoa.m b/ui/cocoa.m
index 25e0db9dd0..96992736ef 100644
--- a/ui/cocoa.m
+++ b/ui/cocoa.m
@@ -539,9 +539,11 @@ - (NSSize)fixAspectRatio:(NSSize)max
- (NSSize) screenSafeAreaSize
{
NSSize size = [[[self window] screen] frame].size;
+#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_VERSION_14_0
NSEdgeInsets insets = [[[self window] screen] safeAreaInsets];
size.width -= insets.left + insets.right;
size.height -= insets.top + insets.bottom;
+#endif
return size;
}
--
2.24.3 (Apple Git-128)
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH 1/1] Fix safeAreaInsets not being available on OS X 10.13
2024-04-28 11:57 [PATCH 1/1] Fix safeAreaInsets not being available on OS X 10.13 Tobias Markus
@ 2024-04-28 12:14 ` Akihiko Odaki
0 siblings, 0 replies; 2+ messages in thread
From: Akihiko Odaki @ 2024-04-28 12:14 UTC (permalink / raw)
To: Tobias Markus, qemu-devel; +Cc: peter.maydell, philmd, kraxel, marcandre.lureau
On 2024/04/28 20:57, Tobias Markus wrote:
> Hello,
>
> to prefix this: I previously filed
> https://gitlab.com/qemu-project/qemu/-/issues/2314 for this compilation
> error and I'm quite aware that QEMU only supports the most recent two
> versions of Mac OS X by default. However, given the small change
> required for this to work, I hope you can make an exception and include
> the attached patch into QEMU.
>
> It would really help me continue to run QEMU on my legacy MacOS X 10.13
> version.
Hi,
I'm sorry to tell this but I'm not for making an exception.
While this change is indeed small, we already have many codes that are
only needed by unsupported macOS versions. They were not added to keep
QEMU work with unsupported macOS versions, but they were added when
those versions were still supported. Maintaining all of them is not a
trivial task so they are now eligible for removal.
Regards,
Akihiko Odaki
>
> Thanks in advance!
>
> Kind regards,
> Tobias Markus
>
> Resolves: https://gitlab.com/qemu-project/qemu/-/issues/2314
> Signed-off-by: Tobias Markus <tobbi.bugs@googlemail.com>
> ---
> ui/cocoa.m | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/ui/cocoa.m b/ui/cocoa.m
> index 25e0db9dd0..96992736ef 100644
> --- a/ui/cocoa.m
> +++ b/ui/cocoa.m
> @@ -539,9 +539,11 @@ - (NSSize)fixAspectRatio:(NSSize)max
> - (NSSize) screenSafeAreaSize
> {
> NSSize size = [[[self window] screen] frame].size;
> +#if MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_VERSION_14_0
> NSEdgeInsets insets = [[[self window] screen] safeAreaInsets];
> size.width -= insets.left + insets.right;
> size.height -= insets.top + insets.bottom;
> +#endif
> return size;
> }
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-04-28 14:27 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-04-28 11:57 [PATCH 1/1] Fix safeAreaInsets not being available on OS X 10.13 Tobias Markus
2024-04-28 12:14 ` Akihiko Odaki
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.