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

Side by Side Diff: chromeos/accelerometer/accelerometer_reader.cc

Issue 1687693003: Update AccelerometerReader Error Output (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chromeos/accelerometer/accelerometer_reader.h" 5 #include "chromeos/accelerometer/accelerometer_reader.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 217 matching lines...) Expand 10 before | Expand all | Expand 10 after
228 void AccelerometerFileReader::Initialize( 228 void AccelerometerFileReader::Initialize(
229 scoped_refptr<base::SequencedTaskRunner> sequenced_task_runner) { 229 scoped_refptr<base::SequencedTaskRunner> sequenced_task_runner) {
230 DCHECK( 230 DCHECK(
231 base::SequencedWorkerPool::GetSequenceTokenForCurrentThread().IsValid()); 231 base::SequencedWorkerPool::GetSequenceTokenForCurrentThread().IsValid());
232 task_runner_ = sequenced_task_runner; 232 task_runner_ = sequenced_task_runner;
233 233
234 // Check for accelerometer symlink which will be created by the udev rules 234 // Check for accelerometer symlink which will be created by the udev rules
235 // file on detecting the device. 235 // file on detecting the device.
236 if (base::IsDirectoryEmpty(base::FilePath(kAccelerometerDevicePath))) { 236 if (base::IsDirectoryEmpty(base::FilePath(kAccelerometerDevicePath))) {
237 if (base::SysInfo::IsRunningOnChromeOS()) { 237 if (base::SysInfo::IsRunningOnChromeOS()) {
238 LOG(ERROR) << "Accelerometer device directory is empty at " 238 LOG(WARNING) << "Accelerometer device directory is empty at "
239 << kAccelerometerDevicePath; 239 << kAccelerometerDevicePath;
240 } 240 }
241 return; 241 return;
242 } 242 }
243 if (!base::PathExists(base::FilePath(kAccelerometerTriggerPath))) { 243 if (!base::PathExists(base::FilePath(kAccelerometerTriggerPath))) {
244 if (base::SysInfo::IsRunningOnChromeOS()) { 244 if (base::SysInfo::IsRunningOnChromeOS()) {
245 LOG(ERROR) << "Accelerometer trigger does not exist at" 245 LOG(ERROR) << "Accelerometer trigger does not exist at"
246 << kAccelerometerTriggerPath; 246 << kAccelerometerTriggerPath;
247 } 247 }
248 return; 248 return;
249 } 249 }
(...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after
501 } 501 }
502 502
503 AccelerometerReader::AccelerometerReader() 503 AccelerometerReader::AccelerometerReader()
504 : accelerometer_file_reader_(new AccelerometerFileReader()) { 504 : accelerometer_file_reader_(new AccelerometerFileReader()) {
505 } 505 }
506 506
507 AccelerometerReader::~AccelerometerReader() { 507 AccelerometerReader::~AccelerometerReader() {
508 } 508 }
509 509
510 } // namespace chromeos 510 } // namespace chromeos
OLDNEW
« 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