OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/api/execute_code_function.h" | 5 #include "chrome/browser/extensions/api/execute_code_function.h" |
6 | 6 |
7 #include "chrome/browser/extensions/api/tabs/tabs_constants.h" | 7 #include "chrome/browser/extensions/api/tabs/tabs_constants.h" |
8 #include "chrome/browser/extensions/script_executor.h" | 8 #include "chrome/browser/extensions/script_executor.h" |
9 #include "chrome/common/extensions/api/i18n/default_locale_handler.h" | 9 #include "chrome/common/extensions/api/i18n/default_locale_handler.h" |
10 #include "chrome/common/extensions/extension_file_util.h" | 10 #include "chrome/common/extensions/extension_file_util.h" |
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
165 resource_, base::Bind(&ExecuteCodeFunction::DidLoadFile, this))); | 165 resource_, base::Bind(&ExecuteCodeFunction::DidLoadFile, this))); |
166 file_reader->Start(); | 166 file_reader->Start(); |
167 | 167 |
168 return true; | 168 return true; |
169 } | 169 } |
170 | 170 |
171 void ExecuteCodeFunction::OnExecuteCodeFinished( | 171 void ExecuteCodeFunction::OnExecuteCodeFinished( |
172 const std::string& error, | 172 const std::string& error, |
173 int32 on_page_id, | 173 int32 on_page_id, |
174 const GURL& on_url, | 174 const GURL& on_url, |
175 const ListValue& result) { | 175 const base::ListValue& result) { |
176 if (!error.empty()) | 176 if (!error.empty()) |
177 SetError(error); | 177 SetError(error); |
178 | 178 |
179 SendResponse(error.empty()); | 179 SendResponse(error.empty()); |
180 } | 180 } |
181 | 181 |
182 } // namespace extensions | 182 } // namespace extensions |
OLD | NEW |