| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/debugger/devtools_http_protocol_handler.h" | 5 #include "chrome/browser/debugger/devtools_http_protocol_handler.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 58 } | 58 } |
| 59 | 59 |
| 60 void NotifyCloseListener() { | 60 void NotifyCloseListener() { |
| 61 DevToolsClientHost::NotifyCloseListener(); | 61 DevToolsClientHost::NotifyCloseListener(); |
| 62 } | 62 } |
| 63 private: | 63 private: |
| 64 // Message handling routines | 64 // Message handling routines |
| 65 void OnDispatchOnInspectorFrontend(const std::string& data) { | 65 void OnDispatchOnInspectorFrontend(const std::string& data) { |
| 66 socket_->SendOverWebSocket(data); | 66 socket_->SendOverWebSocket(data); |
| 67 } | 67 } |
| 68 virtual void FrameNavigating(const std::string& url) {} |
| 68 HttpListenSocket* socket_; | 69 HttpListenSocket* socket_; |
| 69 }; | 70 }; |
| 70 | 71 |
| 71 } // namespace | 72 } // namespace |
| 72 | 73 |
| 73 DevToolsHttpProtocolHandler::~DevToolsHttpProtocolHandler() { | 74 DevToolsHttpProtocolHandler::~DevToolsHttpProtocolHandler() { |
| 74 // Stop() must be called prior to this being called | 75 // Stop() must be called prior to this being called |
| 75 DCHECK(server_.get() == NULL); | 76 DCHECK(server_.get() == NULL); |
| 76 } | 77 } |
| 77 | 78 |
| (...skipping 350 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 428 TabStripModel* model = (*it)->tabstrip_model(); | 429 TabStripModel* model = (*it)->tabstrip_model(); |
| 429 for (int i = 0, size = model->count(); i < size; ++i) { | 430 for (int i = 0, size = model->count(); i < size; ++i) { |
| 430 NavigationController& controller = | 431 NavigationController& controller = |
| 431 model->GetTabContentsAt(i)->controller(); | 432 model->GetTabContentsAt(i)->controller(); |
| 432 if (controller.session_id().id() == session_id) | 433 if (controller.session_id().id() == session_id) |
| 433 return controller.tab_contents(); | 434 return controller.tab_contents(); |
| 434 } | 435 } |
| 435 } | 436 } |
| 436 return NULL; | 437 return NULL; |
| 437 } | 438 } |
| OLD | NEW |