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

Issue 2330943002: [Sensors] Handle default sensor configuration (Closed)

Created:
4 years, 3 months ago by Mikhail
Modified:
4 years, 3 months ago
CC:
chromium-reviews, qsr+mojo_chromium.org, viettrungluu+watch_chromium.org, yzshen+watch_chromium.org, abarth-chromium, Aaron Boodman, blink-reviews, darin (slow to review)
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Sensors] Handle default sensor configuration This patch provides platform sensor's default configuration to the Blink side at 'SensorProxy' initialization stage. Default configuration will be used for sensors construction by default, e.g. 'let sensor = new AmbientLightSensor();'. A few related changes are added as well: - Rename 'SensorReadBuffer' to 'SensorInitParams' - Remove repeated code calling 'startListening()' from 'Sensor::onSensorInitialized()' - Call 'reset()' for all 'SensorProxy' members from 'SensorProxy::handleSensorError()' BUG=606766 Committed: https://crrev.com/b49349c6d3c4e7875fbb3ed8e3535f71006e444c Cr-Commit-Position: refs/heads/master@{#418528}

Patch Set 1 #

Total comments: 8

Patch Set 2 : Comments from Tim #

Patch Set 3 : Comments from Alex #

Patch Set 4 : Rebased #

Unified diffs Side-by-side diffs Delta from patch set Stats (+61 lines, -37 lines) Patch
M device/generic_sensor/platform_sensor_provider_base.cc View 1 chunk +1 line, -1 line 0 comments Download
M device/generic_sensor/public/interfaces/sensor_provider.mojom View 2 chunks +8 lines, -5 lines 0 comments Download
M device/generic_sensor/sensor_provider_impl.cc View 1 2 3 3 chunks +8 lines, -7 lines 0 comments Download
M third_party/WebKit/Source/modules/sensor/Sensor.h View 1 chunk +2 lines, -1 line 0 comments Download
M third_party/WebKit/Source/modules/sensor/Sensor.cpp View 1 2 chunks +14 lines, -15 lines 0 comments Download
M third_party/WebKit/Source/modules/sensor/SensorProxy.h View 1 2 3 chunks +6 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/modules/sensor/SensorProxy.cpp View 1 2 2 chunks +22 lines, -6 lines 0 comments Download

Messages

Total messages: 33 (18 generated)
Mikhail
PTAL
4 years, 3 months ago (2016-09-12 10:01:44 UTC) #5
haraken
In terms of implementation, WebKit/Source/modules/ LGTM.
4 years, 3 months ago (2016-09-12 11:39:24 UTC) #8
timvolodine
https://codereview.chromium.org/2330943002/diff/1/device/generic_sensor/public/interfaces/sensor_provider.mojom File device/generic_sensor/public/interfaces/sensor_provider.mojom (right): https://codereview.chromium.org/2330943002/diff/1/device/generic_sensor/public/interfaces/sensor_provider.mojom#newcode20 device/generic_sensor/public/interfaces/sensor_provider.mojom:20: SensorConfiguration default_configuration; curious how this is described in spec: ...
4 years, 3 months ago (2016-09-12 16:37:08 UTC) #9
Mikhail
https://codereview.chromium.org/2330943002/diff/1/device/generic_sensor/public/interfaces/sensor_provider.mojom File device/generic_sensor/public/interfaces/sensor_provider.mojom (right): https://codereview.chromium.org/2330943002/diff/1/device/generic_sensor/public/interfaces/sensor_provider.mojom#newcode20 device/generic_sensor/public/interfaces/sensor_provider.mojom:20: SensorConfiguration default_configuration; On 2016/09/12 16:37:08, timvolodine wrote: > curious ...
4 years, 3 months ago (2016-09-12 17:08:10 UTC) #10
Mikhail
Please take a look
4 years, 3 months ago (2016-09-12 18:52:46 UTC) #11
Tom Sepez
mojom lgtm
4 years, 3 months ago (2016-09-12 22:01:19 UTC) #13
shalamov
https://codereview.chromium.org/2330943002/diff/1/third_party/WebKit/Source/modules/sensor/SensorProxy.h File third_party/WebKit/Source/modules/sensor/SensorProxy.h (right): https://codereview.chromium.org/2330943002/diff/1/third_party/WebKit/Source/modules/sensor/SensorProxy.h#newcode65 third_party/WebKit/Source/modules/sensor/SensorProxy.h:65: const device::mojom::blink::SensorConfiguration* defaultConfig() const { return m_defaultConfig.get(); } DCHECK(isInitialized()); ...
4 years, 3 months ago (2016-09-13 10:52:59 UTC) #14
shalamov
On 2016/09/12 18:52:46, Mikhail wrote: > Please take a look lgtm
4 years, 3 months ago (2016-09-13 11:25:41 UTC) #15
timvolodine
lgtm, thanks! https://codereview.chromium.org/2330943002/diff/1/device/generic_sensor/public/interfaces/sensor_provider.mojom File device/generic_sensor/public/interfaces/sensor_provider.mojom (right): https://codereview.chromium.org/2330943002/diff/1/device/generic_sensor/public/interfaces/sensor_provider.mojom#newcode20 device/generic_sensor/public/interfaces/sensor_provider.mojom:20: SensorConfiguration default_configuration; On 2016/09/12 17:08:10, Mikhail wrote: ...
4 years, 3 months ago (2016-09-13 13:17:11 UTC) #16
Mikhail
On 2016/09/13 13:17:11, timvolodine wrote: > lgtm, thanks! > > https://codereview.chromium.org/2330943002/diff/1/device/generic_sensor/public/interfaces/sensor_provider.mojom > File device/generic_sensor/public/interfaces/sensor_provider.mojom (right): ...
4 years, 3 months ago (2016-09-13 13:56:48 UTC) #17
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/2330943002/40001
4 years, 3 months ago (2016-09-13 13:57:14 UTC) #20
commit-bot: I haz the power
Try jobs failed on following builders: ios-device on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/ios-device/builds/68136) ios-simulator on master.tryserver.chromium.mac (JOB_FAILED, ...
4 years, 3 months ago (2016-09-13 13:59:22 UTC) #22
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/2330943002/60001
4 years, 3 months ago (2016-09-14 10:25:15 UTC) #29
commit-bot: I haz the power
Committed patchset #4 (id:60001)
4 years, 3 months ago (2016-09-14 10:30:19 UTC) #31
commit-bot: I haz the power
4 years, 3 months ago (2016-09-14 10:31:51 UTC) #33
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/b49349c6d3c4e7875fbb3ed8e3535f71006e444c
Cr-Commit-Position: refs/heads/master@{#418528}

Powered by Google App Engine
This is Rietveld 408576698