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

Side by Side Diff: Source/core/html/HTMLTextAreaElement.cpp

Issue 560273004: Use AtomicString API directly (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add more Created 6 years, 3 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/html/HTMLObjectElement.cpp ('k') | Source/core/rendering/RenderQuote.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) 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 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2010 Apple Inc. All rights reserv ed. 5 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2010 Apple Inc. All rights reserv ed.
6 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) 6 * (C) 2006 Alexey Proskuryakov (ap@nypop.com)
7 * Copyright (C) 2007 Samuel Weinig (sam@webkit.org) 7 * Copyright (C) 2007 Samuel Weinig (sam@webkit.org)
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 424 matching lines...) Expand 10 before | Expand all | Expand 10 after
435 435
436 insertBefore(document().createTextNode(value), firstChild(), IGNORE_EXCEPTIO N); 436 insertBefore(document().createTextNode(value), firstChild(), IGNORE_EXCEPTIO N);
437 437
438 if (!m_isDirty) 438 if (!m_isDirty)
439 setNonDirtyValue(value); 439 setNonDirtyValue(value);
440 } 440 }
441 441
442 int HTMLTextAreaElement::maxLength() const 442 int HTMLTextAreaElement::maxLength() const
443 { 443 {
444 bool ok; 444 bool ok;
445 int value = getAttribute(maxlengthAttr).string().toInt(&ok); 445 int value = getAttribute(maxlengthAttr).toInt(&ok);
446 return ok && value >= 0 ? value : -1; 446 return ok && value >= 0 ? value : -1;
447 } 447 }
448 448
449 void HTMLTextAreaElement::setMaxLength(int newValue, ExceptionState& exceptionSt ate) 449 void HTMLTextAreaElement::setMaxLength(int newValue, ExceptionState& exceptionSt ate)
450 { 450 {
451 if (newValue < 0) 451 if (newValue < 0)
452 exceptionState.throwDOMException(IndexSizeError, "The value provided (" + String::number(newValue) + ") is not positive or 0."); 452 exceptionState.throwDOMException(IndexSizeError, "The value provided (" + String::number(newValue) + ") is not positive or 0.");
453 else 453 else
454 setIntegralAttribute(maxlengthAttr, newValue); 454 setIntegralAttribute(maxlengthAttr, newValue);
455 } 455 }
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
564 { 564 {
565 return true; 565 return true;
566 } 566 }
567 567
568 bool HTMLTextAreaElement::supportsAutofocus() const 568 bool HTMLTextAreaElement::supportsAutofocus() const
569 { 569 {
570 return true; 570 return true;
571 } 571 }
572 572
573 } 573 }
OLDNEW
« no previous file with comments | « Source/core/html/HTMLObjectElement.cpp ('k') | Source/core/rendering/RenderQuote.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698