| Index: chrome/browser/ui/webui/devtools_ui.cc
|
| diff --git a/chrome/browser/ui/webui/devtools_ui.cc b/chrome/browser/ui/webui/devtools_ui.cc
|
| index b07982b9ad5e985010275bf1039f6e883706f5ca..abe7b73af8320e82532c6b790b1a959fa42d93dc 100644
|
| --- a/chrome/browser/ui/webui/devtools_ui.cc
|
| +++ b/chrome/browser/ui/webui/devtools_ui.cc
|
| @@ -15,9 +15,9 @@
|
| #include "content/browser/renderer_host/render_view_host.h"
|
| #include "content/public/browser/browser_thread.h"
|
| #include "content/public/browser/devtools_client_host.h"
|
| +#include "content/public/browser/devtools_http_handler.h"
|
| #include "content/public/browser/web_contents.h"
|
| #include "content/public/browser/web_ui.h"
|
| -#include "grit/devtools_resources_map.h"
|
| #include "ui/base/resource/resource_bundle.h"
|
|
|
| using content::BrowserThread;
|
| @@ -56,13 +56,9 @@ void DevToolsDataSource::StartDataRequest(const std::string& path,
|
| int request_id) {
|
| std::string filename = PathWithoutParams(path);
|
|
|
| - int resource_id = -1;
|
| - for (size_t i = 0; i < kDevtoolsResourcesSize; ++i) {
|
| - if (filename == kDevtoolsResources[i].name) {
|
| - resource_id = kDevtoolsResources[i].value;
|
| - break;
|
| - }
|
| - }
|
| +
|
| + int resource_id =
|
| + content::DevToolsHttpHandler::GetFrontendResourceId(filename);
|
|
|
| DLOG_IF(WARNING, -1 == resource_id) << "Unable to find dev tool resource: "
|
| << filename << ". If you compiled with debug_devtools=1, try running"
|
|
|