#include "third_party/blink/renderer/core/timing/event_timing.h"
#include <optional>
#include "base/time/tick_clock.h"
#include "third_party/blink/renderer/core/dom/events/event.h"
#include "third_party/blink/renderer/core/events/keyboard_event.h"
#include "third_party/blink/renderer/core/events/pointer_event.h"
#include "third_party/blink/renderer/core/events/touch_event.h"
#include "third_party/blink/renderer/core/events/wheel_event.h"
#include "third_party/blink/renderer/core/frame/local_dom_window.h"
#include "third_party/blink/renderer/core/loader/interactive_detector.h"
#include "third_party/blink/renderer/core/timing/dom_window_performance.h"
#include "third_party/blink/renderer/core/timing/performance_event_timing.h"
#include "third_party/blink/renderer/platform/runtime_enabled_features.h"
namespace blink {
namespace {
const base::TickClock* g_clock_for_testing = …;
static base::TimeTicks Now() { … }
bool ShouldLogEvent(const Event& event) { … }
bool ShouldReportForEventTiming(WindowPerformance* performance) { … }
}
EventTiming::EventTiming(base::TimeTicks processing_start,
WindowPerformance* performance,
const Event& event,
EventTarget* original_event_target)
: … { … }
void EventTiming::HandleInputDelay(LocalDOMWindow* window,
const Event& event,
base::TimeTicks processing_start) { … }
bool EventTiming::IsEventTypeForEventTiming(const Event& event) { … }
std::unique_ptr<EventTiming> EventTiming::Create(
LocalDOMWindow* window,
const Event& event,
EventTarget* original_event_target) { … }
void EventTiming::SetTickClockForTesting(const base::TickClock* clock) { … }
EventTiming::~EventTiming() { … }
}