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

Side by Side Diff: Source/core/dom/Document.cpp

Issue 158593003: Remove Unused measure DocumentCreateAttributeNS (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 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/dom/Document.h ('k') | Source/core/dom/Document.idl » ('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) 2001 Dirk Mueller (mueller@kde.org) 4 * (C) 2001 Dirk Mueller (mueller@kde.org)
5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r ights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2011, 2012 Apple Inc. All r ights reserved.
7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/) 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t orchmobile.com/)
8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved. 8 * Copyright (C) 2008, 2009, 2011, 2012 Google Inc. All rights reserved.
9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) 9 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies)
10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved. 10 * Copyright (C) Research In Motion Limited 2010-2011. All rights reserved.
(...skipping 4282 matching lines...) Expand 10 before | Expand all | Expand 10 after
4293 { 4293 {
4294 if (m_contextDocument) 4294 if (m_contextDocument)
4295 return m_contextDocument; 4295 return m_contextDocument;
4296 if (m_frame) 4296 if (m_frame)
4297 return m_weakFactory.createWeakPtr(); 4297 return m_weakFactory.createWeakPtr();
4298 return WeakPtr<Document>(0); 4298 return WeakPtr<Document>(0);
4299 } 4299 }
4300 4300
4301 PassRefPtr<Attr> Document::createAttribute(const AtomicString& name, ExceptionSt ate& exceptionState) 4301 PassRefPtr<Attr> Document::createAttribute(const AtomicString& name, ExceptionSt ate& exceptionState)
4302 { 4302 {
4303 return createAttributeNS(nullAtom, name, exceptionState, true);
4304 }
4305
4306 PassRefPtr<Attr> Document::createAttributeNS(const AtomicString& namespaceURI, c onst AtomicString& qualifiedName, ExceptionState& exceptionState, bool shouldIgn oreNamespaceChecks)
4307 {
4308 AtomicString prefix, localName; 4303 AtomicString prefix, localName;
4309 if (!parseQualifiedName(qualifiedName, prefix, localName, exceptionState)) 4304 if (!parseQualifiedName(name, prefix, localName, exceptionState))
4310 return 0; 4305 return 0;
4311 4306
4312 QualifiedName qName(prefix, localName, namespaceURI); 4307 QualifiedName qName(prefix, localName, nullAtom);
4313
4314 if (!shouldIgnoreNamespaceChecks && !hasValidNamespaceForAttributes(qName)) {
4315 exceptionState.throwDOMException(NamespaceError, "The namespace URI prov ided ('" + namespaceURI + "') is not valid for the qualified name provided ('" + qualifiedName + "').");
4316 return 0;
4317 }
4318 4308
4319 return Attr::create(*this, qName, emptyAtom); 4309 return Attr::create(*this, qName, emptyAtom);
4320 } 4310 }
4321 4311
4322 const SVGDocumentExtensions* Document::svgExtensions() 4312 const SVGDocumentExtensions* Document::svgExtensions()
4323 { 4313 {
4324 return m_svgExtensions.get(); 4314 return m_svgExtensions.get();
4325 } 4315 }
4326 4316
4327 SVGDocumentExtensions* Document::accessSVGExtensions() 4317 SVGDocumentExtensions* Document::accessSVGExtensions()
(...skipping 1086 matching lines...) Expand 10 before | Expand all | Expand 10 after
5414 void Document::defaultEventHandler(Event* event) 5404 void Document::defaultEventHandler(Event* event)
5415 { 5405 {
5416 if (frame() && frame()->remotePlatformLayer()) { 5406 if (frame() && frame()->remotePlatformLayer()) {
5417 frame()->chromeClient().forwardInputEvent(this, event); 5407 frame()->chromeClient().forwardInputEvent(this, event);
5418 return; 5408 return;
5419 } 5409 }
5420 Node::defaultEventHandler(event); 5410 Node::defaultEventHandler(event);
5421 } 5411 }
5422 5412
5423 } // namespace WebCore 5413 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/dom/Document.h ('k') | Source/core/dom/Document.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698