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

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

Issue 620753006: Rendering API cleanup (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Address jchaffraix remarks Created 6 years, 2 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006 Apple Computer, Inc. 2 * Copyright (C) 2006 Apple Computer, Inc.
3 * Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies) 3 * Copyright (C) 2012 Nokia Corporation and/or its subsidiary(-ies)
4 * 4 *
5 * This library is free software; you can redistribute it and/or 5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public 6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either 7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version. 8 * version 2 of the License, or (at your option) any later version.
9 * 9 *
10 * This library is distributed in the hope that it will be useful, 10 * This library is distributed in the hope that it will be useful,
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 HitTestLocation(const HitTestLocation&, const LayoutSize& offset); 47 HitTestLocation(const HitTestLocation&, const LayoutSize& offset);
48 HitTestLocation(const HitTestLocation&); 48 HitTestLocation(const HitTestLocation&);
49 ~HitTestLocation(); 49 ~HitTestLocation();
50 HitTestLocation& operator=(const HitTestLocation&); 50 HitTestLocation& operator=(const HitTestLocation&);
51 51
52 const LayoutPoint& point() const { return m_point; } 52 const LayoutPoint& point() const { return m_point; }
53 IntPoint roundedPoint() const { return roundedIntPoint(m_point); } 53 IntPoint roundedPoint() const { return roundedIntPoint(m_point); }
54 54
55 // Rect-based hit test related methods. 55 // Rect-based hit test related methods.
56 bool isRectBasedTest() const { return m_isRectBased; } 56 bool isRectBasedTest() const { return m_isRectBased; }
57 bool isRectilinear() const { return m_isRectilinear; }
Julien - ping for review 2014/10/03 01:26:42 Nit: Maybe keep?
58 IntRect boundingBox() const { return m_boundingBox; } 57 IntRect boundingBox() const { return m_boundingBox; }
59 58
60 static IntRect rectForPoint(const LayoutPoint&, unsigned topPadding, unsigne d rightPadding, unsigned bottomPadding, unsigned leftPadding); 59 static IntRect rectForPoint(const LayoutPoint&, unsigned topPadding, unsigne d rightPadding, unsigned bottomPadding, unsigned leftPadding);
61 int topPadding() const { return roundedPoint().y() - m_boundingBox.y(); } 60 int topPadding() const { return roundedPoint().y() - m_boundingBox.y(); }
62 int rightPadding() const { return m_boundingBox.maxX() - roundedPoint().x() - 1; } 61 int rightPadding() const { return m_boundingBox.maxX() - roundedPoint().x() - 1; }
63 int bottomPadding() const { return m_boundingBox.maxY() - roundedPoint().y() - 1; } 62 int bottomPadding() const { return m_boundingBox.maxY() - roundedPoint().y() - 1; }
64 int leftPadding() const { return roundedPoint().x() - m_boundingBox.x(); } 63 int leftPadding() const { return roundedPoint().x() - m_boundingBox.x(); }
65 64
66 bool intersects(const LayoutRect&) const; 65 bool intersects(const LayoutRect&) const;
67 bool intersects(const FloatRect&) const; 66 bool intersects(const FloatRect&) const;
(...skipping 15 matching lines...) Expand all
83 FloatPoint m_transformedPoint; 82 FloatPoint m_transformedPoint;
84 FloatQuad m_transformedRect; 83 FloatQuad m_transformedRect;
85 84
86 bool m_isRectBased; 85 bool m_isRectBased;
87 bool m_isRectilinear; 86 bool m_isRectilinear;
88 }; 87 };
89 88
90 } // namespace blink 89 } // namespace blink
91 90
92 #endif // HitTestLocation_h 91 #endif // HitTestLocation_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698