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

Unified Diff: printing/printed_document_win.cc

Issue 3474014: Printing: Remove OS_WIN ifdef in a win-only file. Remove an unused debugging (Closed)
Patch Set: Created 10 years, 3 months 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: printing/printed_document_win.cc
diff --git a/printing/printed_document_win.cc b/printing/printed_document_win.cc
index 3a57b94af0794cd3c8f2efaacda42e248a0a04d3..081bddc8c6a102618db7c41bade2cf740b5e8625 100644
--- a/printing/printed_document_win.cc
+++ b/printing/printed_document_win.cc
@@ -14,7 +14,6 @@
#include "printing/units.h"
#include "skia/ext/platform_device.h"
-#if defined(OS_WIN)
namespace {
void SimpleModifyWorldTransform(HDC context,
@@ -34,7 +33,6 @@ void DrawRect(HDC context, gfx::Rect rect) {
}
} // namespace
-#endif // OS_WIN
namespace printing {
@@ -63,32 +61,6 @@ void PrintedDocument::RenderPrintedPage(
int saved_state = SaveDC(context);
DCHECK_NE(saved_state, 0);
-#if 0
- // Debug code to visually verify margins (leaks GDI handles).
- XFORM debug_xform = { 0 };
- ModifyWorldTransform(context, &debug_xform, MWT_IDENTITY);
- // Printable area:
- SelectObject(context, CreatePen(PS_SOLID, 1, RGB(0, 0, 0)));
- SelectObject(context, CreateSolidBrush(RGB(0x90, 0x90, 0x90)));
- Rectangle(context,
- 0,
- 0,
- page_setup.printable_area().width(),
- page_setup.printable_area().height());
- // Overlay area:
- gfx::Rect debug_overlay_area(page_setup.overlay_area());
- debug_overlay_area.Offset(-page_setup.printable_area().x(),
- -page_setup.printable_area().y());
- SelectObject(context, CreateSolidBrush(RGB(0xb0, 0xb0, 0xb0)));
- DrawRect(context, debug_overlay_area);
- // Content area:
- gfx::Rect debug_content_area(content_area());
- debug_content_area.Offset(-page_setup.printable_area().x(),
- -page_setup.printable_area().y());
- SelectObject(context, CreateSolidBrush(RGB(0xd0, 0xd0, 0xd0)));
- DrawRect(context, debug_content_area);
-#endif
-
// Setup the matrix to translate and scale to the right place. Take in
// account the actual shrinking factor.
// Note that the printing output is relative to printable area of the page.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698