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

Side by Side Diff: chrome/browser/prerender/prerender_contents.cc

Issue 23658056: content: Move kHttpScheme constant into content namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 3 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/prerender/prerender_contents.h" 5 #include "chrome/browser/prerender/prerender_contents.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <functional> 8 #include <functional>
9 #include <utility> 9 #include <utility>
10 10
(...skipping 486 matching lines...) Expand 10 before | Expand all | Expand 10 after
497 it != urls.end(); ++it) { 497 it != urls.end(); ++it) {
498 if (it->icon_type == content::FaviconURL::FAVICON) { 498 if (it->icon_type == content::FaviconURL::FAVICON) {
499 icon_url_ = it->icon_url; 499 icon_url_ = it->icon_url;
500 VLOG(1) << icon_url_; 500 VLOG(1) << icon_url_;
501 return; 501 return;
502 } 502 }
503 } 503 }
504 } 504 }
505 505
506 bool PrerenderContents::AddAliasURL(const GURL& url) { 506 bool PrerenderContents::AddAliasURL(const GURL& url) {
507 const bool http = url.SchemeIs(chrome::kHttpScheme); 507 const bool http = url.SchemeIs(content::kHttpScheme);
508 const bool https = url.SchemeIs(content::kHttpsScheme); 508 const bool https = url.SchemeIs(content::kHttpsScheme);
509 if (!http && !https) { 509 if (!http && !https) {
510 DCHECK_NE(MATCH_COMPLETE_REPLACEMENT_PENDING, match_complete_status_); 510 DCHECK_NE(MATCH_COMPLETE_REPLACEMENT_PENDING, match_complete_status_);
511 Destroy(FINAL_STATUS_UNSUPPORTED_SCHEME); 511 Destroy(FINAL_STATUS_UNSUPPORTED_SCHEME);
512 return false; 512 return false;
513 } 513 }
514 if (https && !prerender_manager_->config().https_allowed) { 514 if (https && !prerender_manager_->config().https_allowed) {
515 DCHECK_NE(MATCH_COMPLETE_REPLACEMENT_PENDING, match_complete_status_); 515 DCHECK_NE(MATCH_COMPLETE_REPLACEMENT_PENDING, match_complete_status_);
516 Destroy(FINAL_STATUS_HTTPS); 516 Destroy(FINAL_STATUS_HTTPS);
517 return false; 517 return false;
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
702 702
703 bool PrerenderContents::IsCrossSiteNavigationPending() const { 703 bool PrerenderContents::IsCrossSiteNavigationPending() const {
704 if (!prerender_contents_) 704 if (!prerender_contents_)
705 return false; 705 return false;
706 return (prerender_contents_->GetSiteInstance() != 706 return (prerender_contents_->GetSiteInstance() !=
707 prerender_contents_->GetPendingSiteInstance()); 707 prerender_contents_->GetPendingSiteInstance());
708 } 708 }
709 709
710 710
711 } // namespace prerender 711 } // namespace prerender
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698