1 _kiwi
.view
.ResizeHandler
= Backbone
.View
.extend({
3 'mousedown': 'startDrag',
7 initialize: function () {
9 this.starting_width
= {};
11 $(window
).on('mousemove', $.proxy(this.onDrag
, this));
14 startDrag: function (event
) {
18 stopDrag: function (event
) {
19 this.dragging
= false;
22 onDrag: function (event
) {
23 if (!this.dragging
) return;
25 this.$el
.css('left', event
.clientX
- (this.$el
.outerWidth(true) / 2));
26 $('#kiwi .memberlists').css('width', this.$el
.parent().width() - (this.$el
.position().left
+ this.$el
.outerWidth()));
27 _kiwi
.app
.view
.doLayout();