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

Side by Side Diff: Source/core/rendering/HitTestRequest.h

Issue 329773002: Remove special touch-action hit test mode (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: incorporated review comments Created 6 years, 6 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 | « Source/core/page/EventHandler.cpp ('k') | Source/core/rendering/InlineBox.h » ('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 23 matching lines...) Expand all
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, 37 TouchEvent = 1 << 7,
38 // Deprecated. Instead of this, callers should call HitTestResult::setTo NodesInDocumentTreeScope() explicitly. 38 // Deprecated. Instead of this, callers should call HitTestResult::setTo NodesInDocumentTreeScope() explicitly.
39 ConfusingAndOftenMisusedDisallowShadowContent = 1 << 8, 39 ConfusingAndOftenMisusedDisallowShadowContent = 1 << 8,
40 AllowFrameScrollbars = 1 << 9, 40 AllowFrameScrollbars = 1 << 9,
41 AllowChildFrameContent = 1 << 10, 41 AllowChildFrameContent = 1 << 10,
42 ChildFrameHitTest = 1 << 11, 42 ChildFrameHitTest = 1 << 11,
43 IgnorePointerEventsNone = 1 << 12, 43 IgnorePointerEventsNone = 1 << 12,
44 TouchAction = 1 << 13, // Hit testing for touch-action considers only bl ock-level elements
45 }; 44 };
46 45
47 typedef unsigned HitTestRequestType; 46 typedef unsigned HitTestRequestType;
48 47
49 HitTestRequest(HitTestRequestType requestType) 48 HitTestRequest(HitTestRequestType requestType)
50 : m_requestType(requestType) 49 : m_requestType(requestType)
51 { 50 {
52 } 51 }
53 52
54 bool readOnly() const { return m_requestType & ReadOnly; } 53 bool readOnly() const { return m_requestType & ReadOnly; }
55 bool active() const { return m_requestType & Active; } 54 bool active() const { return m_requestType & Active; }
56 bool move() const { return m_requestType & Move; } 55 bool move() const { return m_requestType & Move; }
57 bool release() const { return m_requestType & Release; } 56 bool release() const { return m_requestType & Release; }
58 bool ignoreClipping() const { return m_requestType & IgnoreClipping; } 57 bool ignoreClipping() const { return m_requestType & IgnoreClipping; }
59 bool svgClipContent() const { return m_requestType & SVGClipContent; } 58 bool svgClipContent() const { return m_requestType & SVGClipContent; }
60 bool touchEvent() const { return m_requestType & TouchEvent; } 59 bool touchEvent() const { return m_requestType & TouchEvent; }
61 bool mouseEvent() const { return !touchEvent(); } 60 bool mouseEvent() const { return !touchEvent(); }
62 bool disallowsShadowContent() const { return m_requestType & ConfusingAndOft enMisusedDisallowShadowContent; } 61 bool disallowsShadowContent() const { return m_requestType & ConfusingAndOft enMisusedDisallowShadowContent; }
63 bool allowsFrameScrollbars() const { return m_requestType & AllowFrameScroll bars; } 62 bool allowsFrameScrollbars() const { return m_requestType & AllowFrameScroll bars; }
64 bool allowsChildFrameContent() const { return m_requestType & AllowChildFram eContent; } 63 bool allowsChildFrameContent() const { return m_requestType & AllowChildFram eContent; }
65 bool isChildFrameHitTest() const { return m_requestType & ChildFrameHitTest; } 64 bool isChildFrameHitTest() const { return m_requestType & ChildFrameHitTest; }
66 bool ignorePointerEventsNone() const { return m_requestType & IgnorePointerE ventsNone; } 65 bool ignorePointerEventsNone() const { return m_requestType & IgnorePointerE ventsNone; }
67 bool touchAction() const { return m_requestType & TouchAction; }
68 66
69 // Convenience functions 67 // Convenience functions
70 bool touchMove() const { return move() && touchEvent(); } 68 bool touchMove() const { return move() && touchEvent(); }
71 bool touchRelease() const { return release() && touchEvent(); } 69 bool touchRelease() const { return release() && touchEvent(); }
72 70
73 HitTestRequestType type() const { return m_requestType; } 71 HitTestRequestType type() const { return m_requestType; }
74 72
75 private: 73 private:
76 HitTestRequestType m_requestType; 74 HitTestRequestType m_requestType;
77 }; 75 };
78 76
79 } // namespace WebCore 77 } // namespace WebCore
80 78
81 #endif // HitTestRequest_h 79 #endif // HitTestRequest_h
OLDNEW
« no previous file with comments | « Source/core/page/EventHandler.cpp ('k') | Source/core/rendering/InlineBox.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698