| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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/ui/browser.h" | 5 #include "chrome/browser/ui/browser.h" |
| 6 | 6 |
| 7 #if defined(OS_WIN) | 7 #if defined(OS_WIN) |
| 8 #include <windows.h> | 8 #include <windows.h> |
| 9 #include <shellapi.h> | 9 #include <shellapi.h> |
| 10 #endif // defined(OS_WIN) | 10 #endif // defined(OS_WIN) |
| (...skipping 1389 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1400 return window_->GetExtraRenderViewHeight(); | 1400 return window_->GetExtraRenderViewHeight(); |
| 1401 } | 1401 } |
| 1402 | 1402 |
| 1403 void Browser::ViewSourceForTab(WebContents* source, const GURL& page_url) { | 1403 void Browser::ViewSourceForTab(WebContents* source, const GURL& page_url) { |
| 1404 DCHECK(source); | 1404 DCHECK(source); |
| 1405 chrome::ViewSource(this, source); | 1405 chrome::ViewSource(this, source); |
| 1406 } | 1406 } |
| 1407 | 1407 |
| 1408 void Browser::ViewSourceForFrame(WebContents* source, | 1408 void Browser::ViewSourceForFrame(WebContents* source, |
| 1409 const GURL& frame_url, | 1409 const GURL& frame_url, |
| 1410 const std::string& frame_content_state) { | 1410 const content::PageState& frame_page_state) { |
| 1411 DCHECK(source); | 1411 DCHECK(source); |
| 1412 chrome::ViewSource(this, source, frame_url, frame_content_state); | 1412 chrome::ViewSource(this, source, frame_url, frame_page_state); |
| 1413 } | 1413 } |
| 1414 | 1414 |
| 1415 void Browser::ShowRepostFormWarningDialog(WebContents* source) { | 1415 void Browser::ShowRepostFormWarningDialog(WebContents* source) { |
| 1416 TabModalConfirmDialog::Create(new RepostFormWarningController(source), | 1416 TabModalConfirmDialog::Create(new RepostFormWarningController(source), |
| 1417 source); | 1417 source); |
| 1418 } | 1418 } |
| 1419 | 1419 |
| 1420 bool Browser::ShouldCreateWebContents( | 1420 bool Browser::ShouldCreateWebContents( |
| 1421 WebContents* web_contents, | 1421 WebContents* web_contents, |
| 1422 int route_id, | 1422 int route_id, |
| (...skipping 806 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2229 if (contents && !allow_js_access) { | 2229 if (contents && !allow_js_access) { |
| 2230 contents->web_contents()->GetController().LoadURL( | 2230 contents->web_contents()->GetController().LoadURL( |
| 2231 target_url, | 2231 target_url, |
| 2232 content::Referrer(), | 2232 content::Referrer(), |
| 2233 content::PAGE_TRANSITION_LINK, | 2233 content::PAGE_TRANSITION_LINK, |
| 2234 std::string()); // No extra headers. | 2234 std::string()); // No extra headers. |
| 2235 } | 2235 } |
| 2236 | 2236 |
| 2237 return contents != NULL; | 2237 return contents != NULL; |
| 2238 } | 2238 } |
| OLD | NEW |