OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2005, 2011 Apple Inc. All rights reserved. | 2 * Copyright (C) 2005, 2011 Apple Inc. All rights reserved. |
3 * Copyright (C) 2010 Google Inc. All rights reserved. | 3 * Copyright (C) 2010 Google Inc. All rights reserved. |
4 * | 4 * |
5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
9 * | 9 * |
10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
119 forward = !(forward); | 119 forward = !(forward); |
120 HTMLInputElement* nextInputElement = findNextFocusableRadioButtonInGroup( | 120 HTMLInputElement* nextInputElement = findNextFocusableRadioButtonInGroup( |
121 toHTMLInputElement(&element()), forward); | 121 toHTMLInputElement(&element()), forward); |
122 while (nextInputElement) { | 122 while (nextInputElement) { |
123 inputElement = nextInputElement; | 123 inputElement = nextInputElement; |
124 nextInputElement = | 124 nextInputElement = |
125 findNextFocusableRadioButtonInGroup(nextInputElement, forward); | 125 findNextFocusableRadioButtonInGroup(nextInputElement, forward); |
126 } | 126 } |
127 } | 127 } |
128 if (inputElement) { | 128 if (inputElement) { |
129 document.setFocusedElement(inputElement, | 129 document.setFocusedElement( |
130 FocusParams(SelectionBehaviorOnFocus::Restore, | 130 inputElement, |
131 WebFocusTypeNone, nullptr)); | 131 FocusParams(SelectionBehaviorOnFocus::Restore, WebFocusTypeNone, |
| 132 InputDeviceCapabilities::Null)); |
132 inputElement->dispatchSimulatedClick(event, SendNoEvents); | 133 inputElement->dispatchSimulatedClick(event, SendNoEvents); |
133 event->setDefaultHandled(); | 134 event->setDefaultHandled(); |
134 return; | 135 return; |
135 } | 136 } |
136 } | 137 } |
137 | 138 |
138 void RadioInputType::handleKeyupEvent(KeyboardEvent* event) { | 139 void RadioInputType::handleKeyupEvent(KeyboardEvent* event) { |
139 const String& key = event->key(); | 140 const String& key = event->key(); |
140 if (key != " ") | 141 if (key != " ") |
141 return; | 142 return; |
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
234 *inputElement, current->form(), forward)) { | 235 *inputElement, current->form(), forward)) { |
235 if (current->form() == inputElement->form() && | 236 if (current->form() == inputElement->form() && |
236 inputElement->type() == InputTypeNames::radio && | 237 inputElement->type() == InputTypeNames::radio && |
237 inputElement->name() == current->name()) | 238 inputElement->name() == current->name()) |
238 return inputElement; | 239 return inputElement; |
239 } | 240 } |
240 return nullptr; | 241 return nullptr; |
241 } | 242 } |
242 | 243 |
243 } // namespace blink | 244 } // namespace blink |
OLD | NEW |