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

Side by Side Diff: sky/engine/core/editing/htmlediting.cpp

Issue 834693007: Remove the remaining parts of ignorePendingStylesheets and placeholder styles. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Remove comment. Created 5 years, 11 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 | « sky/engine/core/editing/VisibleUnits.cpp ('k') | sky/engine/core/events/MouseRelatedEvent.cpp » ('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) 2004, 2005, 2006, 2007 Apple Inc. All rights reserved. 2 * Copyright (C) 2004, 2005, 2006, 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 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 132
133 return 0; 133 return 0;
134 } 134 }
135 135
136 bool isEditablePosition(const Position& p, EditableType editableType, EUpdateSty le updateStyle) 136 bool isEditablePosition(const Position& p, EditableType editableType, EUpdateSty le updateStyle)
137 { 137 {
138 Node* node = p.parentAnchoredEquivalent().anchorNode(); 138 Node* node = p.parentAnchoredEquivalent().anchorNode();
139 if (!node) 139 if (!node)
140 return false; 140 return false;
141 if (updateStyle == UpdateStyle) 141 if (updateStyle == UpdateStyle)
142 node->document().updateLayoutIgnorePendingStylesheets(); 142 node->document().updateLayout();
143 else 143 else
144 ASSERT(updateStyle == DoNotUpdateStyle); 144 ASSERT(updateStyle == DoNotUpdateStyle);
145 145
146 return node->hasEditableStyle(editableType); 146 return node->hasEditableStyle(editableType);
147 } 147 }
148 148
149 bool isAtUnsplittableElement(const Position& pos) 149 bool isAtUnsplittableElement(const Position& pos)
150 { 150 {
151 Node* node = pos.deprecatedNode(); 151 Node* node = pos.deprecatedNode();
152 return node == editableRootForPosition(pos); 152 return node == editableRootForPosition(pos);
(...skipping 773 matching lines...) Expand 10 before | Expand all | Expand 10 after
926 // if the selection starts just before a paragraph break, skip over it 926 // if the selection starts just before a paragraph break, skip over it
927 if (isEndOfParagraph(visiblePosition)) 927 if (isEndOfParagraph(visiblePosition))
928 return visiblePosition.next().deepEquivalent().downstream(); 928 return visiblePosition.next().deepEquivalent().downstream();
929 929
930 // otherwise, make sure to be at the start of the first selected node, 930 // otherwise, make sure to be at the start of the first selected node,
931 // instead of possibly at the end of the last node before the selection 931 // instead of possibly at the end of the last node before the selection
932 return visiblePosition.deepEquivalent().downstream(); 932 return visiblePosition.deepEquivalent().downstream();
933 } 933 }
934 934
935 } // namespace blink 935 } // namespace blink
OLDNEW
« no previous file with comments | « sky/engine/core/editing/VisibleUnits.cpp ('k') | sky/engine/core/events/MouseRelatedEvent.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698