Merge pull request #2755 from abarth/mojo_shell_bool

Add a bool to indicate whether we're in MojoShell
This commit is contained in:
Adam Barth
2016-03-17 22:12:58 -07:00

View File

@@ -48,6 +48,9 @@ class MojoShell {
}
final ApplicationConnection _embedderConnection = _initEmbedderConnection();
/// Whether [connectToApplication] is able to connect to other applications.
bool get canConnectToOtherApplications => _shell != null;
/// Attempts to connect to an application via the Mojo shell.
ApplicationConnection connectToApplication(String url) {
if (_shell == null)