Bug 1469972 - Remove VRPose::mFrameId and its accessor as it is unused draft
authorKearwood "Kip" Gilbert <kgilbert@mozilla.com>
Wed, 20 Jun 2018 13:02:03 -0700
changeset 808811 fd93d152299ac4861ee3cb219fed1a16fa4690c8
parent 808726 681eb7dfa324dd50403c382888929ea8b8b11b00
push id113500
push userkgilbert@mozilla.com
push dateWed, 20 Jun 2018 20:46:12 +0000
bugs1469972
milestone62.0a1
Bug 1469972 - Remove VRPose::mFrameId and its accessor as it is unused MozReview-Commit-ID: 8t2a7gQacDl
dom/vr/VRDisplay.cpp
dom/vr/VRDisplay.h
--- a/dom/vr/VRDisplay.cpp
+++ b/dom/vr/VRDisplay.cpp
@@ -258,27 +258,25 @@ VRDisplayCapabilities::WrapObject(JSCont
 {
   return VRDisplayCapabilitiesBinding::Wrap(aCx, this, aGivenProto);
 }
 
 VRPose::VRPose(nsISupports* aParent, const gfx::VRHMDSensorState& aState)
   : Pose(aParent)
   , mVRState(aState)
 {
-  mFrameId = aState.inputFrameID;
   mozilla::HoldJSObjects(this);
 }
 
 VRPose::VRPose(nsISupports* aParent)
   : Pose(aParent)
 {
   mVRState.inputFrameID = 0;
   mVRState.timestamp = 0.0;
   mVRState.flags = gfx::VRDisplayCapabilityFlags::Cap_None;
-  mFrameId = 0;
   mozilla::HoldJSObjects(this);
 }
 
 VRPose::~VRPose()
 {
   mozilla::DropJSObjects(this);
 }
 
@@ -484,17 +482,18 @@ VRDisplay::GetSubmitFrameResult(VRSubmit
   aResult.Update(resultInfo.mFrameNum, encodedImg);
   return true;
 }
 
 already_AddRefed<VRPose>
 VRDisplay::GetPose()
 {
   UpdateFrameInfo();
-  RefPtr<VRPose> obj = new VRPose(GetParentObject(), mFrameInfo.mVRState);
+  RefPtr<VRPose> obj = new VRPose(GetParentObject(),
+                                  mFrameInfo.mVRState);
 
   return obj.forget();
 }
 
 void
 VRDisplay::ResetPose()
 {
   mClient->ZeroSensor();
--- a/dom/vr/VRDisplay.h
+++ b/dom/vr/VRDisplay.h
@@ -98,18 +98,16 @@ protected:
 
 class VRPose final : public Pose
 {
 
 public:
   VRPose(nsISupports* aParent, const gfx::VRHMDSensorState& aState);
   explicit VRPose(nsISupports* aParent);
 
-  uint64_t FrameID() const { return mFrameId; }
-
   virtual void GetPosition(JSContext* aCx,
                            JS::MutableHandle<JSObject*> aRetval,
                            ErrorResult& aRv) override;
   virtual void GetLinearVelocity(JSContext* aCx,
                                  JS::MutableHandle<JSObject*> aRetval,
                                  ErrorResult& aRv) override;
   virtual void GetLinearAcceleration(JSContext* aCx,
                                      JS::MutableHandle<JSObject*> aRetval,
@@ -124,17 +122,16 @@ public:
                                       JS::MutableHandle<JSObject*> aRetval,
                                       ErrorResult& aRv) override;
 
   virtual JSObject* WrapObject(JSContext* aCx, JS::Handle<JSObject*> aGivenProto) override;
 
 protected:
   ~VRPose();
 
-  uint64_t mFrameId;
   gfx::VRHMDSensorState mVRState;
 };
 
 struct VRFrameInfo
 {
   VRFrameInfo();
 
   void Update(const gfx::VRDisplayInfo& aInfo,