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

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

Issue 6883221: Linux: clean up the usage of "use_cups" gyp switch: (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 8 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
Index: chrome/browser/ui/webui/print_preview_handler.cc
===================================================================
--- chrome/browser/ui/webui/print_preview_handler.cc (revision 82994)
+++ chrome/browser/ui/webui/print_preview_handler.cc (working copy)
@@ -29,7 +29,7 @@
#include "printing/metafile_impl.h"
#include "printing/print_job_constants.h"
-#if defined(OS_POSIX) && !defined(OS_CHROMEOS)
+#if defined(USE_CUPS)
#include <cups/cups.h>
#include "base/file_util.h"
@@ -43,7 +43,7 @@
const char kDisableColorOption[] = "disableColorOption";
const char kSetColorAsDefault[] = "setColorAsDefault";
-#if defined(OS_POSIX) && !defined(OS_CHROMEOS)
+#if defined(USE_CUPS)
const char kColorDevice[] = "ColorDevice";
#elif defined(OS_WIN)
const char kPskColor[] = "psk:Color";
@@ -126,7 +126,7 @@
return;
}
- #if defined(OS_POSIX) && !defined(OS_CHROMEOS)
+#if defined(USE_CUPS)
FilePath ppd_file_path;
if (!file_util::CreateTemporaryFile(&ppd_file_path))
return;
@@ -148,16 +148,16 @@
ppdClose(ppd);
}
file_util::Delete(ppd_file_path, false);
- #elif defined(OS_WIN)
+#elif defined(OS_WIN)
// According to XPS 1.0 spec, only color printers have psk:Color.
// Therefore we don't need to parse the whole XML file, we just need to
// search the string. The spec can be found at:
// http://msdn.microsoft.com/en-us/windows/hardware/gg463431.
supports_color = (printer_info.printer_capabilities.find(kPskColor) !=
std::string::npos);
- #elif defined(OS_CHROMEOS)
- NOTIMPLEMENTED();
- #endif
+#else
+ NOTIMPLEMENTED();
+#endif
DictionaryValue settings_info;
settings_info.SetBoolean(kDisableColorOption, !supports_color);
« no previous file with comments | « build/linux/system.gyp ('k') | chrome/chrome.gyp » ('j') | printing/printing.gyp » ('J')

Powered by Google App Engine
This is Rietveld 408576698