tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

AndroidAPZ.cpp (1182B)


      1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
      2 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
      3 /* This Source Code Form is subject to the terms of the Mozilla Public
      4 * License, v. 2.0. If a copy of the MPL was not distributed with this
      5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
      6 
      7 #include "AndroidAPZ.h"
      8 
      9 #include "AndroidFlingPhysics.h"
     10 #include "AndroidVelocityTracker.h"
     11 #include "AsyncPanZoomController.h"
     12 #include "GenericFlingAnimation.h"
     13 #include "OverscrollHandoffState.h"
     14 
     15 namespace mozilla {
     16 namespace layers {
     17 
     18 AsyncPanZoomAnimation* AndroidSpecificState::CreateFlingAnimation(
     19    AsyncPanZoomController& aApzc, const FlingHandoffState& aHandoffState,
     20    float aPLPPI) {
     21  return new GenericFlingAnimation<AndroidFlingPhysics>(aApzc, aHandoffState,
     22                                                        aPLPPI);
     23 }
     24 
     25 UniquePtr<VelocityTracker> AndroidSpecificState::CreateVelocityTracker(
     26    Axis* aAxis) {
     27  return MakeUnique<AndroidVelocityTracker>();
     28 }
     29 
     30 /* static */
     31 void AndroidSpecificState::InitializeGlobalState() {
     32  AndroidFlingPhysics::InitializeGlobalState();
     33 }
     34 
     35 }  // namespace layers
     36 }  // namespace mozilla