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

Unified Diff: ios/web/web_state/navigation_context_impl.mm

Issue 2838583002: Added Setters to NavigationContextImpl. (Closed)
Patch Set: Rebased Created 3 years, 7 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 | « ios/web/web_state/navigation_context_impl.h ('k') | ios/web/web_state/navigation_context_impl_unittest.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/web/web_state/navigation_context_impl.mm
diff --git a/ios/web/web_state/navigation_context_impl.mm b/ios/web/web_state/navigation_context_impl.mm
index 4d6406f8dd94c796bc1cbe30794711c3d405b6fd..39df2fa68ea4f649af5bdadf219b39e19787f8ae 100644
--- a/ios/web/web_state/navigation_context_impl.mm
+++ b/ios/web/web_state/navigation_context_impl.mm
@@ -13,6 +13,16 @@ namespace web {
// static
std::unique_ptr<NavigationContextImpl>
+NavigationContextImpl::CreateNavigationContext(WebState* web_state,
+ const GURL& url) {
+ std::unique_ptr<NavigationContextImpl> result(new NavigationContextImpl(
+ web_state, url, false /* is_same_document */, false /* is_error_page */,
+ nullptr /* response_headers */));
+ return result;
+}
+
+// static
+std::unique_ptr<NavigationContextImpl>
NavigationContextImpl::CreateNavigationContext(
WebState* web_state,
const GURL& url,
@@ -76,6 +86,19 @@ net::HttpResponseHeaders* NavigationContextImpl::GetResponseHeaders() const {
return response_headers_.get();
}
+void NavigationContextImpl::SetIsSameDocument(bool is_same_document) {
+ is_same_document_ = is_same_document;
+}
+
+void NavigationContextImpl::SetIsErrorPage(bool is_error_page) {
+ is_error_page_ = is_error_page;
+}
+
+void NavigationContextImpl::SetResponseHeaders(
+ const scoped_refptr<net::HttpResponseHeaders>& response_headers) {
+ response_headers_ = response_headers;
+}
+
NavigationContextImpl::NavigationContextImpl(
WebState* web_state,
const GURL& url,
« no previous file with comments | « ios/web/web_state/navigation_context_impl.h ('k') | ios/web/web_state/navigation_context_impl_unittest.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698