Load App.framework in macOS app (flutter/engine#23221)

This commit is contained in:
Jenn Magder 2020-12-21 13:51:58 -08:00 committed by GitHub
parent 06a21ddc1f
commit 4942e7faad

View File

@ -32,6 +32,9 @@ static NSString* const kAppBundleIdentifier = @"io.flutter.flutter.app";
_dartBundle = [NSBundle bundleWithURL:[NSBundle.mainBundle.privateFrameworksURL
URLByAppendingPathComponent:@"App.framework"]];
}
if (!_dartBundle.isLoaded) {
[_dartBundle load];
}
_dartEntrypointArguments = [[NSProcessInfo processInfo] arguments];
// Remove the first element as it's the binary name
_dartEntrypointArguments = [_dartEntrypointArguments