Mac impl progress
This commit is contained in:
@@ -63,7 +63,6 @@ MacWindow::MacWindow(const CreateWindowSettings& settings)
|
||||
window.title = (__bridge NSString*)MacUtils::ToString(settings.Title);
|
||||
[window setWindow:this];
|
||||
[window setReleasedWhenClosed:NO];
|
||||
[window setBackgroundColor:[NSColor blueColor]];
|
||||
[window setMinSize:NSMakeSize(settings.MinimumSize.X, settings.MinimumSize.Y)];
|
||||
[window setMaxSize:NSMakeSize(settings.MaximumSize.X, settings.MaximumSize.Y)];
|
||||
[window setOpaque:!settings.SupportsTransparency];
|
||||
@@ -169,8 +168,8 @@ bool MacWindow::IsForegroundWindow() const
|
||||
|
||||
void MacWindow::BringToFront(bool force)
|
||||
{
|
||||
NSWindow* window = (NSWindow*)_window;
|
||||
[window activateIgnoringOtherApps:force];
|
||||
Focus();
|
||||
[NSApp activateIgnoringOtherApps: NO];
|
||||
}
|
||||
|
||||
void MacWindow::SetIsFullscreen(bool isFullscreen)
|
||||
|
||||
6
Source/ThirdParty/mono-2.0/mono.Build.cs
vendored
6
Source/ThirdParty/mono-2.0/mono.Build.cs
vendored
@@ -71,7 +71,6 @@ public class mono : DepsModule
|
||||
break;
|
||||
}
|
||||
case TargetPlatform.Linux:
|
||||
case TargetPlatform.Mac:
|
||||
options.PublicDefinitions.Add("USE_MONO_DYNAMIC_LIB");
|
||||
options.DependencyFiles.Add(Path.Combine(depsRoot, "libmonosgen-2.0.so"));
|
||||
options.Libraries.Add(Path.Combine(depsRoot, "libmonosgen-2.0.so"));
|
||||
@@ -91,6 +90,11 @@ public class mono : DepsModule
|
||||
case TargetPlatform.Switch:
|
||||
options.OutputFiles.Add(Path.Combine(depsRoot, "libmonosgen-2.0.a"));
|
||||
break;
|
||||
case TargetPlatform.Mac:
|
||||
options.PublicDefinitions.Add("USE_MONO_DYNAMIC_LIB");
|
||||
options.DependencyFiles.Add(Path.Combine(depsRoot, "libmonosgen-2.0.dylib"));
|
||||
options.Libraries.Add(Path.Combine(depsRoot, "libmonosgen-2.0.dylib"));
|
||||
break;
|
||||
default: throw new InvalidPlatformException(options.Platform.Target);
|
||||
}
|
||||
|
||||
|
||||
@@ -234,8 +234,6 @@ namespace Flax.Build
|
||||
{
|
||||
if (options.Platform.Target == TargetPlatform.PS5)
|
||||
return false; // TODO: mono for ps5
|
||||
if (options.Platform.Target == TargetPlatform.Mac)
|
||||
return false; // TODO: mono for Mac
|
||||
return UseCSharp || options.Target.IsEditor;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -40,6 +40,11 @@ namespace Flax.Deps.Dependencies
|
||||
TargetPlatform.Linux,
|
||||
TargetPlatform.Android,
|
||||
};
|
||||
case TargetPlatform.Mac:
|
||||
return new[]
|
||||
{
|
||||
TargetPlatform.Mac,
|
||||
};
|
||||
default: return new TargetPlatform[0];
|
||||
}
|
||||
}
|
||||
@@ -707,6 +712,26 @@ namespace Flax.Deps.Dependencies
|
||||
method.Invoke(null, new object[] { root, options });
|
||||
break;
|
||||
}
|
||||
case TargetPlatform.Mac:
|
||||
{
|
||||
var monoOptions = new[]
|
||||
{
|
||||
"--with-xen-opt=no",
|
||||
"--without-ikvm-native",
|
||||
"--disable-boehm",
|
||||
"--disable-nls",
|
||||
"--disable-iconv",
|
||||
//"--disable-mcs-build",
|
||||
"--with-mcs-docs=no",
|
||||
"--with-tls=pthread",
|
||||
//"--enable-static",
|
||||
"--enable-maintainer-mode",
|
||||
};
|
||||
var buildDir = Path.Combine(root, "build-mac");
|
||||
|
||||
// Build mono
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user