Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(189)

Side by Side Diff: sky/engine/core/rendering/HitTestRequest.h

Issue 868133003: Remove touch events from Sky (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « sky/engine/core/page/EventHandler.cpp ('k') | sky/engine/platform/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006 Apple Computer, Inc. 2 * Copyright (C) 2006 Apple Computer, Inc.
3 * Copyright (C) 2009 Torch Mobile Inc. http://www.torchmobile.com/ 3 * Copyright (C) 2009 Torch Mobile Inc. http://www.torchmobile.com/
4 * Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies) 4 * Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies)
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 16 matching lines...) Expand all
27 27
28 class HitTestRequest { 28 class HitTestRequest {
29 public: 29 public:
30 enum RequestType { 30 enum RequestType {
31 ReadOnly = 1 << 1, 31 ReadOnly = 1 << 1,
32 Active = 1 << 2, 32 Active = 1 << 2,
33 Move = 1 << 3, 33 Move = 1 << 3,
34 Release = 1 << 4, 34 Release = 1 << 4,
35 IgnoreClipping = 1 << 5, 35 IgnoreClipping = 1 << 5,
36 SVGClipContent = 1 << 6, 36 SVGClipContent = 1 << 6,
37 TouchEvent = 1 << 7,
38 IgnorePointerEventsNone = 1 << 8, 37 IgnorePointerEventsNone = 1 << 8,
39 }; 38 };
40 39
41 typedef unsigned HitTestRequestType; 40 typedef unsigned HitTestRequestType;
42 41
43 HitTestRequest(HitTestRequestType requestType) 42 HitTestRequest(HitTestRequestType requestType)
44 : m_requestType(requestType) 43 : m_requestType(requestType)
45 { 44 {
46 } 45 }
47 46
48 bool readOnly() const { return m_requestType & ReadOnly; } 47 bool readOnly() const { return m_requestType & ReadOnly; }
49 bool active() const { return m_requestType & Active; } 48 bool active() const { return m_requestType & Active; }
50 bool move() const { return m_requestType & Move; } 49 bool move() const { return m_requestType & Move; }
51 bool release() const { return m_requestType & Release; } 50 bool release() const { return m_requestType & Release; }
52 bool ignoreClipping() const { return m_requestType & IgnoreClipping; } 51 bool ignoreClipping() const { return m_requestType & IgnoreClipping; }
53 bool svgClipContent() const { return m_requestType & SVGClipContent; } 52 bool svgClipContent() const { return m_requestType & SVGClipContent; }
54 bool touchEvent() const { return m_requestType & TouchEvent; }
55 bool ignorePointerEventsNone() const { return m_requestType & IgnorePointerE ventsNone; } 53 bool ignorePointerEventsNone() const { return m_requestType & IgnorePointerE ventsNone; }
56 54
57 // Convenience functions
58 bool touchMove() const { return move() && touchEvent(); }
59
60 HitTestRequestType type() const { return m_requestType; } 55 HitTestRequestType type() const { return m_requestType; }
61 56
62 private: 57 private:
63 HitTestRequestType m_requestType; 58 HitTestRequestType m_requestType;
64 }; 59 };
65 60
66 } // namespace blink 61 } // namespace blink
67 62
68 #endif // SKY_ENGINE_CORE_RENDERING_HITTESTREQUEST_H_ 63 #endif // SKY_ENGINE_CORE_RENDERING_HITTESTREQUEST_H_
OLDNEW
« no previous file with comments | « sky/engine/core/page/EventHandler.cpp ('k') | sky/engine/platform/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698