24. 拿来的ImageCropper有BUG。
/**
* @private
* @method _setConstraints
* @param Boolean inside Used when called from inside a resize event, false by default (dragging)
* @description Set the DragDrop constraints to keep the element inside the crop area.
* @return {Object} Object containing Top, Right, Bottom and Left constraints
*/
26. 单体模式。
Y.widget.actlayer = function(btn, type, config){
var self = this; self.btn = btn; self.type = type; self.config = config;
//全角半角转换函数
var _FullToDBC=function(Str) {......};
//构造post数据
var _postdata=function(type){......};
//配置类型
var _typelist={......};
//超时请求
var _failure=function(o){......};
//退出活动的回调
var _exitback={......}
//参加活动之后的回调
var _doback={......};
//第一次检测身份参加的回调
var _canjionback={......};
//检测是否有资格参加活动
var _canjion=function(){......};
//绑定事件
var _bind=function(){......};
//注销事件
var _purgeElement=function(){......};
//弹出效果
var _popup=function(){......};
//启动第一次弹窗
var _fire=function(){.......};
//确认线下活动的回调
var _joincallback=function(target,constitutor,status,errormsg){......};
//tips提示
var _popuptips=function(target,msg){......};
return {
//初始化
intbind: function(){......}
}
};