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

Issue 2847253002: [Device Service] Add RELATIVE_ORIENTATION sensor type to //device/generic_sensor (Closed)

Created:
3 years, 7 months ago by juncai
Modified:
3 years, 7 months ago
CC:
Aaron Boodman, abarth-chromium, agrieve+watch_chromium.org, shalamov, chromium-reviews, darin (slow to review), Mikhail, mlamouri+watch-sensors_chromium.org, qsr+mojo_chromium.org, riju_, timvolodine, viettrungluu+watch_chromium.org, wanming.lin, yzshen+watch_chromium.org
Target Ref:
refs/heads/master
Project:
chromium
Visibility:
Public.

Description

[Device Service] Add RELATIVE_ORIENTATION sensor type to //device/generic_sensor This is one of the CLs that make //content/renderer/device_sensors depend on //device/generic_sensor/public instead of //device/sensors/public. In order to do that, //device/generic_sensor needs to support RELATIVE_ORIENTATION sensor type since it is used by device orientation event. This CL adds RELATIVE_ORIENTATION sensor implementation on Android to //device/generic_sensor. BUG=721427 Review-Url: https://codereview.chromium.org/2847253002 Cr-Commit-Position: refs/heads/master@{#471533} Committed: https://chromium.googlesource.com/chromium/src/+/52b6764cf200aea49a5c09e221eb612394aabba7

Patch Set 1 : add RELATIVE_ORIENTATION sensor type to //device/generic_sensor on Android #

Patch Set 2 : Mac #

Patch Set 3 : address comments, added relative orientation sensor on Win, added documentation #

Patch Set 4 : updated generic_sensor_consts.h #

Total comments: 2

Patch Set 5 : added tests for new sensors #

Total comments: 8

Patch Set 6 : address nits #

Total comments: 11

Patch Set 7 : rebase #

Patch Set 8 : fix typo #

Unified diffs Side-by-side diffs Delta from patch set Stats (+127 lines, -29 lines) Patch
M device/generic_sensor/android/java/src/org/chromium/device/sensors/PlatformSensorProvider.java View 2 chunks +2 lines, -1 line 0 comments Download
M device/generic_sensor/android/junit/src/org/chromium/device/sensors/PlatformSensorAndProviderTest.java View 1 chunk +2 lines, -0 lines 0 comments Download
M device/generic_sensor/platform_sensor_provider_unittest.cc View 1 2 3 4 5 1 chunk +69 lines, -27 lines 0 comments Download
M device/generic_sensor/public/cpp/sensor_reading.h View 1 2 1 chunk +50 lines, -0 lines 0 comments Download
M device/generic_sensor/public/interfaces/sensor.mojom View 1 2 2 chunks +4 lines, -1 line 0 comments Download

Messages

