| Index: mojo/application/public/cpp/lib/application_impl.cc
|
| diff --git a/mojo/application/public/cpp/lib/application_impl.cc b/mojo/application/public/cpp/lib/application_impl.cc
|
| index 31da8113af0e10991022655ffdc0df803a6d685b..6d2fb46b4c652ae41c33392a52908568d9abcded 100644
|
| --- a/mojo/application/public/cpp/lib/application_impl.cc
|
| +++ b/mojo/application/public/cpp/lib/application_impl.cc
|
| @@ -86,11 +86,9 @@ scoped_ptr<ApplicationConnection>
|
| return registry.Pass();
|
| }
|
|
|
| -void ApplicationImpl::Initialize(ShellPtr shell, const mojo::String& url) {
|
| - shell_ = shell.Pass();
|
| - shell_.set_connection_error_handler([this]() { OnConnectionError(); });
|
| - url_ = url;
|
| - delegate_->Initialize(this);
|
| +void ApplicationImpl::WaitForInitialize() {
|
| + DCHECK(!shell_.is_bound());
|
| + binding_.WaitForIncomingMethodCall();
|
| }
|
|
|
| void ApplicationImpl::Quit() {
|
| @@ -104,6 +102,13 @@ void ApplicationImpl::Quit() {
|
| }
|
| }
|
|
|
| +void ApplicationImpl::Initialize(ShellPtr shell, const mojo::String& url) {
|
| + shell_ = shell.Pass();
|
| + shell_.set_connection_error_handler([this]() { OnConnectionError(); });
|
| + url_ = url;
|
| + delegate_->Initialize(this);
|
| +}
|
| +
|
| void ApplicationImpl::AcceptConnection(
|
| const String& requestor_url,
|
| InterfaceRequest<ServiceProvider> services,
|
|
|