| OLD | NEW |
| 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 225 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 236 } | 236 } |
| 237 | 237 |
| 238 bool HTMLTextAreaElement::shouldShowFocusRingOnMouseFocus() const | 238 bool HTMLTextAreaElement::shouldShowFocusRingOnMouseFocus() const |
| 239 { | 239 { |
| 240 return true; | 240 return true; |
| 241 } | 241 } |
| 242 | 242 |
| 243 void HTMLTextAreaElement::updateFocusAppearance(SelectionBehaviorOnFocus selecti
onBehavior) | 243 void HTMLTextAreaElement::updateFocusAppearance(SelectionBehaviorOnFocus selecti
onBehavior) |
| 244 { | 244 { |
| 245 switch (selectionBehavior) { | 245 switch (selectionBehavior) { |
| 246 case SelectionBehaviorOnFocus::Reset: | 246 case SelectionBehaviorOnFocus::Reset: // Fallthrough. |
| 247 setSelectionRange(0, 0, SelectionHasNoDirection, NotDispatchSelectEvent)
; | |
| 248 break; | |
| 249 case SelectionBehaviorOnFocus::Restore: | 247 case SelectionBehaviorOnFocus::Restore: |
| 250 restoreCachedSelection(); | 248 restoreCachedSelection(); |
| 251 break; | 249 break; |
| 252 case SelectionBehaviorOnFocus::None: | 250 case SelectionBehaviorOnFocus::None: |
| 253 return; | 251 return; |
| 254 } | 252 } |
| 255 if (document().frame()) | 253 if (document().frame()) |
| 256 document().frame()->selection().revealSelection(); | 254 document().frame()->selection().revealSelection(); |
| 257 } | 255 } |
| 258 | 256 |
| (...skipping 391 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 650 | 648 |
| 651 void HTMLTextAreaElement::copyNonAttributePropertiesFromElement(const Element& s
ource) | 649 void HTMLTextAreaElement::copyNonAttributePropertiesFromElement(const Element& s
ource) |
| 652 { | 650 { |
| 653 const HTMLTextAreaElement& sourceElement = static_cast<const HTMLTextAreaEle
ment&>(source); | 651 const HTMLTextAreaElement& sourceElement = static_cast<const HTMLTextAreaEle
ment&>(source); |
| 654 setValueCommon(sourceElement.value(), DispatchNoEvent, SetSeletion); | 652 setValueCommon(sourceElement.value(), DispatchNoEvent, SetSeletion); |
| 655 m_isDirty = sourceElement.m_isDirty; | 653 m_isDirty = sourceElement.m_isDirty; |
| 656 HTMLTextFormControlElement::copyNonAttributePropertiesFromElement(source); | 654 HTMLTextFormControlElement::copyNonAttributePropertiesFromElement(source); |
| 657 } | 655 } |
| 658 | 656 |
| 659 } // namespace blink | 657 } // namespace blink |
| OLD | NEW |