Remove assert for unsupported SemanticsEvents (flutter/engine#5349)

Not all platforms are expected to handle all SemanticsEvents. Therefore, it is ok to just drop unsupported events on the floor.
This commit is contained in:
Michael Goderbauer
2018-05-23 16:05:15 -07:00
committed by GitHub
parent a1a09438be
commit 3337784f29
2 changed files with 0 additions and 4 deletions

View File

@@ -691,8 +691,6 @@ class AccessibilityBridge extends AccessibilityNodeProvider implements BasicMess
e.getText().add((String) data.get("message"));
sendAccessibilityEvent(e);
}
default:
assert false;
}
}

View File

@@ -614,8 +614,6 @@ void AccessibilityBridge::HandleEvent(NSDictionary<NSString*, id>* annotatedEven
if ([type isEqualToString:@"announce"]) {
NSString* message = annotatedEvent[@"data"][@"message"];
UIAccessibilityPostNotification(UIAccessibilityAnnouncementNotification, message);
} else {
NSCAssert(NO, @"Invalid event type %@", type);
}
}