mirror of
https://github.com/flutter/flutter.git
synced 2026-02-20 02:29:02 +08:00
Made it so we clean up gl resources when view controllers get deleted. (flutter/engine#13396)
This commit is contained in:
parent
3c497a831e
commit
7cdf36bc7f
@ -203,6 +203,11 @@ NSString* const FlutterDefaultDartEntrypoint = nil;
|
||||
- (void)notifyViewControllerDeallocated {
|
||||
if (!_allowHeadlessExecution) {
|
||||
[self destroyContext];
|
||||
} else {
|
||||
flutter::PlatformViewIOS* platform_view = [self iosPlatformView];
|
||||
if (platform_view) {
|
||||
platform_view->SetOwnerViewController({});
|
||||
}
|
||||
}
|
||||
_viewController.reset();
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user