diff options
| author | Mark Otto <[email protected]> | 2011-12-21 18:39:02 -0600 |
|---|---|---|
| committer | Mark Otto <[email protected]> | 2011-12-21 18:39:02 -0600 |
| commit | 9fb380151d477f1741b7609ade7a9e7fd5450b2c (patch) | |
| tree | a749f2b6917c09770af1586ae9f83e46115de7eb /js/bootstrap-collapse.js | |
| parent | 12a0d69454a2831031035d19237d36d38bb2c2a9 (diff) | |
| parent | a5a98a8a984512011dac1216b432b86c6eff96a4 (diff) | |
| download | bootstrap-9fb380151d477f1741b7609ade7a9e7fd5450b2c.tar.xz bootstrap-9fb380151d477f1741b7609ade7a9e7fd5450b2c.zip | |
Merge branch '2.0-wip' of github.com:twitter/bootstrap into 2.0-wip
Conflicts:
bootstrap.css
docs/javascript.html
Diffstat (limited to 'js/bootstrap-collapse.js')
| -rw-r--r-- | js/bootstrap-collapse.js | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/js/bootstrap-collapse.js b/js/bootstrap-collapse.js index f56f6c705..313c0abca 100644 --- a/js/bootstrap-collapse.js +++ b/js/bootstrap-collapse.js @@ -23,13 +23,13 @@ var Collapse = function ( element, options ) { this.$element = $(element) - this.settings = $.extend({}, $.fn.collapse.defaults, options) + this.options = $.extend({}, $.fn.collapse.defaults, options) - if (this.settings["parent"]) { - this.$parent = $(this.settings["parent"]) + if (this.options["parent"]) { + this.$parent = $(this.options["parent"]) } - this.settings.toggle && this.toggle() + this.options.toggle && this.toggle() } Collapse.prototype = { @@ -116,20 +116,20 @@ toggle: true } - $.fn.collapse.Collapse = Collapse + $.fn.collapse.Constructor = Collapse /* COLLAPSIBLE DATA-API * ==================== */ $(function () { - $('body').delegate('[data-toggle=collapse]', 'click.collapse.data-api', function ( e ) { + $('body').on('click.collapse.data-api', '[data-toggle=collapse]', function ( e ) { var $this = $(this) , target = $this.attr('data-target') || $this.attr('href') , option = $(target).data('collapse') ? 'toggle' : $this.data() - e.preventDefault() + e.preventDefault() $(target).collapse(option) }) }) -})( window.jQuery || window.ender )
\ No newline at end of file +})( window.jQuery )
\ No newline at end of file |
