| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). | 2 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). |
| 3 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 3 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 4 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 4 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 5 * (C) 2001 Dirk Mueller (mueller@kde.org) | 5 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 6 * Copyright (C) 2004, 2005, 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights
reserved. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights
reserved. |
| 7 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) | 7 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) |
| 8 * Copyright (C) 2010 Google Inc. All rights reserved. | 8 * Copyright (C) 2010 Google Inc. All rights reserved. |
| 9 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) | 9 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo
bile.com/) |
| 10 * | 10 * |
| (...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 267 void HTMLSelectElement::parseAttribute(const QualifiedName& name, const AtomicSt
ring& value) | 267 void HTMLSelectElement::parseAttribute(const QualifiedName& name, const AtomicSt
ring& value) |
| 268 { | 268 { |
| 269 if (name == sizeAttr) { | 269 if (name == sizeAttr) { |
| 270 int oldSize = m_size; | 270 int oldSize = m_size; |
| 271 // Set the attribute value to a number. | 271 // Set the attribute value to a number. |
| 272 // This is important since the style rules for this attribute can determ
ine the appearance property. | 272 // This is important since the style rules for this attribute can determ
ine the appearance property. |
| 273 int size = value.toInt(); | 273 int size = value.toInt(); |
| 274 AtomicString attrSize = AtomicString::number(size); | 274 AtomicString attrSize = AtomicString::number(size); |
| 275 if (attrSize != value) { | 275 if (attrSize != value) { |
| 276 // FIXME: This is horribly factored. | 276 // FIXME: This is horribly factored. |
| 277 if (Attribute* sizeAttribute = ensureUniqueElementData()->getAttribu
teItem(sizeAttr)) | 277 if (Attribute* sizeAttribute = ensureUniqueElementData().getAttribut
eItem(sizeAttr)) |
| 278 sizeAttribute->setValue(attrSize); | 278 sizeAttribute->setValue(attrSize); |
| 279 } | 279 } |
| 280 size = max(size, 1); | 280 size = max(size, 1); |
| 281 | 281 |
| 282 // Ensure that we've determined selectedness of the items at least once
prior to changing the size. | 282 // Ensure that we've determined selectedness of the items at least once
prior to changing the size. |
| 283 if (oldSize != size) | 283 if (oldSize != size) |
| 284 updateListItemSelectedStates(); | 284 updateListItemSelectedStates(); |
| 285 | 285 |
| 286 m_size = size; | 286 m_size = size; |
| 287 setNeedsValidityCheck(); | 287 setNeedsValidityCheck(); |
| (...skipping 1273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1561 { | 1561 { |
| 1562 return true; | 1562 return true; |
| 1563 } | 1563 } |
| 1564 | 1564 |
| 1565 bool HTMLSelectElement::supportsAutofocus() const | 1565 bool HTMLSelectElement::supportsAutofocus() const |
| 1566 { | 1566 { |
| 1567 return true; | 1567 return true; |
| 1568 } | 1568 } |
| 1569 | 1569 |
| 1570 } // namespace | 1570 } // namespace |
| OLD | NEW |