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

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

Issue 143653008: Enable sticky positioning for table elements. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Got better fix for containingBlock() from webkit and updated by review comments. Created 6 years, 10 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
« no previous file with comments | « Source/core/rendering/RenderBox.cpp ('k') | Source/core/rendering/RenderTableRow.h » ('j') | 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) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com) 5 * (C) 2004 Allan Sandfeld Jensen (kde@carewolf.com)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserv ed. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2011 Apple Inc. All rights reserv ed.
7 * Copyright (C) 2009 Google Inc. All rights reserved. 7 * Copyright (C) 2009 Google Inc. All rights reserved.
8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/) 8 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/)
9 * 9 *
10 * This library is free software; you can redistribute it and/or 10 * This library is free software; you can redistribute it and/or
(...skipping 815 matching lines...) Expand 10 before | Expand all | Expand 10 after
826 break; 826 break;
827 827
828 if (o->style()->hasInFlowPosition() && o->isInline() && !o->isReplac ed()) { 828 if (o->style()->hasInFlowPosition() && o->isInline() && !o->isReplac ed()) {
829 o = o->containingBlock(); 829 o = o->containingBlock();
830 break; 830 break;
831 } 831 }
832 832
833 o = o->parent(); 833 o = o->parent();
834 } 834 }
835 835
836 if (o && !o->isRenderBlock())
837 o = o->containingBlock();
838
836 while (o && o->isAnonymousBlock()) 839 while (o && o->isAnonymousBlock())
837 o = o->containingBlock(); 840 o = o->containingBlock();
838 } else { 841 } else {
839 while (o && ((o->isInline() && !o->isReplaced()) || !o->isRenderBlock()) ) 842 while (o && ((o->isInline() && !o->isReplaced()) || !o->isRenderBlock()) )
840 o = o->parent(); 843 o = o->parent();
841 } 844 }
842 845
843 if (!o || !o->isRenderBlock()) 846 if (!o || !o->isRenderBlock())
844 return 0; // This can still happen in case of an orphaned tree 847 return 0; // This can still happen in case of an orphaned tree
845 848
(...skipping 2541 matching lines...) Expand 10 before | Expand all | Expand 10 after
3387 { 3390 {
3388 if (object1) { 3391 if (object1) {
3389 const WebCore::RenderObject* root = object1; 3392 const WebCore::RenderObject* root = object1;
3390 while (root->parent()) 3393 while (root->parent())
3391 root = root->parent(); 3394 root = root->parent();
3392 root->showRenderTreeAndMark(object1, "*", object2, "-", 0); 3395 root->showRenderTreeAndMark(object1, "*", object2, "-", 0);
3393 } 3396 }
3394 } 3397 }
3395 3398
3396 #endif 3399 #endif
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderBox.cpp ('k') | Source/core/rendering/RenderTableRow.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698