chromium/ui/events/gesture_detection/scale_gesture_detector.cc

// Copyright 2014 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "ui/events/gesture_detection/scale_gesture_detector.h"

#include <limits.h>

#include <algorithm>
#include <cmath>

#include "base/check.h"
#include "base/logging.h"
#include "base/numerics/angle_conversions.h"
#include "base/numerics/math_constants.h"
#include "ui/events/gesture_detection/scale_gesture_listeners.h"
#include "ui/events/velocity_tracker/motion_event.h"

TimeTicks;

namespace ui {
namespace {

const float kScaleFactor =;

// Using a small epsilon when comparing slop distances allows pixel
// perfect slop determination when using fractional DPI coordinates
// (assuming the slop region and DPI scale are reasonably
// proportioned).
const float kSlopEpsilon =;

}  // namespace

// Note: These constants were taken directly from the default (unscaled)
// versions found in Android's ViewConfiguration. Do not change these default
// values without explicitly consulting an OWNER.
ScaleGestureDetector::Config::Config()
    :{}

ScaleGestureDetector::Config::~Config() {}

ScaleGestureDetector::ScaleGestureDetector(const Config& config,
                                           ScaleGestureListener* listener)
    :{}

ScaleGestureDetector::~ScaleGestureDetector() {}

bool ScaleGestureDetector::OnTouchEvent(const MotionEvent& event) {}

bool ScaleGestureDetector::IsInProgress() const {}

bool ScaleGestureDetector::InAnchoredScaleMode() const {}

float ScaleGestureDetector::GetFocusX() const {}

float ScaleGestureDetector::GetFocusY() const {}

float ScaleGestureDetector::GetCurrentSpan() const {}

float ScaleGestureDetector::GetCurrentSpanX() const {}

float ScaleGestureDetector::GetCurrentSpanY() const {}

float ScaleGestureDetector::GetPreviousSpan() const {}

float ScaleGestureDetector::GetPreviousSpanX() const {}

float ScaleGestureDetector::GetPreviousSpanY() const {}

float ScaleGestureDetector::GetScaleFactor() const {}

float ScaleGestureDetector::GetAngleChange() const {}

base::TimeDelta ScaleGestureDetector::GetTimeDelta() const {}

base::TimeTicks ScaleGestureDetector::GetEventTime() const {}

bool ScaleGestureDetector::OnDoubleTap(const MotionEvent& ev) {}

void ScaleGestureDetector::ResetScaleWithSpan(float span) {}

float ScaleGestureDetector::CalculateAngle(const MotionEvent& event,
                                           int action_index,
                                           float focus_x,
                                           float focus_y) const {}

}  // namespace ui