| Index: chrome/browser/ui/webui/bug_report_ui.cc
|
| diff --git a/chrome/browser/ui/webui/bug_report_ui.cc b/chrome/browser/ui/webui/bug_report_ui.cc
|
| index c5df51a8edf9e16286bf73f2acab3e202fee1a01..93c12bde37221c20672362479807ba3c40e1f66c 100644
|
| --- a/chrome/browser/ui/webui/bug_report_ui.cc
|
| +++ b/chrome/browser/ui/webui/bug_report_ui.cc
|
| @@ -53,9 +53,7 @@ const char kScreenshotBaseUrl[] = "chrome://screenshots/";
|
| const char kCurrentScreenshotUrl[] = "chrome://screenshots/current";
|
| #if defined(OS_CHROMEOS)
|
| const char kSavedScreenshotsUrl[] = "chrome://screenshots/saved/";
|
| -
|
| -const char kScreenshotPattern[] = "*.png";
|
| -const char kScreenshotsRelativePath[] = "/Screenshots";
|
| +const char kScreenshotPattern[] = "screenshot-*.png";
|
|
|
| const size_t kMaxSavedScreenshots = 2;
|
| #endif
|
| @@ -73,11 +71,7 @@ void GetSavedScreenshots(std::vector<std::string>* saved_screenshots,
|
| return;
|
| }
|
|
|
| - // TODO(rkc): Change this to use FilePath.Append() once the cros
|
| - // issue with it is fixed
|
| - FilePath screenshots_path(fileshelf_path.value() +
|
| - std::string(kScreenshotsRelativePath));
|
| - file_util::FileEnumerator screenshots(screenshots_path, false,
|
| + file_util::FileEnumerator screenshots(fileshelf_path, false,
|
| file_util::FileEnumerator::FILES,
|
| std::string(kScreenshotPattern));
|
| FilePath screenshot = screenshots.Next();
|
| @@ -513,9 +507,9 @@ void BugReportHandler::HandleSendReport(const ListValue* list_value) {
|
| screenshot_path.erase(0, strlen(kScreenshotBaseUrl));
|
|
|
| // Get the image to send in the report.
|
| - std::vector<unsigned char> image;
|
| + ScreenshotDataPtr image_ptr;
|
| if (!screenshot_path.empty())
|
| - image = screenshot_source_->GetScreenshot(screenshot_path);
|
| + image_ptr = screenshot_source_->GetCachedScreenshot(screenshot_path);
|
|
|
| #if defined(OS_CHROMEOS)
|
| if (++i == list_value->end()) {
|
| @@ -547,7 +541,7 @@ void BugReportHandler::HandleSendReport(const ListValue* list_value) {
|
| , problem_type
|
| , page_url
|
| , description
|
| - , image
|
| + , image_ptr
|
| #if defined(OS_CHROMEOS)
|
| , user_email
|
| , send_sys_info
|
|
|