Requires

Provides

Input.js

A base class for all kinds of form controls

License:
Public domain (http://unlicense.org).
Authors:
Yaroslaff Fedin
  1. 22
  2. 23
  3. 24
  4. 25
  5. 26
  6. 27
  7. 28
  8. 29
  9. 30
  10. 31
  11. 32
  12. 33
  13. 34
  14. 35
  15. 36
  16. 37
  17. 38
  18. 39
  19. 40
  20. 41
  21. 42
  22. 43
  23. 44
  24. 45
  25. 46
  26. 47
  27. 48
  28. 49
  29. 50
  30. 51
  31. 52
  32. 53
  33. 54
  34. 55
  35. 56
  36. 57
  37. 58
  38. 59
  39. 60
  40. 61
LSD.Widget.Input = new Class({ States: { 'focused': ['focus', 'blur'] }, Includes: [ LSD.Widget.Paint, LSD.Trait.Input ], options: { tag: 'input', attributes: { type: 'text' }, writable: true, focusable: false, events: { _input: { focus: function() { this.input.focus(); }, blur: function() { this.input.blur(); } } } }, retain: function() { this.focus(false); return false; }, applyValue: function(item) { this.input.set('value', item); } });