| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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/extensions/extension_dom_ui.h" | 5 #include "chrome/browser/extensions/extension_dom_ui.h" |
| 6 | 6 |
| 7 #include "chrome/browser/browser.h" | 7 #include "chrome/browser/browser.h" |
| 8 #include "chrome/browser/browser_list.h" | 8 #include "chrome/browser/browser_list.h" |
| 9 #include "chrome/browser/profile.h" | 9 #include "chrome/browser/profile.h" |
| 10 #include "chrome/browser/tab_contents/tab_contents.h" | 10 #include "chrome/browser/tab_contents/tab_contents.h" |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 47 | 47 |
| 48 void ExtensionDOMUI::RenderViewCreated(RenderViewHost* render_view_host) { | 48 void ExtensionDOMUI::RenderViewCreated(RenderViewHost* render_view_host) { |
| 49 ResetExtensionFunctionDispatcher(render_view_host); | 49 ResetExtensionFunctionDispatcher(render_view_host); |
| 50 } | 50 } |
| 51 | 51 |
| 52 void ExtensionDOMUI::RenderViewReused(RenderViewHost* render_view_host) { | 52 void ExtensionDOMUI::RenderViewReused(RenderViewHost* render_view_host) { |
| 53 ResetExtensionFunctionDispatcher(render_view_host); | 53 ResetExtensionFunctionDispatcher(render_view_host); |
| 54 } | 54 } |
| 55 | 55 |
| 56 void ExtensionDOMUI::ProcessDOMUIMessage(const std::string& message, | 56 void ExtensionDOMUI::ProcessDOMUIMessage(const std::string& message, |
| 57 const std::string& content, | 57 const Value* content, |
| 58 int request_id, | 58 int request_id, |
| 59 bool has_callback) { | 59 bool has_callback) { |
| 60 extension_function_dispatcher_->HandleRequest(message, content, request_id, | 60 extension_function_dispatcher_->HandleRequest(message, content, request_id, |
| 61 has_callback); | 61 has_callback); |
| 62 } | 62 } |
| 63 | 63 |
| 64 Browser* ExtensionDOMUI::GetBrowser() { | 64 Browser* ExtensionDOMUI::GetBrowser() { |
| 65 return static_cast<Browser*>(tab_contents()->delegate()); | 65 return static_cast<Browser*>(tab_contents()->delegate()); |
| 66 } | 66 } |
| 67 | 67 |
| (...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 242 if (!all_overrides->GetList(*iter, &page_overrides)) { | 242 if (!all_overrides->GetList(*iter, &page_overrides)) { |
| 243 // If it's being unregistered, it should already be in the list. | 243 // If it's being unregistered, it should already be in the list. |
| 244 NOTREACHED(); | 244 NOTREACHED(); |
| 245 continue; | 245 continue; |
| 246 } else { | 246 } else { |
| 247 UnregisterAndReplaceOverride(WideToUTF8(*iter), profile, page_overrides, | 247 UnregisterAndReplaceOverride(WideToUTF8(*iter), profile, page_overrides, |
| 248 val); | 248 val); |
| 249 } | 249 } |
| 250 } | 250 } |
| 251 } | 251 } |
| OLD | NEW |