Refactoring
This commit is contained in:
parent
5f4345679d
commit
68ad058a65
|
@ -378,6 +378,7 @@ define([
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
resetPageX(e);
|
resetPageX(e);
|
||||||
|
me.mouseFree = true;
|
||||||
|
|
||||||
var index = e.data.index,
|
var index = e.data.index,
|
||||||
lastValue = me.thumbs[index].value,
|
lastValue = me.thumbs[index].value,
|
||||||
|
@ -405,7 +406,6 @@ define([
|
||||||
|
|
||||||
$(document).off('mouseup', me.binding.onMouseUp);
|
$(document).off('mouseup', me.binding.onMouseUp);
|
||||||
$(document).off('mousemove', me.binding.onMouseMove);
|
$(document).off('mousemove', me.binding.onMouseMove);
|
||||||
me.mouseFree = true;
|
|
||||||
me._dragstart = undefined;
|
me._dragstart = undefined;
|
||||||
!me.isRemoveThumb && me.trigger('changecomplete', me, value, lastValue);
|
!me.isRemoveThumb && me.trigger('changecomplete', me, value, lastValue);
|
||||||
me.isRemoveThumb = undefined;
|
me.isRemoveThumb = undefined;
|
||||||
|
|
|
@ -994,7 +994,7 @@ define([
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
me.mnuDirectionPicker.dataViewItems.forEach(function (item){
|
me.mnuDirectionPicker.dataViewItems.forEach(function (item){
|
||||||
var type = item.options.model.attributes.type+90;
|
var type = item.model.get('type')+90;
|
||||||
item.$el.children(0).css({'background': 'linear-gradient('+ type + 'deg, '+ me.gradientColorsStr + ')'});
|
item.$el.children(0).css({'background': 'linear-gradient('+ type + 'deg, '+ me.gradientColorsStr + ')'});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -539,7 +539,7 @@ define([
|
||||||
this.mnuDirectionPicker.dataViewItems[0].$el.children(0).css({'background': 'radial-gradient(' + gradientColorsStr + ')'});
|
this.mnuDirectionPicker.dataViewItems[0].$el.children(0).css({'background': 'radial-gradient(' + gradientColorsStr + ')'});
|
||||||
else
|
else
|
||||||
this.mnuDirectionPicker.dataViewItems.forEach(function (item) {
|
this.mnuDirectionPicker.dataViewItems.forEach(function (item) {
|
||||||
var type = item.options.model.attributes.type + 90;
|
var type = item.model.get('type') + 90;
|
||||||
item.$el.children(0).css({'background': 'linear-gradient(' + type + 'deg, ' + gradientColorsStr + ')'});
|
item.$el.children(0).css({'background': 'linear-gradient(' + type + 'deg, ' + gradientColorsStr + ')'});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -615,7 +615,7 @@ define([
|
||||||
this.mnuDirectionPicker.dataViewItems[0].$el.children(0).css({'background': 'radial-gradient(' + gradientColorsStr + ')'});
|
this.mnuDirectionPicker.dataViewItems[0].$el.children(0).css({'background': 'radial-gradient(' + gradientColorsStr + ')'});
|
||||||
else
|
else
|
||||||
this.mnuDirectionPicker.dataViewItems.forEach(function (item) {
|
this.mnuDirectionPicker.dataViewItems.forEach(function (item) {
|
||||||
var type = item.options.model.attributes.type + 90;
|
var type = item.model.get('type') + 90;
|
||||||
item.$el.children(0).css({'background': 'linear-gradient(' + type + 'deg, ' + gradientColorsStr + ')'});
|
item.$el.children(0).css({'background': 'linear-gradient(' + type + 'deg, ' + gradientColorsStr + ')'});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -950,7 +950,7 @@ define([
|
||||||
me.mnuDirectionPicker.dataViewItems[0].$el.children(0).css({'background': 'radial-gradient(' + me.gradientColorsStr + ')'});
|
me.mnuDirectionPicker.dataViewItems[0].$el.children(0).css({'background': 'radial-gradient(' + me.gradientColorsStr + ')'});
|
||||||
else
|
else
|
||||||
me.mnuDirectionPicker.dataViewItems.forEach(function (item){
|
me.mnuDirectionPicker.dataViewItems.forEach(function (item){
|
||||||
var type = item.options.model.attributes.type+90;
|
var type = item.model.get('type')+90;
|
||||||
item.$el.children(0).css({'background': 'linear-gradient('+ type + 'deg, '+ me.gradientColorsStr + ')'});
|
item.$el.children(0).css({'background': 'linear-gradient('+ type + 'deg, '+ me.gradientColorsStr + ')'});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
|
@ -929,7 +929,7 @@ define([
|
||||||
me.mnuDirectionPicker.dataViewItems[0].$el.children(0).css({'background': 'radial-gradient(' + me.gradientColorsStr + ')'});
|
me.mnuDirectionPicker.dataViewItems[0].$el.children(0).css({'background': 'radial-gradient(' + me.gradientColorsStr + ')'});
|
||||||
else
|
else
|
||||||
me.mnuDirectionPicker.dataViewItems.forEach(function (item){
|
me.mnuDirectionPicker.dataViewItems.forEach(function (item){
|
||||||
var type = item.options.model.attributes.type+90;
|
var type = item.model.get('type')+90;
|
||||||
item.$el.children(0).css({'background': 'linear-gradient('+ type + 'deg, '+ me.gradientColorsStr + ')'});
|
item.$el.children(0).css({'background': 'linear-gradient('+ type + 'deg, '+ me.gradientColorsStr + ')'});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue