| 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 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 52 WebElement::assign(e); | 52 WebElement::assign(e); |
| 53 return *this; | 53 return *this; |
| 54 } | 54 } |
| 55 void assign(const WebFormControlElement& e) { WebElement::assign(e); } | 55 void assign(const WebFormControlElement& e) { WebElement::assign(e); } |
| 56 | 56 |
| 57 BLINK_EXPORT bool isEnabled() const; | 57 BLINK_EXPORT bool isEnabled() const; |
| 58 BLINK_EXPORT bool isReadOnly() const; | 58 BLINK_EXPORT bool isReadOnly() const; |
| 59 BLINK_EXPORT WebString formControlName() const; | 59 BLINK_EXPORT WebString formControlName() const; |
| 60 BLINK_EXPORT WebString formControlType() const; | 60 BLINK_EXPORT WebString formControlType() const; |
| 61 | 61 |
| 62 // FIXME: remove this method when no longer used. |
| 62 BLINK_EXPORT void dispatchFormControlChangeEvent(); | 63 BLINK_EXPORT void dispatchFormControlChangeEvent(); |
| 63 | 64 |
| 64 BLINK_EXPORT bool isAutofilled() const; | 65 BLINK_EXPORT bool isAutofilled() const; |
| 65 BLINK_EXPORT void setAutofilled(bool); | 66 BLINK_EXPORT void setAutofilled(bool); |
| 66 | 67 |
| 67 // Returns true if autocomplete attribute of the element is not set as "off"
. | 68 // Returns true if autocomplete attribute of the element is not set as "off"
. |
| 68 BLINK_EXPORT bool autoComplete() const; | 69 BLINK_EXPORT bool autoComplete() const; |
| 69 | 70 |
| 70 // Sets value for input element, textarea element and select element. For se
lect | 71 // Sets value for input element, textarea element and select element. For se
lect |
| 71 // element it finds the option with value matches the given parameter and ma
ke the | 72 // element it finds the option with value matches the given parameter and ma
ke the |
| 72 // option as the current selection. | 73 // option as the current selection. |
| 73 BLINK_EXPORT void setValue(const WebString&, bool sendChangeEvent = false); | 74 BLINK_EXPORT void setValue(const WebString&, bool sendEvents = false); |
| 74 // Returns value of element. For select element, it returns the value of | 75 // Returns value of element. For select element, it returns the value of |
| 75 // the selected option if present. If no selected option, an empty string | 76 // the selected option if present. If no selected option, an empty string |
| 76 // is returned. If element doesn't fall into input element, textarea element | 77 // is returned. If element doesn't fall into input element, textarea element |
| 77 // and select element categories, a null string is returned. | 78 // and select element categories, a null string is returned. |
| 78 BLINK_EXPORT WebString value() const; | 79 BLINK_EXPORT WebString value() const; |
| 79 // Sets suggested value for element. For select element it finds the option | 80 // Sets suggested value for element. For select element it finds the option |
| 80 // with value matches the given parameter and make the option as the suggest
ed | 81 // with value matches the given parameter and make the option as the suggest
ed |
| 81 // selection. The goal of introducing suggested value is to not leak any inf
ormation | 82 // selection. The goal of introducing suggested value is to not leak any inf
ormation |
| 82 // to JavaScript. | 83 // to JavaScript. |
| 83 BLINK_EXPORT void setSuggestedValue(const WebString&); | 84 BLINK_EXPORT void setSuggestedValue(const WebString&); |
| (...skipping 30 matching lines...) Expand all Loading... |
| 114 #if BLINK_IMPLEMENTATION | 115 #if BLINK_IMPLEMENTATION |
| 115 WebFormControlElement(const WTF::PassRefPtr<WebCore::HTMLFormControlElement>
&); | 116 WebFormControlElement(const WTF::PassRefPtr<WebCore::HTMLFormControlElement>
&); |
| 116 WebFormControlElement& operator=(const WTF::PassRefPtr<WebCore::HTMLFormCont
rolElement>&); | 117 WebFormControlElement& operator=(const WTF::PassRefPtr<WebCore::HTMLFormCont
rolElement>&); |
| 117 operator WTF::PassRefPtr<WebCore::HTMLFormControlElement>() const; | 118 operator WTF::PassRefPtr<WebCore::HTMLFormControlElement>() const; |
| 118 #endif | 119 #endif |
| 119 }; | 120 }; |
| 120 | 121 |
| 121 } // namespace blink | 122 } // namespace blink |
| 122 | 123 |
| 123 #endif | 124 #endif |
| OLD | NEW |