Last change
on this file since 441 was
441,
checked in by hendrikvanantwerpen, 12 years ago
|
Big cleanup of the question content.
- Replaced old list implementations with a new one that behaves like a form widget.
- All question content is now in separate widgets, not in the factory itself.
- Added form and widget validation for question editing.
|
File size:
666 bytes
|
Line | |
---|
1 | define([ |
---|
2 | "../../../widgets/_ComplexValueWidget", |
---|
3 | "dojo/_base/declare", |
---|
4 | "dojo/text!./templates/TextInputWidget.html" |
---|
5 | ], function(_ComplexValueWidget, declare, template) { |
---|
6 | return declare([_ComplexValueWidget],{ |
---|
7 | text: '', |
---|
8 | maxLength: null, |
---|
9 | templateString: template, |
---|
10 | startup: function() { |
---|
11 | if ( this.maxLength ) { |
---|
12 | this.textArea.set('maxLength', this.maxLength); |
---|
13 | } |
---|
14 | }, |
---|
15 | _getValueAttr: function() { |
---|
16 | return this.textBox.get('value'); |
---|
17 | }, |
---|
18 | _setValueAttr: function(value) { |
---|
19 | return this.textBox.set('value', value); |
---|
20 | } |
---|
21 | }); |
---|
22 | }); |
---|
Note: See
TracBrowser
for help on using the repository browser.