Commit 5070e5b2 by Chris Dodge

Merge branch 'feature/alex/poll-merged' of github.com:MITx/mitx into feature/alex/poll-merged

parents d2f21661 c54ad38f
...@@ -354,7 +354,11 @@ return { ...@@ -354,7 +354,11 @@ return {
'width': this.iconWidthSmall, 'width': this.iconWidthSmall,
'height': this.iconHeightSmall, 'height': this.iconHeightSmall,
'left': 50 - this.iconWidthSmall * 0.5, 'left': 50 - this.iconWidthSmall * 0.5,
'top': ((this.labelEl !== null) ? 5 : 50 - this.iconHeightSmall * 0.5)
// Before:
// 'top': ((this.labelEl !== null) ? (100 - this.iconHeightSmall - 25) * 0.5 : 50 - this.iconHeightSmall * 0.5)
// After:
'top': ((this.labelEl !== null) ? 37.5 : 50.0) - 0.5 * this.iconHeightSmall
}); });
this.iconEl.appendTo(this.containerEl); this.iconEl.appendTo(this.containerEl);
...@@ -367,7 +371,11 @@ return { ...@@ -367,7 +371,11 @@ return {
'padding-right': 0, 'padding-right': 0,
'z-index': this.zIndex, 'z-index': this.zIndex,
'left': 50 - this.labelWidth * 0.5, 'left': 50 - this.labelWidth * 0.5,
'top': 5 + this.iconHeightSmall + 5
// Before:
// 'top': (100 - this.iconHeightSmall - 25) * 0.5 + this.iconHeightSmall + 5
// After:
'top': 42.5 + 0.5 * this.iconHeightSmall
}); });
this.labelEl.appendTo(this.containerEl); this.labelEl.appendTo(this.containerEl);
} }
......
...@@ -214,7 +214,11 @@ define(['logme', 'draggable_events', 'draggable_logic'], function (logme, dragga ...@@ -214,7 +214,11 @@ define(['logme', 'draggable_events', 'draggable_logic'], function (logme, dragga
'width': draggableObj.iconWidthSmall, 'width': draggableObj.iconWidthSmall,
'height': draggableObj.iconHeightSmall, 'height': draggableObj.iconHeightSmall,
'left': 50 - draggableObj.iconWidthSmall * 0.5, 'left': 50 - draggableObj.iconWidthSmall * 0.5,
'top': ((obj.label.length > 0) ? 5 : 50 - draggableObj.iconHeightSmall * 0.5)
// Before:
// 'top': ((obj.label.length > 0) ? (100 - draggableObj.iconHeightSmall - 25) * 0.5 : 50 - draggableObj.iconHeightSmall * 0.5)
// After:
'top': ((obj.label.length > 0) ? 37.5 : 50.0) - 0.5 * draggableObj.iconHeightSmall
}); });
draggableObj.iconImgEl.css({ draggableObj.iconImgEl.css({
'position': 'absolute', 'position': 'absolute',
...@@ -243,7 +247,11 @@ define(['logme', 'draggable_events', 'draggable_logic'], function (logme, dragga ...@@ -243,7 +247,11 @@ define(['logme', 'draggable_events', 'draggable_logic'], function (logme, dragga
draggableObj.labelWidth = draggableObj.labelEl.width(); draggableObj.labelWidth = draggableObj.labelEl.width();
draggableObj.labelEl.css({ draggableObj.labelEl.css({
'left': 50 - draggableObj.labelWidth * 0.5, 'left': 50 - draggableObj.labelWidth * 0.5,
'top': 5 + draggableObj.iconHeightSmall + 5
// Before:
// 'top': (100 - this.iconHeightSmall - 25) * 0.5 + this.iconHeightSmall + 5
// After:
'top': 42.5 + 0.5 * draggableObj.iconHeightSmall
}); });
draggableObj.attachMouseEventsTo('labelEl'); draggableObj.attachMouseEventsTo('labelEl');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment