Closed Bug 333690 Opened 18 years ago Closed 8 years ago

[Meta] Expose specific interfaces for xforms controls

Categories

(Core Graveyard :: XForms, enhancement)

enhancement
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: surkov, Unassigned)

References

Details

HTML Forms controls have interface to get/modify their values from a script. XForms controls supposes that their values can be changed only by instance data modifying. I guess it's not always good. F.x. if want to replace selected text in xforms:input on some other text then I can't do it now. Probably sometimes the script author will be feel yourself fine if he can to change selection of xforms:select by using index or item (bug 332083) (and he shouldn't parse value of instance data).

Probably we should expose interface for such proposes.
Some thoughts after irc talk with Allan. The bug is about some xforms controls should have interface like it do their kins (xul and xhtml controls). F.x. it's good if xforms:input will have methods for maxlength setting or selection managing. Some such properties/methods should be putted into accessors interface.
I guess I don't get what you mean by the initial bug comment...you can set the value of the control currently using the accessor for the control.  Use setValue or setContent.

I do agree with the second comment, though.  Some things like setting the selected value via index would be nice via script.  Also the maxlength of a field would be nice.
I mark the bug as meta because I guess we can cover at once that not only xforms:input should have additional methods. For xforms:input and other I'll file new bug.
Status: UNCONFIRMED → NEW
Ever confirmed: true
Summary: Expose interface for value xforms controls access → [Meta] Expose specific interfaces for xforms controls
Depends on: 333815
Methods/properties should be redirected to corresponding methods/properties of native control widgets and it means that thease methods/properties should be defined on XBL bindings. But such interfaces should be defined as a part of accessors interface that is defined in XTF binding. How can interfaces be implemented?
Severity: normal → enhancement
Assignee: aaronr → xforms
RIP xforms
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → WONTFIX
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.