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

Unified Diff: chrome/browser/metrics/metrics_log_chromeos.cc

Issue 232173003: ozone: Protect X11-specific code in chrome/browser/metrics (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add // defined(USE_X11) Created 6 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
« 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: chrome/browser/metrics/metrics_log_chromeos.cc
diff --git a/chrome/browser/metrics/metrics_log_chromeos.cc b/chrome/browser/metrics/metrics_log_chromeos.cc
index 5fc376b90571efb6839c540aadafabf95f786e74..55dcc62fdfd4451886f83bd3fa72eb59e9dc0025 100644
--- a/chrome/browser/metrics/metrics_log_chromeos.cc
+++ b/chrome/browser/metrics/metrics_log_chromeos.cc
@@ -15,9 +15,12 @@
#include "device/bluetooth/bluetooth_adapter_factory.h"
#include "device/bluetooth/bluetooth_device.h"
#include "ui/events/event_utils.h"
-#include "ui/events/x/touch_factory_x11.h"
#include "ui/gfx/screen.h"
+#if defined(USE_X11)
+#include "ui/events/x/touch_factory_x11.h"
+#endif // defined(USE_X11)
+
using metrics::ChromeUserMetricsExtension;
using metrics::PerfDataProto;
using metrics::SystemProfileProto;
@@ -63,6 +66,7 @@ PairedDevice::Type AsBluetoothDeviceType(
}
void WriteExternalTouchscreensProto(SystemProfileProto::Hardware* hardware) {
+#if defined(USE_X11)
std::set<std::pair<int, int> > touchscreen_ids =
ui::TouchFactory::GetInstance()->GetTouchscreenIds();
for (std::set<std::pair<int, int> >::iterator it = touchscreen_ids.begin();
@@ -73,6 +77,7 @@ void WriteExternalTouchscreensProto(SystemProfileProto::Hardware* hardware) {
touchscreen->set_vendor_id(it->first);
touchscreen->set_product_id(it->second);
}
+#endif // defined(USE_X11)
}
} // namespace
« 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