Disable FlutterMetalLayer by default. (flutter/engine#54095)
Backing textures aren't getting deallocated, which is causing memory leaks and crashing devicelab.
This commit is contained in:
parent
dc9ff41cb8
commit
f4ca71ce57
@ -424,14 +424,14 @@ extern CFTimeInterval display_link_target;
|
|||||||
}
|
}
|
||||||
|
|
||||||
+ (BOOL)enabled {
|
+ (BOOL)enabled {
|
||||||
static BOOL enabled = YES;
|
static BOOL enabled = NO;
|
||||||
static BOOL didCheckInfoPlist = NO;
|
static BOOL didCheckInfoPlist = NO;
|
||||||
if (!didCheckInfoPlist) {
|
if (!didCheckInfoPlist) {
|
||||||
didCheckInfoPlist = YES;
|
didCheckInfoPlist = YES;
|
||||||
NSNumber* use_flutter_metal_layer =
|
NSNumber* use_flutter_metal_layer =
|
||||||
[[NSBundle mainBundle] objectForInfoDictionaryKey:@"FLTUseFlutterMetalLayer"];
|
[[NSBundle mainBundle] objectForInfoDictionaryKey:@"FLTUseFlutterMetalLayer"];
|
||||||
if (use_flutter_metal_layer != nil && ![use_flutter_metal_layer boolValue]) {
|
if (use_flutter_metal_layer != nil && [use_flutter_metal_layer boolValue]) {
|
||||||
enabled = NO;
|
enabled = YES;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return enabled;
|
return enabled;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user