Bug 1277806 - Add the missing C++ API for boolean scalars. r=gfritzsche
authorAlessio Placitelli <alessio.placitelli@gmail.com>
Wed, 14 Sep 2016 02:59:00 +0200
changeset 314720 73c0774056bb
parent 314719 d0ad8d0da0ef
child 314721 41f5b98f7b55
push id20583
push useralessio.placitelli@gmail.com
push dateWed, 21 Sep 2016 16:38:21 +0000
treeherderfx-team@73c0774056bb [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgfritzsche
bugs1277806
milestone52.0a1
Bug 1277806 - Add the missing C++ API for boolean scalars. r=gfritzsche
toolkit/components/telemetry/Telemetry.cpp
toolkit/components/telemetry/Telemetry.h
--- a/toolkit/components/telemetry/Telemetry.cpp
+++ b/toolkit/components/telemetry/Telemetry.cpp
@@ -3004,16 +3004,22 @@ ScalarAdd(mozilla::Telemetry::ScalarID a
 
 void
 ScalarSet(mozilla::Telemetry::ScalarID aId, uint32_t aVal)
 {
   TelemetryScalar::Set(aId, aVal);
 }
 
 void
+ScalarSet(mozilla::Telemetry::ScalarID aId, bool aVal)
+{
+  TelemetryScalar::Set(aId, aVal);
+}
+
+void
 ScalarSet(mozilla::Telemetry::ScalarID aId, const nsAString& aVal)
 {
   TelemetryScalar::Set(aId, aVal);
 }
 
 void
 ScalarSetMaximum(mozilla::Telemetry::ScalarID aId, uint32_t aVal)
 {
--- a/toolkit/components/telemetry/Telemetry.h
+++ b/toolkit/components/telemetry/Telemetry.h
@@ -374,16 +374,24 @@ void ScalarAdd(mozilla::Telemetry::Scala
  * @param aValue The value to set the scalar to.
  */
 void ScalarSet(mozilla::Telemetry::ScalarID aId, uint32_t aValue);
 
 /**
  * Sets the scalar to the given value.
  *
  * @param aId The scalar enum id.
+ * @param aValue The value to set the scalar to.
+ */
+void ScalarSet(mozilla::Telemetry::ScalarID aId, bool aValue);
+
+/**
+ * Sets the scalar to the given value.
+ *
+ * @param aId The scalar enum id.
  * @param aValue The value to set the scalar to, truncated to
  *        50 characters if exceeding that length.
  */
 void ScalarSet(mozilla::Telemetry::ScalarID aId, const nsAString& aValue);
 
 /**
  * Sets the scalar to the maximum of the current and the passed value.
  *