Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1738)

Unified Diff: mojo/shell/context.cc

Issue 741453002: Make sure that Content Handled application can be connected multiple times. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Follow review Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: mojo/shell/context.cc
diff --git a/mojo/shell/context.cc b/mojo/shell/context.cc
index e1c742a8b670f734c1b825429644bb97948e8eff..b5238f9fba77771b8b7e1e0e23cfd1b2fbd46488 100644
--- a/mojo/shell/context.cc
+++ b/mojo/shell/context.cc
@@ -138,10 +138,10 @@ class Context::NativeViewportApplicationLoader
// ApplicationLoader implementation.
virtual void Load(ApplicationManager* manager,
const GURL& url,
- scoped_refptr<LoadCallbacks> callbacks) override {
- ScopedMessagePipeHandle shell_handle = callbacks->RegisterApplication();
- if (shell_handle.is_valid())
- app_.reset(new ApplicationImpl(this, shell_handle.Pass()));
+ ScopedMessagePipeHandle shell_handle,
+ LoadCallback callbacks) override {
+ DCHECK(shell_handle.is_valid());
+ app_.reset(new ApplicationImpl(this, shell_handle.Pass()));
}
virtual void OnApplicationError(ApplicationManager* manager,

Powered by Google App Engine
This is Rietveld 408576698