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

Unified Diff: Source/core/frame/FrameView.cpp

Issue 1319863006: (blink) Propagate scrolling/marginwidth/marginheight property values to child frame. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: address comments + static_cast for enum conversion Created 5 years, 3 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
Index: Source/core/frame/FrameView.cpp
diff --git a/Source/core/frame/FrameView.cpp b/Source/core/frame/FrameView.cpp
index cdfa3a72851e8005b125f67f28d907238286c97d..3d9f37ad4101283215df5e2795837a51fc0a7025 100644
--- a/Source/core/frame/FrameView.cpp
+++ b/Source/core/frame/FrameView.cpp
@@ -587,9 +587,13 @@ void FrameView::applyOverflowToViewport(LayoutObject* o, ScrollbarMode& hMode, S
void FrameView::calculateScrollbarModesForLayout(ScrollbarMode& hMode, ScrollbarMode& vMode, ScrollbarModesCalculationStrategy strategy)
{
- // FIXME: How do we handle this for OOPI?
- const HTMLFrameOwnerElement* owner = m_frame->deprecatedLocalOwner();
- if (owner && (owner->scrollingMode() == ScrollbarAlwaysOff)) {
+ const HTMLFrameOwnerElement* ownerElement = m_frame->deprecatedLocalOwner();
alexmos 2015/09/02 21:37:05 Wouldn't just doing this via m_frame->owner() work
lazyboy 2015/09/15 01:40:32 Yes, Done.
+ if (ownerElement && (ownerElement->scrollingMode() == ScrollbarAlwaysOff)) {
+ hMode = ScrollbarAlwaysOff;
+ vMode = ScrollbarAlwaysOff;
+ return;
+ }
+ if (!ownerElement && m_frame->owner() && (m_frame->owner()->scrollingMode() == ScrollbarAlwaysOff)) {
alexmos 2015/09/02 21:37:05 Does LocalFrame::createView need a similar fix? h
lazyboy 2015/09/15 01:40:32 I've added the fix there too similarly.
hMode = ScrollbarAlwaysOff;
vMode = ScrollbarAlwaysOff;
return;

Powered by Google App Engine
This is Rietveld 408576698