| 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 1532 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1543 | 1543 |
| 1544 chrome::ShowHungRendererDialog(source); | 1544 chrome::ShowHungRendererDialog(source); |
| 1545 } | 1545 } |
| 1546 | 1546 |
| 1547 void Browser::RendererResponsive(WebContents* source) { | 1547 void Browser::RendererResponsive(WebContents* source) { |
| 1548 chrome::HideHungRendererDialog(source); | 1548 chrome::HideHungRendererDialog(source); |
| 1549 } | 1549 } |
| 1550 | 1550 |
| 1551 void Browser::WorkerCrashed(WebContents* source) { | 1551 void Browser::WorkerCrashed(WebContents* source) { |
| 1552 SimpleAlertInfoBarDelegate::Create( | 1552 SimpleAlertInfoBarDelegate::Create( |
| 1553 InfoBarService::FromWebContents(source), InfoBarDelegate::kNoIconID, | 1553 InfoBarService::FromWebContents(source), |
| 1554 infobars::InfoBarDelegate::kNoIconID, |
| 1554 l10n_util::GetStringUTF16(IDS_WEBWORKER_CRASHED_PROMPT), true); | 1555 l10n_util::GetStringUTF16(IDS_WEBWORKER_CRASHED_PROMPT), true); |
| 1555 } | 1556 } |
| 1556 | 1557 |
| 1557 void Browser::DidNavigateMainFramePostCommit(WebContents* web_contents) { | 1558 void Browser::DidNavigateMainFramePostCommit(WebContents* web_contents) { |
| 1558 if (web_contents == tab_strip_model_->GetActiveWebContents()) | 1559 if (web_contents == tab_strip_model_->GetActiveWebContents()) |
| 1559 UpdateBookmarkBarState(BOOKMARK_BAR_STATE_CHANGE_TAB_STATE); | 1560 UpdateBookmarkBarState(BOOKMARK_BAR_STATE_CHANGE_TAB_STATE); |
| 1560 } | 1561 } |
| 1561 | 1562 |
| 1562 void Browser::DidNavigateToPendingEntry(WebContents* web_contents) { | 1563 void Browser::DidNavigateToPendingEntry(WebContents* web_contents) { |
| 1563 if (web_contents == tab_strip_model_->GetActiveWebContents()) | 1564 if (web_contents == tab_strip_model_->GetActiveWebContents()) |
| (...skipping 846 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2410 if (contents && !allow_js_access) { | 2411 if (contents && !allow_js_access) { |
| 2411 contents->web_contents()->GetController().LoadURL( | 2412 contents->web_contents()->GetController().LoadURL( |
| 2412 target_url, | 2413 target_url, |
| 2413 content::Referrer(), | 2414 content::Referrer(), |
| 2414 content::PAGE_TRANSITION_LINK, | 2415 content::PAGE_TRANSITION_LINK, |
| 2415 std::string()); // No extra headers. | 2416 std::string()); // No extra headers. |
| 2416 } | 2417 } |
| 2417 | 2418 |
| 2418 return contents != NULL; | 2419 return contents != NULL; |
| 2419 } | 2420 } |
| OLD | NEW |