use of io.flutter.vmService.VMServiceManager in project flutter-intellij by flutter.
the class VmServiceWidgetPerfProvider method setupConnection.
private void setupConnection(@NotNull VmService vmService) {
if (isDisposed || connected) {
return;
}
final VMServiceManager vmServiceManager = app.getVMServiceManager();
assert vmServiceManager != null;
connected = true;
isolateRefStreamSubscription = vmServiceManager.getCurrentFlutterIsolate((isolateRef) -> requestRepaint(When.soon), false);
vmService.addVmServiceListener(new VmServiceListenerAdapter() {
@Override
public void received(String streamId, Event event) {
onVmServiceReceived(streamId, event);
}
@Override
public void connectionClosed() {
}
});
inspectorService = InspectorService.create(app, app.getFlutterDebugProcess(), app.getVmService());
inspectorService.whenCompleteAsync((service, throwable) -> Disposer.register(this, service));
requestRepaint(When.soon);
}
use of io.flutter.vmService.VMServiceManager in project flutter-intellij by flutter.
the class FlutterViewMessages method sendDebugActive.
public static void sendDebugActive(@NotNull Project project, @NotNull FlutterApp app, @NotNull VmService vmService) {
final MessageBus bus = project.getMessageBus();
final FlutterDebugNotifier publisher = bus.syncPublisher(FLUTTER_DEBUG_TOPIC);
assert (app.getFlutterDebugProcess() != null);
final VMServiceManager vmServiceManager = new VMServiceManager(app, vmService);
Disposer.register(app.getFlutterDebugProcess().getVmServiceWrapper(), vmServiceManager);
app.setVmServices(vmService, vmServiceManager);
publisher.debugActive(new FlutterDebugEvent(app, vmService));
}
Aggregations