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

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

Issue 2545243002: Don't repeat thead if the first row exceeds the height of the page (Closed)
Patch Set: bug 669690 Created 4 years 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) 2007 Apple Inc. All rights reserved. 2 * Copyright (C) 2007 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 bool containingBlockLogicalWidthChanged) 46 bool containingBlockLogicalWidthChanged)
47 : m_containingBlockLogicalWidthChanged(containingBlockLogicalWidthChanged), 47 : m_containingBlockLogicalWidthChanged(containingBlockLogicalWidthChanged),
48 m_next(layoutObject.view()->layoutState()), 48 m_next(layoutObject.view()->layoutState()),
49 m_layoutObject(layoutObject) { 49 m_layoutObject(layoutObject) {
50 if (layoutObject.isLayoutFlowThread()) 50 if (layoutObject.isLayoutFlowThread())
51 m_flowThread = toLayoutFlowThread(&layoutObject); 51 m_flowThread = toLayoutFlowThread(&layoutObject);
52 else 52 else
53 m_flowThread = m_next->flowThread(); 53 m_flowThread = m_next->flowThread();
54 m_paginationStateChanged = m_next->m_paginationStateChanged; 54 m_paginationStateChanged = m_next->m_paginationStateChanged;
55 layoutObject.view()->pushLayoutState(*this); 55 layoutObject.view()->pushLayoutState(*this);
56 m_heightOffsetForTableHeaders = m_next->heightOffsetForTableHeaders();
57 56
58 if (layoutObject.isLayoutFlowThread()) { 57 if (layoutObject.isLayoutFlowThread()) {
59 // Entering a new pagination context. 58 // Entering a new pagination context.
60 m_paginationOffset = LayoutSize(); 59 m_paginationOffset = LayoutSize();
61 m_isPaginated = true; 60 m_isPaginated = true;
62 return; 61 return;
63 } 62 }
64 63
65 // Disable pagination for objects we don't support. For now this includes 64 // Disable pagination for objects we don't support. For now this includes
66 // overflow:scroll/auto, inline blocks and writing mode roots. Additionally, 65 // overflow:scroll/auto, inline blocks and writing mode roots. Additionally,
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
124 123
125 LayoutUnit LayoutState::pageLogicalOffset( 124 LayoutUnit LayoutState::pageLogicalOffset(
126 const LayoutBox& child, 125 const LayoutBox& child,
127 const LayoutUnit& childLogicalOffset) const { 126 const LayoutUnit& childLogicalOffset) const {
128 if (child.isHorizontalWritingMode()) 127 if (child.isHorizontalWritingMode())
129 return m_paginationOffset.height() + childLogicalOffset; 128 return m_paginationOffset.height() + childLogicalOffset;
130 return m_paginationOffset.width() + childLogicalOffset; 129 return m_paginationOffset.width() + childLogicalOffset;
131 } 130 }
132 131
133 } // namespace blink 132 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutState.h ('k') | third_party/WebKit/Source/core/layout/LayoutTable.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698