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

Side by Side Diff: third_party/WebKit/Source/core/editing/serializers/Serialization.cpp

Issue 1896793002: Rename (updateLayout/updateStyle).*.() to updateStyleAndLayout.*.() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserv ed. 2 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserv ed.
3 * Copyright (C) 2008, 2009, 2010, 2011 Google Inc. All rights reserved. 3 * Copyright (C) 2008, 2009, 2010, 2011 Google Inc. All rights reserved.
4 * Copyright (C) 2011 Igalia S.L. 4 * Copyright (C) 2011 Igalia S.L.
5 * Copyright (C) 2011 Motorola Mobility. All rights reserved. 5 * Copyright (C) 2011 Motorola Mobility. All rights reserved.
6 * 6 *
7 * Redistribution and use in source and binary forms, with or without 7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions 8 * modification, are permitted provided that the following conditions
9 * are met: 9 * are met:
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after
248 RELEASE_ASSERT(startPosition.compareTo(endPosition) <= 0); 248 RELEASE_ASSERT(startPosition.compareTo(endPosition) <= 0);
249 249
250 bool collapsed = startPosition == endPosition; 250 bool collapsed = startPosition == endPosition;
251 if (collapsed) 251 if (collapsed)
252 return emptyString(); 252 return emptyString();
253 Node* commonAncestor = Strategy::commonAncestor(*startPosition.computeContai nerNode(), *endPosition.computeContainerNode()); 253 Node* commonAncestor = Strategy::commonAncestor(*startPosition.computeContai nerNode(), *endPosition.computeContainerNode());
254 if (!commonAncestor) 254 if (!commonAncestor)
255 return emptyString(); 255 return emptyString();
256 256
257 Document* document = startPosition.document(); 257 Document* document = startPosition.document();
258 document->updateLayoutIgnorePendingStylesheets(); 258 document->updateStyleAndLayoutIgnorePendingStylesheets();
259 259
260 HTMLElement* specialCommonAncestor = highestAncestorToWrapMarkup<Strategy>(s tartPosition, endPosition, shouldAnnotate, constrainingAncestor); 260 HTMLElement* specialCommonAncestor = highestAncestorToWrapMarkup<Strategy>(s tartPosition, endPosition, shouldAnnotate, constrainingAncestor);
261 StyledMarkupSerializer<Strategy> serializer(shouldResolveURLs, shouldAnnotat e, startPosition, endPosition, specialCommonAncestor, convertBlocksToInlines); 261 StyledMarkupSerializer<Strategy> serializer(shouldResolveURLs, shouldAnnotat e, startPosition, endPosition, specialCommonAncestor, convertBlocksToInlines);
262 return serializer.createMarkup(); 262 return serializer.createMarkup();
263 } 263 }
264 264
265 String createMarkup(const Position& startPosition, const Position& endPosition, EAnnotateForInterchange shouldAnnotate, ConvertBlocksToInlines convertBlocksToIn lines, EAbsoluteURLs shouldResolveURLs, Node* constrainingAncestor) 265 String createMarkup(const Position& startPosition, const Position& endPosition, EAnnotateForInterchange shouldAnnotate, ConvertBlocksToInlines convertBlocksToIn lines, EAbsoluteURLs shouldResolveURLs, Node* constrainingAncestor)
266 { 266 {
267 return CreateMarkupAlgorithm<EditingStrategy>::createMarkup(startPosition, e ndPosition, shouldAnnotate, convertBlocksToInlines, shouldResolveURLs, constrain ingAncestor); 267 return CreateMarkupAlgorithm<EditingStrategy>::createMarkup(startPosition, e ndPosition, shouldAnnotate, convertBlocksToInlines, shouldResolveURLs, constrain ingAncestor);
268 } 268 }
(...skipping 414 matching lines...) Expand 10 before | Expand all | Expand 10 after
683 Text* textNext = toText(next); 683 Text* textNext = toText(next);
684 textNode->appendData(textNext->data()); 684 textNode->appendData(textNext->data());
685 if (textNext->parentNode()) // Might have been removed by mutation event. 685 if (textNext->parentNode()) // Might have been removed by mutation event.
686 textNext->remove(exceptionState); 686 textNext->remove(exceptionState);
687 } 687 }
688 688
689 template class CORE_TEMPLATE_EXPORT CreateMarkupAlgorithm<EditingStrategy>; 689 template class CORE_TEMPLATE_EXPORT CreateMarkupAlgorithm<EditingStrategy>;
690 template class CORE_TEMPLATE_EXPORT CreateMarkupAlgorithm<EditingInFlatTreeStrat egy>; 690 template class CORE_TEMPLATE_EXPORT CreateMarkupAlgorithm<EditingInFlatTreeStrat egy>;
691 691
692 } // namespace blink 692 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698