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

Side by Side Diff: third_party/WebKit/Source/core/layout/HitTestResult.cpp

Issue 2389073002: Fix link's hover state if the link under scrollbar (Closed)
Patch Set: add test Created 4 years, 1 month 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, 2008, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2008, 2011 Apple Inc. All rights reserved.
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 199 matching lines...) Expand 10 before | Expand all | Expand 10 after
210 m_innerNode = area; 210 m_innerNode = area;
211 m_innerPossiblyPseudoNode = area; 211 m_innerPossiblyPseudoNode = area;
212 } 212 }
213 } 213 }
214 214
215 void HitTestResult::setURLElement(Element* n) { 215 void HitTestResult::setURLElement(Element* n) {
216 m_innerURLElement = n; 216 m_innerURLElement = n;
217 } 217 }
218 218
219 void HitTestResult::setScrollbar(Scrollbar* s) { 219 void HitTestResult::setScrollbar(Scrollbar* s) {
220 // ignore the hidden scrollbar
221 if (!s->enabled())
bokan 2016/11/01 21:09:37 Hmm, in the case of regular, non-overlay scrollbar
222 return;
220 m_scrollbar = s; 223 m_scrollbar = s;
221 } 224 }
222 225
223 LocalFrame* HitTestResult::innerNodeFrame() const { 226 LocalFrame* HitTestResult::innerNodeFrame() const {
224 if (m_innerNode) 227 if (m_innerNode)
225 return m_innerNode->document().frame(); 228 return m_innerNode->document().frame();
226 return nullptr; 229 return nullptr;
227 } 230 }
228 231
229 bool HitTestResult::isSelected() const { 232 bool HitTestResult::isSelected() const {
(...skipping 270 matching lines...) Expand 10 before | Expand all | Expand 10 after
500 else if (isHTMLMapElement(m_innerNode)) 503 else if (isHTMLMapElement(m_innerNode))
501 imageMapImageElement = toHTMLMapElement(m_innerNode)->imageElement(); 504 imageMapImageElement = toHTMLMapElement(m_innerNode)->imageElement();
502 505
503 if (!imageMapImageElement) 506 if (!imageMapImageElement)
504 return m_innerNode.get(); 507 return m_innerNode.get();
505 508
506 return imageMapImageElement; 509 return imageMapImageElement;
507 } 510 }
508 511
509 } // namespace blink 512 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698