js/helper.js
/**
 * Init the element with required drag cordinate info
 * @param element
 * @private
 */
Init the element with required drag cordinate info
@param element
@private
Init the element with required drag cordinate info @param element @private
function _initDrag(element, event) {
	element.mouseStartPos = {x: event.clientX, y: event.clientY};
	element.elementStartPos = {
		left: element.offsetLeft,
		top: element.offsetTop
	};
	element.limitPos = {
		left: element.parentNode.offsetWidth - element.offsetWidth,
		top: element.parentNode.offsetHeight - element.offsetHeight
	};
}
function _initDrag ( element , event ) { element . mouseStartPos = { x : event . clientX , y : event . clientY } ; element . elementStartPos = { left : element . offsetLeft , top : element . offsetTop } ; element . limitPos = { left : element . parentNode . offsetWidth - element . offsetWidth , top : element . parentNode . offsetHeight - element . offsetHeight } ; }
Init the element with required drag cordinate info
 @param element
 @private
Init the element with required drag cordinate info @param element @private