function mf(a,b,d,e){this.Init(a,b,d,e)}m("AdfMasonryLayoutBehavior",mf);r.v(mf,Aa);mf.prototype.Init=function(a,b,d,e){mf.h.Init.call(this);this.Pj=a;this.Tk=b;this.zg=d;this.XG=e};r.a("AdfMasonryLayoutBehavior.prototype.Init",{Init:mf.prototype.Init});mf.prototype.Qa=function(a){u.s(a,G);a instanceof AdfUICommand&&a.addEventListener(ab.ed,this.Wha,this)};r.a("AdfMasonryLayoutBehavior.prototype.initialize",{Qa:mf.prototype.Qa});
mf.lKa=function(a){for(a=a.getParent();a;){var b=a.o().i();if(b&&1==b.nodeType)return a;a=a.getParent()}return null};
mf.prototype.Wha=function(a){if(a.$H()){var b=a.getSource(),d=a=null;if(null==this.Pj)for(var e=null;null!=b;){if(b instanceof AdfRichMasonryLayout){a=b;d=e;break}e=b;b=mf.lKa(b)}else switch(this.Tk){case "delete":case "resize":d=b.m(this.Pj);null!=d&&(a=mf.lKa(d));break;default:a=b.m(this.Pj)}u.assert(null!=a,'The masonryLayout associated with the MasonryLayoutBehavior for\x3d"'+this.Pj+'" could not be found (masonryLayout component \x3d '+a+").");if(null!=a){e='The masonryLayout associated with the MasonryLayoutBehavior for\x3d"'+
this.Pj+'" is not a masonryLayout (masonryLayout component \x3d '+a+").";b=null;if("delete"==this.Tk||"resize"==this.Tk)u.assert(null!=d,'The tile associated with the MasonryLayoutBehavior for\x3d"'+this.Pj+'" could not be found (tile component \x3d '+d+")."),b=d.g(),u.J(b);switch(this.Tk){case "delete":u.assert(null!=a.fC,e);a.fC(b);break;case "resize":u.J(this.XG);u.assert(null!=a.nv,e);a.nv(b,this.XG);break;default:d=parseInt(this.zg),isNaN(d)&&(d=-1),u.J(this.XG),u.assert(null!=a.Dy,e),a.Dy(this.XG,
d)}}}};