Title: [195591] trunk/Source/WebCore
- Revision
- 195591
- Author
- [email protected]
- Date
- 2016-01-26 09:00:18 -0800 (Tue, 26 Jan 2016)
Log Message
Main frame scrollbars not updated on hovering when using overlay scrollbars
https://bugs.webkit.org/show_bug.cgi?id=153304
Reviewed by Michael Catanzaro.
Legacy scrollbars were fixed in r194155, but overlay scrollbars
are not notified when they are hovered. This is because the layer
hit test in RenderView::hitTest always returns true when using
overlay scrollbars and we are returning early in such case,
ignoring the HitTestRequest::AllowFrameScrollbars flag. So, in
case of using overlay scrollbars we still need to check the
RenderView scrollbars even when the layer hit test succeeded.
* rendering/RenderView.cpp:
(WebCore::RenderView::hitTest):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (195590 => 195591)
--- trunk/Source/WebCore/ChangeLog 2016-01-26 16:15:22 UTC (rev 195590)
+++ trunk/Source/WebCore/ChangeLog 2016-01-26 17:00:18 UTC (rev 195591)
@@ -1,3 +1,21 @@
+2016-01-25 Carlos Garcia Campos <[email protected]>
+
+ Main frame scrollbars not updated on hovering when using overlay scrollbars
+ https://bugs.webkit.org/show_bug.cgi?id=153304
+
+ Reviewed by Michael Catanzaro.
+
+ Legacy scrollbars were fixed in r194155, but overlay scrollbars
+ are not notified when they are hovered. This is because the layer
+ hit test in RenderView::hitTest always returns true when using
+ overlay scrollbars and we are returning early in such case,
+ ignoring the HitTestRequest::AllowFrameScrollbars flag. So, in
+ case of using overlay scrollbars we still need to check the
+ RenderView scrollbars even when the layer hit test succeeded.
+
+ * rendering/RenderView.cpp:
+ (WebCore::RenderView::hitTest):
+
2016-01-26 Daniel Bates <[email protected]>
LayoutTest http/tests/security/xssAuditor/embed-tag-in-path-unterminated.html crashing
Modified: trunk/Source/WebCore/rendering/RenderView.cpp (195590 => 195591)
--- trunk/Source/WebCore/rendering/RenderView.cpp 2016-01-26 16:15:22 UTC (rev 195590)
+++ trunk/Source/WebCore/rendering/RenderView.cpp 2016-01-26 17:00:18 UTC (rev 195591)
@@ -47,6 +47,7 @@
#include "RenderNamedFlowThread.h"
#include "RenderSelectionInfo.h"
#include "RenderWidget.h"
+#include "ScrollbarTheme.h"
#include "Settings.h"
#include "StyleInheritedData.h"
#include "TransformState.h"
@@ -197,21 +198,23 @@
FrameFlatteningLayoutDisallower disallower(frameView());
- if (layer()->hitTest(request, location, result))
- return true;
+ bool resultLayer = layer()->hitTest(request, location, result);
- // FIXME: Consider if this test should be done unconditionally.
- if (request.allowsFrameScrollbars()) {
- // ScrollView scrollbars are not the same as RenderLayer scrollbars tested by RenderLayer::hitTestOverflowControls,
- // so we need to test ScrollView scrollbars separately here.
- IntPoint windowPoint = frameView().contentsToWindow(location.roundedPoint());
- if (Scrollbar* frameScrollbar = frameView().scrollbarAtPoint(windowPoint)) {
- result.setScrollbar(frameScrollbar);
- return true;
+ // ScrollView scrollbars are not the same as RenderLayer scrollbars tested by RenderLayer::hitTestOverflowControls,
+ // so we need to test ScrollView scrollbars separately here. In case of using overlay scrollbars, the layer hit test
+ // will always work so we need to check the ScrollView scrollbars in that case too.
+ if (!resultLayer || ScrollbarTheme::theme().usesOverlayScrollbars()) {
+ // FIXME: Consider if this test should be done unconditionally.
+ if (request.allowsFrameScrollbars()) {
+ IntPoint windowPoint = frameView().contentsToWindow(location.roundedPoint());
+ if (Scrollbar* frameScrollbar = frameView().scrollbarAtPoint(windowPoint)) {
+ result.setScrollbar(frameScrollbar);
+ return true;
+ }
}
}
- return false;
+ return resultLayer;
}
void RenderView::computeLogicalHeight(LayoutUnit logicalHeight, LayoutUnit, LogicalExtentComputedValues& computedValues) const
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes