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

Side by Side Diff: third_party/WebKit/Source/core/html/HTMLOptionElement.cpp

Issue 2701993002: DO NOT COMMIT: Results of running new (proposed) clang-format on Blink (Closed)
Patch Set: Created 3 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
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@nypop.com) 5 * (C) 2006 Alexey Proskuryakov (ap@nypop.com)
6 * Copyright (C) 2004, 2005, 2006, 2010 Apple Inc. All rights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2010 Apple Inc. All rights reserved.
7 * Copyright (C) 2010 Google Inc. All rights reserved. 7 * Copyright (C) 2010 Google Inc. All rights reserved.
8 * Copyright (C) 2011 Motorola Mobility, Inc. All rights reserved. 8 * Copyright (C) 2011 Motorola Mobility, Inc. All rights reserved.
9 * 9 *
10 * This library is free software; you can redistribute it and/or 10 * This library is free software; you can redistribute it and/or
(...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after
368 String HTMLOptionElement::defaultToolTip() const { 368 String HTMLOptionElement::defaultToolTip() const {
369 if (HTMLSelectElement* select = ownerSelectElement()) 369 if (HTMLSelectElement* select = ownerSelectElement())
370 return select->defaultToolTip(); 370 return select->defaultToolTip();
371 return String(); 371 return String();
372 } 372 }
373 373
374 Node::InsertionNotificationRequest HTMLOptionElement::insertedInto( 374 Node::InsertionNotificationRequest HTMLOptionElement::insertedInto(
375 ContainerNode* insertionPoint) { 375 ContainerNode* insertionPoint) {
376 HTMLElement::insertedInto(insertionPoint); 376 HTMLElement::insertedInto(insertionPoint);
377 if (HTMLSelectElement* select = ownerSelectElement()) { 377 if (HTMLSelectElement* select = ownerSelectElement()) {
378 if (insertionPoint == select || (isHTMLOptGroupElement(*insertionPoint) && 378 if (insertionPoint == select ||
379 insertionPoint->parentNode() == select)) 379 (isHTMLOptGroupElement(*insertionPoint) &&
380 insertionPoint->parentNode() == select))
380 select->optionInserted(*this, m_isSelected); 381 select->optionInserted(*this, m_isSelected);
381 } 382 }
382 return InsertionDone; 383 return InsertionDone;
383 } 384 }
384 385
385 void HTMLOptionElement::removedFrom(ContainerNode* insertionPoint) { 386 void HTMLOptionElement::removedFrom(ContainerNode* insertionPoint) {
386 if (isHTMLSelectElement(*insertionPoint)) { 387 if (isHTMLSelectElement(*insertionPoint)) {
387 if (!parentNode() || isHTMLOptGroupElement(*parentNode())) 388 if (!parentNode() || isHTMLOptGroupElement(*parentNode()))
388 toHTMLSelectElement(insertionPoint)->optionRemoved(*this); 389 toHTMLSelectElement(insertionPoint)->optionRemoved(*this);
389 } else if (isHTMLOptGroupElement(*insertionPoint)) { 390 } else if (isHTMLOptGroupElement(*insertionPoint)) {
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after
454 } 455 }
455 456
456 String HTMLOptionElement::innerText() { 457 String HTMLOptionElement::innerText() {
457 // A workaround for crbug.com/424578. We add ShadowRoot to an OPTION, but 458 // A workaround for crbug.com/424578. We add ShadowRoot to an OPTION, but
458 // innerText behavior for Shadow DOM is unclear. We just return the same 459 // innerText behavior for Shadow DOM is unclear. We just return the same
459 // string before adding ShadowRoot. 460 // string before adding ShadowRoot.
460 return textContent(); 461 return textContent();
461 } 462 }
462 463
463 } // namespace blink 464 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLMarqueeElement.cpp ('k') | third_party/WebKit/Source/core/html/HTMLPlugInElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698