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

Side by Side Diff: third_party/WebKit/Source/core/dom/PseudoElement.cpp

Issue 1686483002: Oilpan: Remove most WillBe types from the code base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google 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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Neither the name of Google Inc. nor the names of its 10 * * Neither the name of Google Inc. nor the names of its
(...skipping 17 matching lines...) Expand all
28 28
29 #include "core/dom/FirstLetterPseudoElement.h" 29 #include "core/dom/FirstLetterPseudoElement.h"
30 #include "core/frame/UseCounter.h" 30 #include "core/frame/UseCounter.h"
31 #include "core/inspector/InspectorInstrumentation.h" 31 #include "core/inspector/InspectorInstrumentation.h"
32 #include "core/layout/LayoutObject.h" 32 #include "core/layout/LayoutObject.h"
33 #include "core/layout/LayoutQuote.h" 33 #include "core/layout/LayoutQuote.h"
34 #include "core/style/ContentData.h" 34 #include "core/style/ContentData.h"
35 35
36 namespace blink { 36 namespace blink {
37 37
38 PassRefPtrWillBeRawPtr<PseudoElement> PseudoElement::create(Element* parent, Pse udoId pseudoId) 38 RawPtr<PseudoElement> PseudoElement::create(Element* parent, PseudoId pseudoId)
39 { 39 {
40 return adoptRefWillBeNoop(new PseudoElement(parent, pseudoId)); 40 return new PseudoElement(parent, pseudoId);
41 } 41 }
42 42
43 const QualifiedName& pseudoElementTagName(PseudoId pseudoId) 43 const QualifiedName& pseudoElementTagName(PseudoId pseudoId)
44 { 44 {
45 switch (pseudoId) { 45 switch (pseudoId) {
46 case PseudoIdAfter: { 46 case PseudoIdAfter: {
47 DEFINE_STATIC_LOCAL(QualifiedName, after, (nullAtom, "<pseudo:after>", n ullAtom)); 47 DEFINE_STATIC_LOCAL(QualifiedName, after, (nullAtom, "<pseudo:after>", n ullAtom));
48 return after; 48 return after;
49 } 49 }
50 case PseudoIdBefore: { 50 case PseudoIdBefore: {
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 void PseudoElement::dispose() 101 void PseudoElement::dispose()
102 { 102 {
103 ASSERT(parentOrShadowHostElement()); 103 ASSERT(parentOrShadowHostElement());
104 104
105 InspectorInstrumentation::pseudoElementDestroyed(this); 105 InspectorInstrumentation::pseudoElementDestroyed(this);
106 106
107 ASSERT(!nextSibling()); 107 ASSERT(!nextSibling());
108 ASSERT(!previousSibling()); 108 ASSERT(!previousSibling());
109 109
110 detach(); 110 detach();
111 RefPtrWillBeRawPtr<Element> parent = parentOrShadowHostElement(); 111 RawPtr<Element> parent = parentOrShadowHostElement();
112 document().adoptIfNeeded(*this); 112 document().adoptIfNeeded(*this);
113 setParentOrShadowHostNode(0); 113 setParentOrShadowHostNode(0);
114 removedFrom(parent.get()); 114 removedFrom(parent.get());
115 } 115 }
116 116
117 void PseudoElement::attach(const AttachContext& context) 117 void PseudoElement::attach(const AttachContext& context)
118 { 118 {
119 ASSERT(!layoutObject()); 119 ASSERT(!layoutObject());
120 120
121 Element::attach(context); 121 Element::attach(context);
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 // us and our parent so make sure we skip over them. 187 // us and our parent so make sure we skip over them.
188 LayoutObject* ancestor = layoutObject()->parent(); 188 LayoutObject* ancestor = layoutObject()->parent();
189 while (ancestor->isAnonymous() || (ancestor->node() && ancestor->node()->isP seudoElement())) { 189 while (ancestor->isAnonymous() || (ancestor->node() && ancestor->node()->isP seudoElement())) {
190 ASSERT(ancestor->parent()); 190 ASSERT(ancestor->parent());
191 ancestor = ancestor->parent(); 191 ancestor = ancestor->parent();
192 } 192 }
193 return ancestor->node(); 193 return ancestor->node();
194 } 194 }
195 195
196 } // namespace blink 196 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/dom/PseudoElement.h ('k') | third_party/WebKit/Source/core/dom/Range.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698