Chromium Code Reviews| Index: chrome/test/chromedriver/chrome_impl.h |
| diff --git a/chrome/test/chromedriver/chrome_impl.h b/chrome/test/chromedriver/chrome_impl.h |
| index abebb060d0df05fa398df425d7ac95ce9cc9da97..a562db8747199cb5d2945a563047b3aed94edeba 100644 |
| --- a/chrome/test/chromedriver/chrome_impl.h |
| +++ b/chrome/test/chromedriver/chrome_impl.h |
| @@ -17,11 +17,13 @@ |
| #include "chrome/test/chromedriver/net/sync_websocket_factory.h" |
| namespace base { |
| +class DictionaryValue; |
| class ListValue; |
| class Value; |
| } |
| class DevToolsClient; |
| +class DomTracker; |
| class Status; |
| class URLRequestContextGetter; |
| @@ -38,11 +40,17 @@ class ChromeImpl : public Chrome { |
| // Overridden from Chrome: |
| virtual Status Load(const std::string& url) OVERRIDE; |
| - virtual Status EvaluateScript(const std::string& expression, |
| + virtual Status EvaluateScript(const std::string& frame, |
|
frankf
2012/12/20 19:23:53
I know it's not convention in C++ to have a doc fo
kkania
2013/01/08 18:30:11
I don't use too many comments, but I think it migh
|
| + const std::string& expression, |
| scoped_ptr<base::Value>* result) OVERRIDE; |
| - virtual Status CallFunction(const std::string& function, |
| + virtual Status CallFunction(const std::string& frame, |
| + const std::string& function, |
| const base::ListValue& args, |
| scoped_ptr<base::Value>* result) OVERRIDE; |
| + virtual Status GetFrameByFunction(const std::string& frame, |
| + const std::string& function, |
| + const base::ListValue& args, |
| + std::string* out_frame) OVERRIDE; |
| virtual Status Quit() OVERRIDE; |
| private: |
| @@ -51,6 +59,7 @@ class ChromeImpl : public Chrome { |
| base::ScopedTempDir user_data_dir_; |
| int port_; |
| SyncWebSocketFactory socket_factory_; |
| + scoped_ptr<DomTracker> dom_tracker_; |
| scoped_ptr<DevToolsClient> client_; |
| }; |
| @@ -58,9 +67,28 @@ namespace internal { |
| Status ParsePagesInfo(const std::string& data, |
| std::list<std::string>* debugger_urls); |
| +enum EvaluateScriptReturnType { |
| + ReturnByValue, |
| + ReturnByObject |
| +}; |
| Status EvaluateScript(DevToolsClient* client, |
| + int context_id, |
| const std::string& expression, |
| - scoped_ptr<base::Value>* result); |
| + EvaluateScriptReturnType return_type, |
| + scoped_ptr<base::DictionaryValue>* result); |
| +Status EvaluateScriptAndGetObject(DevToolsClient* client, |
| + int context_id, |
| + const std::string& expression, |
| + std::string* object_id); |
| +Status EvaluateScriptAndGetValue(DevToolsClient* client, |
| + int context_id, |
| + const std::string& expression, |
| + scoped_ptr<base::Value>* result); |
| +Status GetNodeIdFromFunction(DevToolsClient* client, |
| + int context_id, |
| + const std::string& function, |
| + const base::ListValue& args, |
| + int* node_id); |
| } // namespace internal |