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

Side by Side Diff: Source/core/rendering/RenderBlock.cpp

Issue 68243009: Fix RenderBlock::nodeAtPoint() for scrollbars of hidden and pointer-events:none elements (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Test the effect of pointer-events:none on scrollbars Created 7 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
« no previous file with comments | « LayoutTests/scrollbars/scrollbar-visibility-hidden-expected.txt ('k') | no next file » | 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) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * (C) 2007 David Smith (catfish.man@gmail.com) 4 * (C) 2007 David Smith (catfish.man@gmail.com)
5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved.
6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved.
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 3061 matching lines...) Expand 10 before | Expand all | Expand 10 after
3072 3072
3073 if (!isRenderView()) { 3073 if (!isRenderView()) {
3074 // Check if we need to do anything at all. 3074 // Check if we need to do anything at all.
3075 LayoutRect overflowBox = visualOverflowRect(); 3075 LayoutRect overflowBox = visualOverflowRect();
3076 flipForWritingMode(overflowBox); 3076 flipForWritingMode(overflowBox);
3077 overflowBox.moveBy(adjustedLocation); 3077 overflowBox.moveBy(adjustedLocation);
3078 if (!locationInContainer.intersects(overflowBox)) 3078 if (!locationInContainer.intersects(overflowBox))
3079 return false; 3079 return false;
3080 } 3080 }
3081 3081
3082 if ((hitTestAction == HitTestBlockBackground || hitTestAction == HitTestChil dBlockBackground) && isPointInOverflowControl(result, locationInContainer.point( ), adjustedLocation)) { 3082 if ((hitTestAction == HitTestBlockBackground || hitTestAction == HitTestChil dBlockBackground)
3083 && visibleToHitTestRequest(request)
3084 && isPointInOverflowControl(result, locationInContainer.point(), adjuste dLocation)) {
3083 updateHitTestResult(result, locationInContainer.point() - localOffset); 3085 updateHitTestResult(result, locationInContainer.point() - localOffset);
3084 // FIXME: isPointInOverflowControl() doesn't handle rect-based tests yet . 3086 // FIXME: isPointInOverflowControl() doesn't handle rect-based tests yet .
3085 if (!result.addNodeToRectBasedTestResult(nodeForHitTest(), request, loca tionInContainer)) 3087 if (!result.addNodeToRectBasedTestResult(nodeForHitTest(), request, loca tionInContainer))
3086 return true; 3088 return true;
3087 } 3089 }
3088 3090
3089 // If we have clipping, then we can't have any spillout. 3091 // If we have clipping, then we can't have any spillout.
3090 bool useOverflowClip = hasOverflowClip() && !hasSelfPaintingLayer(); 3092 bool useOverflowClip = hasOverflowClip() && !hasSelfPaintingLayer();
3091 bool useClip = (hasControlClip() || useOverflowClip); 3093 bool useClip = (hasControlClip() || useOverflowClip);
3092 bool checkChildren = !useClip || (hasControlClip() ? locationInContainer.int ersects(controlClipRect(adjustedLocation)) : locationInContainer.intersects(over flowClipRect(adjustedLocation, locationInContainer.region(), IncludeOverlayScrol lbarSize))); 3094 bool checkChildren = !useClip || (hasControlClip() ? locationInContainer.int ersects(controlClipRect(adjustedLocation)) : locationInContainer.intersects(over flowClipRect(adjustedLocation, locationInContainer.region(), IncludeOverlayScrol lbarSize)));
(...skipping 2759 matching lines...) Expand 10 before | Expand all | Expand 10 after
5852 void RenderBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Render Object* obj) const 5854 void RenderBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Render Object* obj) const
5853 { 5855 {
5854 showRenderObject(); 5856 showRenderObject();
5855 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot Box()) 5857 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot Box())
5856 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa bel2, obj, 1); 5858 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa bel2, obj, 1);
5857 } 5859 }
5858 5860
5859 #endif 5861 #endif
5860 5862
5861 } // namespace WebCore 5863 } // namespace WebCore
OLDNEW
« no previous file with comments | « LayoutTests/scrollbars/scrollbar-visibility-hidden-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698