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

Unified Diff: sky/engine/core/frame/LocalDOMWindow.cpp

Issue 1059743004: Teach window.location.href setter to handle relative urls. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 8 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 | « no previous file | sky/examples/raw/touch-demo.sky » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/engine/core/frame/LocalDOMWindow.cpp
diff --git a/sky/engine/core/frame/LocalDOMWindow.cpp b/sky/engine/core/frame/LocalDOMWindow.cpp
index 0342914477609820b17e2d41aad3e46793752f5b..16e1da3ced33563888d3423216537dc12a9bfb3d 100644
--- a/sky/engine/core/frame/LocalDOMWindow.cpp
+++ b/sky/engine/core/frame/LocalDOMWindow.cpp
@@ -703,7 +703,7 @@ void LocalDOMWindow::setLocation(const String& urlString, SetLocationLocking loc
if (!host)
return;
mojo::URLRequestPtr request = mojo::URLRequest::New();
- request->url = urlString.toUTF8();
+ request->url = document()->completeURL(urlString).string().toUTF8();
host->services()->NavigatorHost()->RequestNavigate(
mojo::TARGET_SOURCE_NODE, request.Pass());
}
« no previous file with comments | « no previous file | sky/examples/raw/touch-demo.sky » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698