Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed to be compilable on macOS 12 #176

Merged
merged 3 commits into from
Nov 21, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions virtualization_view.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

#pragma once

#import "virtualization_helper.h"
#import <Availability.h>
#import <Cocoa/Cocoa.h>
#import <Virtualization/Virtualization.h>
Expand Down
4 changes: 3 additions & 1 deletion virtualization_view.m
Original file line number Diff line number Diff line change
Expand Up @@ -453,7 +453,8 @@ - (void)setupGraphicWindow
// distortion within the window.
- (NSSize)getVirtualMachineSizeInPixels
{
__block NSSize sizeInPixels;
__block NSSize sizeInPixels = NSZeroSize;
#ifdef INCLUDE_TARGET_OSX_14
if (@available(macOS 14.0, *)) {
dispatch_sync(_queue, ^{
if (_virtualMachine.graphicsDevices.count > 0) {
Expand All @@ -465,6 +466,7 @@ - (NSSize)getVirtualMachineSizeInPixels
}
});
}
#endif
return sizeInPixels;
Code-Hex marked this conversation as resolved.
Show resolved Hide resolved
}

Expand Down