Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(413)

Unified Diff: chrome/browser/ui/webui/bug_report_ui.cc

Issue 8523022: Change snasphotting API to take in a bounds Rect (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Nicer diff Created 9 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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 d9abc7e72259f7849e5f585d1a9b37e337fb25e0..e079ee179543b60caf0097a9734bc97b7df724b2 100644
--- a/chrome/browser/ui/webui/bug_report_ui.cc
+++ b/chrome/browser/ui/webui/bug_report_ui.cc
@@ -139,8 +139,11 @@ void ShowHtmlBugReportView(Browser* browser,
last_screenshot_png->clear();
gfx::NativeWindow native_window = browser->window()->GetNativeHandle();
- BugReportUtil::SetScreenshotSize(
- browser::GrabWindowSnapshot(native_window, last_screenshot_png));
Nico 2011/11/15 17:10:09 nit: I liked the old interface better for the use
+ gfx::Rect window_bounds = browser->window()->GetBounds();
+ bool success = browser::GrabWindowSnapshot(native_window,
+ last_screenshot_png,
+ window_bounds);
sky 2011/11/15 16:58:08 Don't you need to convert window_bounds to have an
+ BugReportUtil::SetScreenshotSize(success ? window_bounds : gfx::Rect());
std::string bug_report_url = std::string(chrome::kChromeUIBugReportURL) +
"#" + base::IntToString(browser->active_index()) +

Powered by Google App Engine
This is Rietveld 408576698