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

Side by Side Diff: Source/core/dom/shadow/ShadowRoot.cpp

Issue 18548003: Rename ExceptionCode constants to use the names in the spec (2/3) (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/dom/SelectorQuery.cpp ('k') | Source/core/editing/markup.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) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 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 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 } 113 }
114 114
115 String ShadowRoot::innerHTML() const 115 String ShadowRoot::innerHTML() const
116 { 116 {
117 return createMarkup(this, ChildrenOnly); 117 return createMarkup(this, ChildrenOnly);
118 } 118 }
119 119
120 void ShadowRoot::setInnerHTML(const String& markup, ExceptionCode& ec) 120 void ShadowRoot::setInnerHTML(const String& markup, ExceptionCode& ec)
121 { 121 {
122 if (isOrphan()) { 122 if (isOrphan()) {
123 ec = INVALID_ACCESS_ERR; 123 ec = InvalidAccessError;
124 return; 124 return;
125 } 125 }
126 126
127 if (RefPtr<DocumentFragment> fragment = createFragmentForInnerOuterHTML(mark up, host(), AllowScriptingContent, ec)) 127 if (RefPtr<DocumentFragment> fragment = createFragmentForInnerOuterHTML(mark up, host(), AllowScriptingContent, ec))
128 replaceChildrenWithFragment(this, fragment.release(), ec); 128 replaceChildrenWithFragment(this, fragment.release(), ec);
129 } 129 }
130 130
131 bool ShadowRoot::childTypeAllowed(NodeType type) const 131 bool ShadowRoot::childTypeAllowed(NodeType type) const
132 { 132 {
133 switch (type) { 133 switch (type) {
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
293 { 293 {
294 MemoryClassInfo info(memoryObjectInfo, this, WebCoreMemoryTypes::DOM); 294 MemoryClassInfo info(memoryObjectInfo, this, WebCoreMemoryTypes::DOM);
295 DocumentFragment::reportMemoryUsage(memoryObjectInfo); 295 DocumentFragment::reportMemoryUsage(memoryObjectInfo);
296 TreeScope::reportMemoryUsage(memoryObjectInfo); 296 TreeScope::reportMemoryUsage(memoryObjectInfo);
297 info.addMember(m_prev, "prev"); 297 info.addMember(m_prev, "prev");
298 info.addMember(m_next, "next"); 298 info.addMember(m_next, "next");
299 info.addMember(m_scopeDistribution, "scopeDistribution"); 299 info.addMember(m_scopeDistribution, "scopeDistribution");
300 } 300 }
301 301
302 } 302 }
OLDNEW
« no previous file with comments | « Source/core/dom/SelectorQuery.cpp ('k') | Source/core/editing/markup.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698