| OLD | NEW |
| 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/ui/alternate_error_tab_observer.h" | 5 #include "chrome/browser/ui/alternate_error_tab_observer.h" |
| 6 | 6 |
| 7 #include "base/prefs/pref_service.h" | 7 #include "base/prefs/pref_service.h" |
| 8 #include "chrome/browser/chrome_notification_types.h" | 8 #include "chrome/browser/chrome_notification_types.h" |
| 9 #include "chrome/browser/google/google_util.h" | 9 #include "chrome/browser/google/google_util.h" |
| 10 #include "chrome/browser/profiles/profile.h" | 10 #include "chrome/browser/profiles/profile.h" |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 92 void AlternateErrorPageTabObserver::OnAlternateErrorPagesEnabledChanged() { | 92 void AlternateErrorPageTabObserver::OnAlternateErrorPagesEnabledChanged() { |
| 93 UpdateAlternateErrorPageURL(web_contents()->GetRenderViewHost()); | 93 UpdateAlternateErrorPageURL(web_contents()->GetRenderViewHost()); |
| 94 } | 94 } |
| 95 | 95 |
| 96 void AlternateErrorPageTabObserver::UpdateAlternateErrorPageURL( | 96 void AlternateErrorPageTabObserver::UpdateAlternateErrorPageURL( |
| 97 RenderViewHost* rvh) { | 97 RenderViewHost* rvh) { |
| 98 RenderFrameHost* rfh = rvh->GetMainFrame(); | 98 RenderFrameHost* rfh = rvh->GetMainFrame(); |
| 99 rfh->Send(new ChromeViewMsg_SetAltErrorPageURL( | 99 rfh->Send(new ChromeViewMsg_SetAltErrorPageURL( |
| 100 rfh->GetRoutingID(), GetAlternateErrorPageURL())); | 100 rfh->GetRoutingID(), GetAlternateErrorPageURL())); |
| 101 } | 101 } |
| OLD | NEW |