Chromium Code Reviews| Index: chrome/test/automation/automation_json_requests.cc |
| diff --git a/chrome/test/automation/automation_json_requests.cc b/chrome/test/automation/automation_json_requests.cc |
| index 7ac9369c34dbef49cfbaaef2865ad6550a75e5de..4b3e1f1a55a24255c01d8e30c717288a0df6b468 100644 |
| --- a/chrome/test/automation/automation_json_requests.cc |
| +++ b/chrome/test/automation/automation_json_requests.cc |
| @@ -4,6 +4,7 @@ |
| #include "chrome/test/automation/automation_json_requests.h" |
| +#include "base/file_path.h" |
| #include "base/scoped_ptr.h" |
| #include "base/values.h" |
| #include "base/json/json_reader.h" |
| @@ -195,6 +196,28 @@ bool SendReloadJSONRequest( |
| return SendAutomationJSONRequest(sender, dict, &reply_dict); |
| } |
| +bool SendCaptureEntirePageJSONRequest( |
| + AutomationMessageSender* sender, |
| + int browser_index, |
| + int tab_index, |
| + const FilePath& path) { |
| + DictionaryValue dict; |
| + dict.SetString("command", "GetScreenShot"); |
|
kkania
2011/03/17 18:35:11
change name here too
Joe
2011/03/18 00:33:32
Done.
|
| + dict.SetInteger("windex", browser_index); |
| + dict.SetInteger("tab_index", tab_index); |
| + dict.SetString("path", path.value()); |
| + DictionaryValue reply_dict; |
| + |
| + if (!SendAutomationJSONRequest(sender, dict, &reply_dict)) |
| + return false; |
| + |
| + bool success; |
| + if (reply_dict.GetBoolean("success", &success)) |
|
kkania
2011/03/17 18:35:11
if (!
Joe
2011/03/18 00:33:32
Done.
|
| + return false; |
| + |
| + return success; |
| +} |
| + |
| bool SendGetTabURLJSONRequest( |
| AutomationMessageSender* sender, |
| int browser_index, |