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

Unified Diff: third_party/WebKit/Source/modules/sensor/Sensor.h

Issue 2384273004: [Sensors] 'onerror' event implementation (Closed)
Patch Set: updated global-interface-listing-expected.txt Created 4 years, 2 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: third_party/WebKit/Source/modules/sensor/Sensor.h
diff --git a/third_party/WebKit/Source/modules/sensor/Sensor.h b/third_party/WebKit/Source/modules/sensor/Sensor.h
index e34d9f4d9b841aa48a3a9a9c1d97df511fe06c83..e1aacf407cdb04730dc594e605b3498a1959e2bf 100644
--- a/third_party/WebKit/Source/modules/sensor/Sensor.h
+++ b/third_party/WebKit/Source/modules/sensor/Sensor.h
@@ -83,7 +83,9 @@ class Sensor : public EventTargetWithInlineData,
// SensorController::Observer overrides.
void onSensorInitialized() override;
void onSensorReadingChanged() override;
- void onSensorError() override;
+ void onSensorError(ExceptionCode,
+ const String& sanitizedMessage,
+ const String& unsanitizedMessage) override;
void onStartRequestCompleted(bool);
void onStopRequestCompleted(bool);
@@ -98,12 +100,15 @@ class Sensor : public EventTargetWithInlineData,
void pollForData();
void updateState(SensorState newState);
- void reportError();
+ void reportError(ExceptionCode = UnknownError,
+ const String& sanitizedMessage = String(),
+ const String& unsanitizedMessage = String());
void updatePollingStatus();
void notifySensorReadingChanged();
void notifyStateChanged();
+ void notifyError(DOMException* error);
private:
Member<SensorReading> m_sensorReading;

Powered by Google App Engine
This is Rietveld 408576698