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

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

Issue 70163005: Fix clientLeft value for RTL direction, while the element have vertical scrollbar in left side. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebased Created 6 years, 9 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 unified diff | Download patch
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) 2005 Allan Sandfeld Jensen (kde@carewolf.com) 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com)
5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com)
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv ed. 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv ed.
7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. 7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 4269 matching lines...) Expand 10 before | Expand all | Expand 10 after
4280 m_overflow->addVisualOverflow(rect); 4280 m_overflow->addVisualOverflow(rect);
4281 } 4281 }
4282 4282
4283 void RenderBox::addContentsVisualOverflow(const LayoutRect& rect) 4283 void RenderBox::addContentsVisualOverflow(const LayoutRect& rect)
4284 { 4284 {
4285 if (!hasOverflowClip()) { 4285 if (!hasOverflowClip()) {
4286 addVisualOverflow(rect); 4286 addVisualOverflow(rect);
4287 return; 4287 return;
4288 } 4288 }
4289 4289
4290 if (!m_overflow) 4290 if (!m_overflow) {
4291 m_overflow = adoptPtr(new RenderOverflow(clientBoxRect(), borderBoxRect( ))); 4291 LayoutRect clientBox = clientBoxRect();
4292 if (style()->shouldPlaceBlockDirectionScrollbarOnLogicalLeft())
4293 clientBox.move(-verticalScrollbarWidth(), 0);
4294 m_overflow = adoptPtr(new RenderOverflow(clientBox, borderBoxRect()));
4295 }
4292 m_overflow->addContentsVisualOverflow(rect); 4296 m_overflow->addContentsVisualOverflow(rect);
4293 } 4297 }
4294 4298
4295 void RenderBox::clearLayoutOverflow() 4299 void RenderBox::clearLayoutOverflow()
4296 { 4300 {
4297 if (!m_overflow) 4301 if (!m_overflow)
4298 return; 4302 return;
4299 4303
4300 if (!hasVisualOverflow() && contentsVisualOverflowRect().isEmpty()) { 4304 if (!hasVisualOverflow() && contentsVisualOverflowRect().isEmpty()) {
4301 m_overflow.clear(); 4305 m_overflow.clear();
(...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after
4692 return 0; 4696 return 0;
4693 4697
4694 if (!layoutState && !flowThreadContainingBlock()) 4698 if (!layoutState && !flowThreadContainingBlock())
4695 return 0; 4699 return 0;
4696 4700
4697 RenderBlock* containerBlock = containingBlock(); 4701 RenderBlock* containerBlock = containingBlock();
4698 return containerBlock->offsetFromLogicalTopOfFirstPage() + logicalTop(); 4702 return containerBlock->offsetFromLogicalTopOfFirstPage() + logicalTop();
4699 } 4703 }
4700 4704
4701 } // namespace WebCore 4705 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderBox.h ('k') | Source/core/rendering/compositing/CompositedLayerMapping.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698