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

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

Issue 2725343002: Migrate WTF::LinkedHashSet/ListHashSet::last() to ::back() (Closed)
Patch Set: rebase Created 3 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) 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2012 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 454 matching lines...) Expand 10 before | Expand all | Expand 10 after
465 return nullptr; 465 return nullptr;
466 if (offset < LayoutUnit()) { 466 if (offset < LayoutUnit()) {
467 columnSet = m_multiColumnSetList.front(); 467 columnSet = m_multiColumnSetList.front();
468 } else { 468 } else {
469 MultiColumnSetSearchAdapter adapter(offset); 469 MultiColumnSetSearchAdapter adapter(offset);
470 m_multiColumnSetIntervalTree 470 m_multiColumnSetIntervalTree
471 .allOverlapsWithAdapter<MultiColumnSetSearchAdapter>(adapter); 471 .allOverlapsWithAdapter<MultiColumnSetSearchAdapter>(adapter);
472 472
473 // If no set was found, the offset is in the flow thread overflow. 473 // If no set was found, the offset is in the flow thread overflow.
474 if (!adapter.result() && !m_multiColumnSetList.isEmpty()) 474 if (!adapter.result() && !m_multiColumnSetList.isEmpty())
475 columnSet = m_multiColumnSetList.last(); 475 columnSet = m_multiColumnSetList.back();
476 else 476 else
477 columnSet = adapter.result(); 477 columnSet = adapter.result();
478 } 478 }
479 } 479 }
480 if (pageBoundaryRule == AssociateWithFormerPage && columnSet && 480 if (pageBoundaryRule == AssociateWithFormerPage && columnSet &&
481 offset == columnSet->logicalTopInFlowThread()) { 481 offset == columnSet->logicalTopInFlowThread()) {
482 // The column set that we found starts at the exact same flow thread offset 482 // The column set that we found starts at the exact same flow thread offset
483 // as we specified. Since we are to associate offsets at boundaries with the 483 // as we specified. Since we are to associate offsets at boundaries with the
484 // former fragmentainer, the fragmentainer we're looking for is in the 484 // former fragmentainer, the fragmentainer we're looking for is in the
485 // previous column set. 485 // previous column set.
(...skipping 890 matching lines...) Expand 10 before | Expand all | Expand 10 after
1376 const { 1376 const {
1377 return MultiColumnLayoutState(m_lastSetWorkedOn); 1377 return MultiColumnLayoutState(m_lastSetWorkedOn);
1378 } 1378 }
1379 1379
1380 void LayoutMultiColumnFlowThread::restoreMultiColumnLayoutState( 1380 void LayoutMultiColumnFlowThread::restoreMultiColumnLayoutState(
1381 const MultiColumnLayoutState& state) { 1381 const MultiColumnLayoutState& state) {
1382 m_lastSetWorkedOn = state.columnSet(); 1382 m_lastSetWorkedOn = state.columnSet();
1383 } 1383 }
1384 1384
1385 } // namespace blink 1385 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutBlockFlowLine.cpp ('k') | third_party/WebKit/Source/wtf/LinkedHashSet.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698