We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 91ee84e commit 69f3720Copy full SHA for 69f3720
lib/flutter_single_instance.dart
@@ -55,6 +55,11 @@ abstract class FlutterSingleInstance {
55
@protected
56
FlutterSingleInstance.internal();
57
58
+ /// The port used for the RPC server receiving focus requests.
59
+ ///
60
+ /// Defaults to `0`, letting the OS choose a random port.
61
+ static int port = 0;
62
+
63
Server? _server;
64
Instance? _instance;
65
@@ -209,7 +214,7 @@ abstract class FlutterSingleInstance {
209
214
),
210
215
);
211
216
212
- await _server!.serve(port: 0);
217
+ await _server!.serve(port: port);
213
218
219
logger.finest("RPC server started on port ${_server!.port}");
220
0 commit comments