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

Unified Diff: mojo/shell/mojo_url_resolver.cc

Issue 414633003: Mojo: Set a default value for the --origin command line switch. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 5 months 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
« no previous file with comments | « mojo/examples/wget/wget.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: mojo/shell/mojo_url_resolver.cc
diff --git a/mojo/shell/mojo_url_resolver.cc b/mojo/shell/mojo_url_resolver.cc
index daa91639ecc6186d23573c505471a43fb451d362..58cc101bb2c3c51e0fdd30d43d294174f698f38c 100644
--- a/mojo/shell/mojo_url_resolver.cc
+++ b/mojo/shell/mojo_url_resolver.cc
@@ -33,6 +33,11 @@ std::string MakeSharedLibraryName(const std::string& host_name) {
MojoURLResolver::MojoURLResolver() {
// Needed to treat first component of mojo URLs as host, not path.
url::AddStandardScheme("mojo");
+
+ // By default, resolve mojo URLs to files living alongside the shell.
+ base::FilePath path;
+ PathService::Get(base::DIR_MODULE, &path);
+ origin_ = net::FilePathToFileURL(path).spec();
tim (not reviewing) 2014/07/23 22:22:32 As we were talking about, probably makes sense to
}
MojoURLResolver::~MojoURLResolver() {
« no previous file with comments | « mojo/examples/wget/wget.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698