Sha256: d09a53dc65254d3a0d2d99b92e6e1a1941b54b5fc467b1aa5f54f4a0c2000117
Contents?: true
Size: 903 Bytes
Versions: 13
Compression:
Stored size: 903 Bytes
Contents
define([ 'jquery', './utils' ], function ($, Utils) { function Dropdown ($element, options) { this.$element = $element; this.options = options; Dropdown.__super__.constructor.call(this); } Utils.Extend(Dropdown, Utils.Observable); Dropdown.prototype.render = function () { var $dropdown = $( '<span class="select2-dropdown">' + '<span class="select2-results"></span>' + '</span>' ); $dropdown.attr('dir', this.options.get('dir')); this.$dropdown = $dropdown; return $dropdown; }; Dropdown.prototype.bind = function () { // Should be implemented in subclasses }; Dropdown.prototype.position = function ($dropdown, $container) { // Should be implemented in subclasses }; Dropdown.prototype.destroy = function () { // Remove the dropdown from the DOM this.$dropdown.remove(); }; return Dropdown; });
Version data entries
13 entries across 13 versions & 1 rubygems