1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "ui/base/events/event_utils.h"
7 #include "ui/base/events/event.h"
12 int g_custom_event_types
= ET_LAST
;
15 bool EventCanceledDefaultHandling(const Event
& event
) {
16 return event
.phase() == EP_POSTTARGET
&& event
.result() != ER_UNHANDLED
;
19 int RegisterCustomEventType() {
20 return ++g_custom_event_types
;
23 base::TimeDelta
EventTimeForNow() {
24 return base::TimeDelta::FromInternalValue(
25 base::TimeTicks::Now().ToInternalValue());