Total messages: 81 (49 generated)
juncai
Please take a look.
3 years, 7 months ago (2017-05-01 17:22:26 UTC) #12
Reilly Grant (use Gerrit)
When looking at implementing SensorType::ACCELEROMETER we considered using the Sudden Motion Sensor on macOS however ...
3 years, 7 months ago (2017-05-01 18:22:05 UTC) #13
juncai
On 2017/05/01 18:22:05, Reilly Grant wrote: > When looking at implementing SensorType::ACCELEROMETER we considered using ...
3 years, 7 months ago (2017-05-02 01:11:23 UTC) #21
shalamov
https://codereview.chromium.org/2847253002/diff/60001/device/generic_sensor/platform_sensor_reader_win.cc File device/generic_sensor/platform_sensor_reader_win.cc (right): https://codereview.chromium.org/2847253002/diff/60001/device/generic_sensor/platform_sensor_reader_win.cc#newcode197 device/generic_sensor/platform_sensor_reader_win.cc:197: // RelativeOrientation sensor reader initialization parameters. Could you please ...
3 years, 7 months ago (2017-05-02 06:22:49 UTC) #23
juncai
https://codereview.chromium.org/2847253002/diff/60001/device/generic_sensor/platform_sensor_reader_win.cc File device/generic_sensor/platform_sensor_reader_win.cc (right): https://codereview.chromium.org/2847253002/diff/60001/device/generic_sensor/platform_sensor_reader_win.cc#newcode197 device/generic_sensor/platform_sensor_reader_win.cc:197: // RelativeOrientation sensor reader initialization parameters. On 2017/05/02 06:22:49, ...
3 years, 7 months ago (2017-05-02 18:23:08 UTC) #26
Reilly Grant (use Gerrit)
lgtm with nits https://codereview.chromium.org/2847253002/diff/80001/device/generic_sensor/platform_sensor_accelerometer_mac.cc File device/generic_sensor/platform_sensor_accelerometer_mac.cc (right): https://codereview.chromium.org/2847253002/diff/80001/device/generic_sensor/platform_sensor_accelerometer_mac.cc#newcode23 device/generic_sensor/platform_sensor_accelerometer_mac.cc:23: DCHECK_EQ(type, mojom::SensorType::ACCELEROMETER); If this is the ...
3 years, 7 months ago (2017-05-02 23:23:32 UTC) #31
juncai
mark@chromium.org: Please review changes in device/generic_sensor/DEPS that adds '+third_party/sudden_motion_sensor' dcheng@chromium.org: Please do a security review ...
3 years, 7 months ago (2017-05-03 00:56:51 UTC) #35
Mikhail
https://codereview.chromium.org/2847253002/diff/100001/device/generic_sensor/platform_sensor_accelerometer_mac.cc File device/generic_sensor/platform_sensor_accelerometer_mac.cc (right): https://codereview.chromium.org/2847253002/diff/100001/device/generic_sensor/platform_sensor_accelerometer_mac.cc#newcode28 device/generic_sensor/platform_sensor_accelerometer_mac.cc:28: return mojom::ReportingMode::ON_CHANGE; so, does the accelerometer give updated values ...
3 years, 7 months ago (2017-05-03 07:47:46 UTC) #39
juncai
https://codereview.chromium.org/2847253002/diff/100001/device/generic_sensor/platform_sensor_accelerometer_mac.cc File device/generic_sensor/platform_sensor_accelerometer_mac.cc (right): https://codereview.chromium.org/2847253002/diff/100001/device/generic_sensor/platform_sensor_accelerometer_mac.cc#newcode28 device/generic_sensor/platform_sensor_accelerometer_mac.cc:28: return mojom::ReportingMode::ON_CHANGE; On 2017/05/03 07:47:46, Mikhail wrote: > so, ...
3 years, 7 months ago (2017-05-03 17:39:18 UTC) #40
juncai
https://codereview.chromium.org/2847253002/diff/100001/device/generic_sensor/platform_sensor_accelerometer_mac.cc File device/generic_sensor/platform_sensor_accelerometer_mac.cc (right): https://codereview.chromium.org/2847253002/diff/100001/device/generic_sensor/platform_sensor_accelerometer_mac.cc#newcode28 device/generic_sensor/platform_sensor_accelerometer_mac.cc:28: return mojom::ReportingMode::ON_CHANGE; On 2017/05/03 07:47:46, Mikhail wrote: > so, ...
3 years, 7 months ago (2017-05-03 18:13:03 UTC) #41
Mikhail
lgtm
3 years, 7 months ago (2017-05-03 18:43:18 UTC) #44
dcheng
Btw, please don't TBR changes like this, it's not really a non-trivial change since it's ...
3 years, 7 months ago (2017-05-03 20:58:53 UTC) #45
Reilly Grant (use Gerrit)
On 2017/05/03 20:58:53, dcheng wrote: > Btw, please don't TBR changes like this, it's not ...
3 years, 7 months ago (2017-05-03 21:20:24 UTC) #47
dcheng
On 2017/05/03 21:20:24, Reilly Grant wrote: > On 2017/05/03 20:58:53, dcheng wrote: > > Btw, ...
3 years, 7 months ago (2017-05-03 22:15:48 UTC) #48
Chris Palmer
> The existing //device/sensor code also polls at 60Hz. I think that this is an ...
3 years, 7 months ago (2017-05-03 22:19:16 UTC) #49
Reilly Grant (use Gerrit)
On 2017/05/03 22:19:16, Chris Palmer wrote: > > The existing //device/sensor code also polls at ...
3 years, 7 months ago (2017-05-03 22:48:21 UTC) #51
shalamov
https://codereview.chromium.org/2847253002/diff/100001/device/generic_sensor/platform_sensor_accelerometer_mac.cc File device/generic_sensor/platform_sensor_accelerometer_mac.cc (right): https://codereview.chromium.org/2847253002/diff/100001/device/generic_sensor/platform_sensor_accelerometer_mac.cc#newcode28 device/generic_sensor/platform_sensor_accelerometer_mac.cc:28: return mojom::ReportingMode::ON_CHANGE; On 2017/05/03 17:39:18, juncai wrote: > On ...
3 years, 7 months ago (2017-05-04 06:53:46 UTC) #52
juncai
https://codereview.chromium.org/2847253002/diff/100001/device/generic_sensor/platform_sensor_accelerometer_mac.cc File device/generic_sensor/platform_sensor_accelerometer_mac.cc (right): https://codereview.chromium.org/2847253002/diff/100001/device/generic_sensor/platform_sensor_accelerometer_mac.cc#newcode28 device/generic_sensor/platform_sensor_accelerometer_mac.cc:28: return mojom::ReportingMode::ON_CHANGE; On 2017/05/04 06:53:46, shalamov wrote: > On ...
3 years, 7 months ago (2017-05-04 17:51:09 UTC) #53
palmer
Oops, sorry, I mis-clicked and clicked the Close button by accident!
3 years, 7 months ago (2017-05-05 22:22:43 UTC) #56
Mikhail
This CL does most of the work for enabling https://w3c.github.io/orientation-sensor/#relativeorientationsensor-interface , would be great to ...
3 years, 7 months ago (2017-05-10 13:06:30 UTC) #57
dcheng
On 2017/05/10 13:06:30, Mikhail wrote: > This CL does most of the work for enabling ...
3 years, 7 months ago (2017-05-10 17:35:28 UTC) #58
palmer
Following this chain of links: https://w3c.github.io/orientation-sensor/#usecases-requirements https://w3c.github.io/motion-sensors/#usecases-and-requirements https://w3c.github.io/motion-sensors/#security-and-privacy https://www.w3.org/TR/generic-sensor/#security-and-privacy I'm left with the impression that ...
3 years, 7 months ago (2017-05-12 00:24:19 UTC) #60
Reilly Grant (use Gerrit)
On 2017/05/12 00:24:19, palmer wrote: > Following this chain of links: > > https://w3c.github.io/orientation-sensor/#usecases-requirements > ...
3 years, 7 months ago (2017-05-12 00:46:08 UTC) #61
scheib
> So that this refactoring work is not blocked do we agree that the intent ...
3 years, 7 months ago (2017-05-12 06:13:24 UTC) #62
palmer
Okay, IPC security LGTM.
3 years, 7 months ago (2017-05-12 21:27:56 UTC) #63
dcheng
So just to be clear, does this mean the //device/sensors implementation is going away at ...
3 years, 7 months ago (2017-05-12 21:32:25 UTC) #64
juncai
On 2017/05/12 21:32:25, dcheng wrote: > So just to be clear, does this mean the ...
3 years, 7 months ago (2017-05-12 21:43:25 UTC) #65
dcheng
ok, lgtm in that case. thanks
3 years, 7 months ago (2017-05-12 21:46:51 UTC) #66
juncai
reillyg@, please take another look. I did some changes as following: 1. Removed RELATIVE_ORIENTATION sensor ...
3 years, 7 months ago (2017-05-13 00:36:54 UTC) #74
Reilly Grant (use Gerrit)
lgtm, thanks for breaking this up
3 years, 7 months ago (2017-05-13 00:43:00 UTC) #75
commit-bot: I haz the power
CQ is trying da patch. Follow status at: https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2847253002/140001
3 years, 7 months ago (2017-05-13 00:55:51 UTC) #78
commit-bot: I haz the power
3 years, 7 months ago (2017-05-13 01:45:24 UTC) #81
Message was sent while issue was closed.
Committed patchset #8 (id:140001) as
https://chromium.googlesource.com/chromium/src/+/52b6764cf200aea49a5c09e221eb...

Powered by Google App Engine
This is Rietveld 408576698