Unverified Commit 63c58a33 authored by Lau Ching Jun's avatar Lau Ching Jun Committed by GitHub

Make `handleJsonEvent` public so that it can be overridden internally. (#139531)

parent 2c613504
......@@ -472,7 +472,7 @@ class FlutterDebugAdapter extends FlutterBaseDebugAdapter with VmServiceInfoFile
}
/// Handles incoming JSON events from `flutter run --machine`.
void _handleJsonEvent(String event, Map<String, Object?>? params) {
void handleJsonEvent(String event, Map<String, Object?>? params) {
params ??= <String, Object?>{};
switch (event) {
case 'daemon.connected':
......@@ -646,7 +646,7 @@ class FlutterDebugAdapter extends FlutterBaseDebugAdapter with VmServiceInfoFile
final Object? params = payload['params'];
final Object? id = payload['id'];
if (event is String && params is Map<String, Object?>?) {
_handleJsonEvent(event, params);
handleJsonEvent(event, params);
} else if (id != null && method is String && params is Map<String, Object?>?) {
_handleJsonRequest(id, method, params);
} else if (id is int && _flutterRequestCompleters.containsKey(id)) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment