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

Unified Diff: views/controls/link.cc

Issue 7248064: views: Override Label::HitTest with the default View::HitTest for Link. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Created 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « views/controls/link.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: views/controls/link.cc
diff --git a/views/controls/link.cc b/views/controls/link.cc
index 68b8c417606314fea7fcab44b296767df400130d..4f60d30b1e083c280eabb04351104ac191461d43 100644
--- a/views/controls/link.cc
+++ b/views/controls/link.cc
@@ -108,6 +108,12 @@ gfx::NativeCursor Link::GetCursor(const MouseEvent& event) {
#endif
}
+bool Link::HitTest(const gfx::Point& l) const {
+ // We need to allow clicks on the link. So we override the implementation in
+ // Label and use the default implementation of View.
+ return View::HitTest(l);
+}
+
bool Link::OnMousePressed(const MouseEvent& event) {
if (!IsEnabled() ||
(!event.IsLeftMouseButton() && !event.IsMiddleMouseButton()))
« no previous file with comments | « views/controls/link.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698