| OLD | NEW | 
|---|
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 <utility> | 8 #include <utility> | 
| 9 | 9 | 
| 10 #include "base/process_util.h" | 10 #include "base/process_util.h" | 
| (...skipping 614 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 625   for (std::vector<FaviconURL>::const_iterator it = urls.begin(); | 625   for (std::vector<FaviconURL>::const_iterator it = urls.begin(); | 
| 626        it != urls.end(); ++it) { | 626        it != urls.end(); ++it) { | 
| 627     if (it->icon_type == FaviconURL::FAVICON) { | 627     if (it->icon_type == FaviconURL::FAVICON) { | 
| 628       icon_url_ = it->icon_url; | 628       icon_url_ = it->icon_url; | 
| 629       VLOG(1) << icon_url_; | 629       VLOG(1) << icon_url_; | 
| 630       return; | 630       return; | 
| 631     } | 631     } | 
| 632   } | 632   } | 
| 633 } | 633 } | 
| 634 | 634 | 
| 635 void PrerenderContents::OnMaybeCancelPrerenderForHTML5Media() { |  | 
| 636   Destroy(FINAL_STATUS_HTML5_MEDIA); |  | 
| 637 } |  | 
| 638 |  | 
| 639 bool PrerenderContents::AddAliasURL(const GURL& url) { | 635 bool PrerenderContents::AddAliasURL(const GURL& url) { | 
| 640   if (!url.SchemeIs("http")) { | 636   if (!url.SchemeIs("http")) { | 
| 641     if (url.SchemeIs("https")) | 637     if (url.SchemeIs("https")) | 
| 642       Destroy(FINAL_STATUS_HTTPS); | 638       Destroy(FINAL_STATUS_HTTPS); | 
| 643     else | 639     else | 
| 644       Destroy(FINAL_STATUS_UNSUPPORTED_SCHEME); | 640       Destroy(FINAL_STATUS_UNSUPPORTED_SCHEME); | 
| 645     return false; | 641     return false; | 
| 646   } | 642   } | 
| 647   alias_urls_.push_back(url); | 643   alias_urls_.push_back(url); | 
| 648   return true; | 644   return true; | 
| (...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 758   //               used. | 754   //               used. | 
| 759   if (UseTabContents()) { | 755   if (UseTabContents()) { | 
| 760     if (!prerender_contents_.get()) | 756     if (!prerender_contents_.get()) | 
| 761       return NULL; | 757       return NULL; | 
| 762     return prerender_contents_->render_view_host(); | 758     return prerender_contents_->render_view_host(); | 
| 763   } | 759   } | 
| 764   return render_view_host_; | 760   return render_view_host_; | 
| 765 } | 761 } | 
| 766 | 762 | 
| 767 }  // namespace prerender | 763 }  // namespace prerender | 
| OLD | NEW | 
|---|