Bug 819791 - Part 4: Remove an unnecessary TArray copy in OrientationObserver.cpp. r=mounir

This commit is contained in:
Justin Lebar 2012-12-18 20:16:06 -05:00
parent 7bef45ba1a
commit aceb4ec69b

View File

@ -200,7 +200,7 @@ OrientationObserver::Notify(const hal::SensorData& aSensorData)
MOZ_ASSERT(NS_IsMainThread());
MOZ_ASSERT(aSensorData.sensor() == hal::SensorType::SENSOR_ORIENTATION);
InfallibleTArray<float> values = aSensorData.values();
const InfallibleTArray<float>& values = aSensorData.values();
// Azimuth (values[0]): the device's horizontal orientation
// (0 degree is north). It's unused for screen rotation.
float pitch = values[1];