OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
172 if (isHTMLInputElement(*m_private)) | 172 if (isHTMLInputElement(*m_private)) |
173 return constUnwrap<HTMLInputElement>()->selectionEnd(); | 173 return constUnwrap<HTMLInputElement>()->selectionEnd(); |
174 if (isHTMLTextAreaElement(*m_private)) | 174 if (isHTMLTextAreaElement(*m_private)) |
175 return constUnwrap<HTMLTextAreaElement>()->selectionEnd(); | 175 return constUnwrap<HTMLTextAreaElement>()->selectionEnd(); |
176 return 0; | 176 return 0; |
177 } | 177 } |
178 | 178 |
179 WebString WebFormControlElement::alignmentForFormData() const { | 179 WebString WebFormControlElement::alignmentForFormData() const { |
180 if (const ComputedStyle* style = | 180 if (const ComputedStyle* style = |
181 constUnwrap<HTMLFormControlElement>()->computedStyle()) { | 181 constUnwrap<HTMLFormControlElement>()->computedStyle()) { |
182 if (style->textAlign() == ETextAlign::Right) | 182 if (style->textAlign() == ETextAlign::kRight) |
183 return WebString::fromUTF8("right"); | 183 return WebString::fromUTF8("right"); |
184 if (style->textAlign() == ETextAlign::Left) | 184 if (style->textAlign() == ETextAlign::kLeft) |
185 return WebString::fromUTF8("left"); | 185 return WebString::fromUTF8("left"); |
186 } | 186 } |
187 return WebString(); | 187 return WebString(); |
188 } | 188 } |
189 | 189 |
190 WebString WebFormControlElement::directionForFormData() const { | 190 WebString WebFormControlElement::directionForFormData() const { |
191 if (const ComputedStyle* style = | 191 if (const ComputedStyle* style = |
192 constUnwrap<HTMLFormControlElement>()->computedStyle()) { | 192 constUnwrap<HTMLFormControlElement>()->computedStyle()) { |
193 return style->isLeftToRightDirection() ? WebString::fromUTF8("ltr") | 193 return style->isLeftToRightDirection() ? WebString::fromUTF8("ltr") |
194 : WebString::fromUTF8("rtl"); | 194 : WebString::fromUTF8("rtl"); |
(...skipping 16 matching lines...) Expand all Loading... |
211 HTMLFormControlElement* elem) { | 211 HTMLFormControlElement* elem) { |
212 m_private = elem; | 212 m_private = elem; |
213 return *this; | 213 return *this; |
214 } | 214 } |
215 | 215 |
216 WebFormControlElement::operator HTMLFormControlElement*() const { | 216 WebFormControlElement::operator HTMLFormControlElement*() const { |
217 return toHTMLFormControlElement(m_private.get()); | 217 return toHTMLFormControlElement(m_private.get()); |
218 } | 218 } |
219 | 219 |
220 } // namespace blink | 220 } // namespace blink |
OLD | NEW |