MySpace.Timer=function(){MySpace.Timer.initializeBase(this);this._interval=1000;this._enabled=false;this._timer=null};MySpace.Timer.prototype={get_interval:function(){return this._interval},set_interval:function(A){if(this._interval!==A){this._interval=A;this.raisePropertyChanged("interval");if(!this.get_isUpdating()&&this._timer!==null){this.restartTimer()}}},get_enabled:function(){return this._enabled},set_enabled:function(A){if(A!==this.get_enabled()){this._enabled=A;this.raisePropertyChanged("enabled");if(!this.get_isUpdating()){if(A){this._startTimer()}else{this._stopTimer()}}}},add_tick:function(A){this.get_events().addHandler("tick",A)},remove_tick:function(A){this.get_events().removeHandler("tick",A)},dispose:function(){this.set_enabled(false);this._stopTimer();MySpace.Timer.callBaseMethod(this,"dispose")},updated:function(){MySpace.Timer.callBaseMethod(this,"updated");if(this._enabled){this.restartTimer()}},_timerCallback:function(){var A=this.get_events().getHandler("tick");if(A){A(this,Sys.EventArgs.Empty)}},restartTimer:function(){this._stopTimer();this._startTimer()},_startTimer:function(){this._timer=window.setInterval(Function.createDelegate(this,this._timerCallback),this._interval)},_stopTimer:function(){window.clearInterval(this._timer);this._timer=null}};MySpace.Timer.registerClass("MySpace.Timer",Sys.Component);Type.registerNamespace("MySpace.UI.Effects");MySpace.UI.Effects.Glitz=function(){throw Error.invalidOperation()};MySpace.UI.Effects.Glitz.interpolate=function(C,B,A,D){if(D){A=100*D(A/100)}return C+(B-C)*(A/100)};MySpace.UI.Effects.Glitz.setElementOpacity=function(B,A){if(B.filters){if(A==1){B.style.cssText=B.style.cssText.replace(/FILTER:[^;]*;?/i,"")}else{B.style.filter="progid:DXImageTransform.Microsoft.Alpha(opacity="+A*100+")"}}else{B.style.opacity=A}};MySpace.UI.Effects.Easing={linear:function(A){return A},quadIn:function(A){return A*A},quadOut:function(A){return A*(A-2)*-1},quadInOut:function(A){A=A*2;if(A<1){return Math.pow(A,2)/2}return -1*((--A)*(A-2)-1)/2},quartIn:function(A){return Math.pow(A,4)},quartOut:function(A){return -1*(Math.pow(A-1,4)-1)},quartInOut:function(A){A=A*2;if(A<1){return Math.pow(A,4)/2}A-=2;return -1/2*(Math.pow(A,4)-2)},circIn:function(A){return -1*(Math.sqrt(1-Math.pow(A,2))-1)},circOut:function(A){A=A-1;return Math.sqrt(1-Math.pow(A,2))},circInOut:function(A){A=A*2;if(A<1){return -1/2*(Math.sqrt(1-Math.pow(A,2))-1)}A-=2;return 1/2*(Math.sqrt(1-Math.pow(A,2))+1)},backIn:function(B){var A=1.70158;return Math.pow(B,2)*((A+1)*B-A)},backOut:function(B){B=B-1;var A=1.70158;return Math.pow(B,2)*((A+1)*B+A)+1},backInOut:function(B){var A=1.70158*1.525;B=B*2;if(B<1){return(Math.pow(B,2)*((A+1)*B-A))/2}B-=2;return(Math.pow(B,2)*((A+1)*B+A)+2)/2},elasticIn:function(C){if(C==0){return 0}if(C==1){return 1}var B=0.3;var A=B/4;C=C-1;return -1*Math.pow(2,10*C)*Math.sin((C-A)*(2*Math.PI)/B)},elasticOut:function(C){if(C==0){return 0}if(C==1){return 1}var B=0.3;var A=B/4;return Math.pow(2,-10*C)*Math.sin((C-A)*(2*Math.PI)/B)+1},elasticInOut:function(C){if(C==0){return 0}C=C*2;if(C==2){return 1}var B=0.3*1.5;var A=B/4;if(C<1){C-=1;return -0.5*(Math.pow(2,10*C)*Math.sin((C-A)*(2*Math.PI)/B))}C-=1;return 0.5*(Math.pow(2,-10*C)*Math.sin((C-A)*(2*Math.PI)/B))+1},bounceIn:function(A){return(1-MySpace.UI.Effects.Easing.bounceOut(1-A))},bounceOut:function(D){var B=7.5625;var C=2.75;var A;if(D<(1/C)){A=B*Math.pow(D,2)}else{if(D<(2/C)){D-=(1.5/C);A=B*Math.pow(D,2)+0.75}else{if(D<(2.5/C)){D-=(2.25/C);A=B*Math.pow(D,2)+0.9375}else{D-=(2.625/C);A=B*Math.pow(D,2)+0.984375}}}return A},bounceInOut:function(A){if(A<0.5){return MySpace.UI.Effects.Easing.bounceIn(A*2)/2}return(MySpace.UI.Effects.Easing.bounceOut(A*2-1)/2)+0.5}};MySpace.UI.Effects.Animation=function(){MySpace.UI.Effects.Animation.initializeBase(this)};MySpace.UI.Effects.Animation.prototype={_duration:1,_fps:25,_target:null,_tickHandler:null,_timer:null,_percentComplete:0,_percentDelta:null,_parentAnimation:null,get_duration:function(){return this._duration},set_duration:function(A){this._duration=A},get_fps:function(){return this._fps},set_fps:function(A){this._fps=A},get_isActive:function(){return this._timer!==null},get_isPlaying:function(){return this._timer!==null&&this._timer.get_enabled()},get_percentComplete:function(){return this._percentComplete},get_target:function(){return this._target},set_target:function(A){this._target=A},add_ended:function(A){this.get_events().addHandler("ended",A)},remove_ended:function(A){this.get_events().removeHandler("ended",A)},add_started:function(A){this.get_events().addHandler("started",A)},remove_started:function(A){this.get_events().removeHandler("started",A)},dispose:function(){if(this._timer){this._timer.dispose();this._timer=null}this._tickHandler=null;this._target=null;MySpace.UI.Effects.Animation.callBaseMethod(this,"dispose")},getAnimatedValue:function(){throw Error.notImplemented()},onEnd:function(){},onStart:function(){},onStep:function(A){this.setValue(this.getAnimatedValue(A))},pause:function(){if(!this._parentAnimation){if(this._timer){this._timer.set_enabled(false);this.raisePropertyChanged("isPlaying")}}},play:function(){if(!this._parentAnimation){var A=true;if(!this._timer){A=false;if(!this._tickHandler){this._tickHandler=Function.createDelegate(this,this._onTimerTick)}this._timer=new MySpace.Timer;this._timer.set_interval(1000/this._fps);this._timer.add_tick(this._tickHandler);this._percentDelta=100/(this._duration*this._fps);this.onStart();this._updatePercentComplete(0,true)}this._timer.set_enabled(true);this.raisePropertyChanged("isPlaying");if(!A){this.raisePropertyChanged("isActive")}}},setOwner:function(A){this._parentAnimation=A},setValue:function(){throw Error.notImplemented()},stop:function(){if(!this._parentAnimation){var A=this._timer;this._timer=null;if(A){A.dispose();this._updatePercentComplete(100);this.onEnd();var B=this.get_events().getHandler("ended");if(B){B(this,null)}this.raisePropertyChanged("isPlaying");this.raisePropertyChanged("isActive")}}},_onTimerTick:function(){this._updatePercentComplete(this._percentComplete+this._percentDelta,true)},_updatePercentComplete:function(B,A){if(B>100){B=100}this._percentComplete=B;this.raisePropertyChanged("percentComplete");if(A){this.onStep(B)}if(B===100){this.stop()}}};MySpace.UI.Effects.Animation.registerClass("MySpace.UI.Effects.Animation",Sys.Component);MySpace.UI.Effects.PropertyAnimation=function(){MySpace.UI.Effects.PropertyAnimation.initializeBase(this)};MySpace.UI.Effects.PropertyAnimation.prototype={_property:null,_propertyKey:null,get_property:function(){return this._property},set_property:function(A){this._property=A},get_propertyKey:function(){return this._propertyKey},set_propertyKey:function(A){this._propertyKey=A},add_ended:function(A){this.get_events().addHandler("ended",A)},remove_ended:function(A){this.get_events().removeHandler("ended",A)},add_started:function(A){this.get_events().addHandler("started",A)},remove_started:function(A){this.get_events().removeHandler("started",A)},setValue:function(A){if(this._propertyKey){this.get_target()[this._property][this._propertyKey]=A}else{this.get_target()[this._property]=A}}};MySpace.UI.Effects.PropertyAnimation.registerClass("MySpace.UI.Effects.PropertyAnimation",MySpace.UI.Effects.Animation);MySpace.UI.Effects.InterpolatedAnimation=function(){MySpace.UI.Effects.InterpolatedAnimation.initializeBase(this)};MySpace.UI.Effects.InterpolatedAnimation.prototype={_startValue:null,_endValue:null,_easingFunction:null,get_endValue:function(){return this._endValue},set_endValue:function(A){this._endValue=A},get_startValue:function(){return this._startValue},set_startValue:function(A){this._startValue=A},get_easingFunction:function(){return this._easingFunction},set_easingFunction:function(A){this._easingFunction=A}};MySpace.UI.Effects.InterpolatedAnimation.registerClass("MySpace.UI.Effects.InterpolatedAnimation",MySpace.UI.Effects.PropertyAnimation);MySpace.UI.Effects.DiscreteAnimation=function(){MySpace.UI.Effects.DiscreteAnimation.initializeBase(this);this._values=[]};MySpace.UI.Effects.DiscreteAnimation.prototype={get_values:function(){return this._values},set_values:function(A){this._values=A},getAnimatedValue:function(B){var A=Math.round(B/100*(this._values.length-1));return this._values[A]}};MySpace.UI.Effects.DiscreteAnimation.registerClass("MySpace.UI.Effects.DiscreteAnimation",MySpace.UI.Effects.PropertyAnimation);MySpace.UI.Effects.NumberAnimation=function(){MySpace.UI.Effects.NumberAnimation.initializeBase(this)};MySpace.UI.Effects.NumberAnimation.prototype={_integralValues:false,get_integralValues:function(){return this._integralValues},set_integralValues:function(A){this._integralValues=A},getAnimatedValue:function(B){var A=MySpace.UI.Effects.Glitz.interpolate(this.get_startValue(),this.get_endValue(),B,this.get_easingFunction());if(this._integralValues){A=Math.round(A)}return A}};MySpace.UI.Effects.NumberAnimation.registerClass("MySpace.UI.Effects.NumberAnimation",MySpace.UI.Effects.InterpolatedAnimation);MySpace.UI.Effects.LengthAnimation=function(){MySpace.UI.Effects.LengthAnimation.initializeBase(this)};MySpace.UI.Effects.LengthAnimation.prototype={_unit:"px",get_unit:function(){return this._unit},set_unit:function(A){this._unit=A},getAnimatedValue:function(B){var A=MySpace.UI.Effects.Glitz.interpolate(this.get_startValue(),this.get_endValue(),B,this.get_easingFunction());return Math.round(A)+this._unit}};MySpace.UI.Effects.LengthAnimation.registerClass("MySpace.UI.Effects.LengthAnimation",MySpace.UI.Effects.InterpolatedAnimation);MySpace.UI.Effects.CompositeAnimation=function(){MySpace.UI.Effects.CompositeAnimation.initializeBase(this);this._animations=[]};MySpace.UI.Effects.CompositeAnimation.prototype={get_animations:function(){return this._animations},add_animation:function(A){this._animations.push(A)},getAnimatedValue:function(){throw Error.invalidOperation()},dispose:function(){for(var A=0;A<this._animations.length;A++){this._animations[A].dispose()}this._animations=null;MySpace.UI.Effects.CompositeAnimation.callBaseMethod(this,"dispose")},onEnd:function(){for(var A=0;A<this._animations.length;A++){this._animations[A].onEnd()}},onStart:function(){for(var A=0;A<this._animations.length;A++){this._animations[A].onStart()}},onStep:function(A){for(var B=0;B<this._animations.length;B++){this._animations[B].onStep(A)}}};MySpace.UI.Effects.CompositeAnimation.registerClass("MySpace.UI.Effects.CompositeAnimation",MySpace.UI.Effects.Animation);MySpace.UI.Effects.ColorAnimation=function(G,F,E,D,C,B,A){MySpace.UI.Effects.ColorAnimation.initializeBase(this,[G,F,E,D,C,B,A]);this._start=null;this._end=null;this._interpolateRed=false;this._interpolateGreen=false;this._interpolateBlue=false};MySpace.UI.Effects.ColorAnimation.prototype={onStart:function(){MySpace.UI.Effects.ColorAnimation.callBaseMethod(this,"onStart");this._start=MySpace.UI.Effects.ColorAnimation.getRGB(this.get_startValue());this._end=MySpace.UI.Effects.ColorAnimation.getRGB(this.get_endValue());this._interpolateRed=(this._start.Red!=this._end.Red);this._interpolateGreen=(this._start.Green!=this._end.Green);this._interpolateBlue=(this._start.Blue!=this._end.Blue)},getAnimatedValue:function(B){var D=this._start.Red;var C=this._start.Green;var A=this._start.Blue;if(this._interpolateRed){D=Math.round(MySpace.UI.Effects.Glitz.interpolate(D,this._end.Red,B,this.get_easingFunction()))}if(this._interpolateGreen){C=Math.round(MySpace.UI.Effects.Glitz.interpolate(C,this._end.Green,B,this.get_easingFunction()))}if(this._interpolateBlue){A=Math.round(MySpace.UI.Effects.Glitz.interpolate(A,this._end.Blue,B,this.get_easingFunction()))}return MySpace.UI.Effects.ColorAnimation.toColor(D,C,A)},set_startValue:function(A){if(this._startValue!=A){this._startValue=A;this.raisePropertyChanged("startValue")}},set_endValue:function(A){if(this._endValue!=A){this._endValue=A;this.raisePropertyChanged("endValue")}}};MySpace.UI.Effects.ColorAnimation.getRGB=function(A){if(!A||A.length!=7){throw String.format(AjaxControlToolkit.Resources.Animation_InvalidColor,A)}return{Red:parseInt(A.substr(1,2),16),Green:parseInt(A.substr(3,2),16),Blue:parseInt(A.substr(5,2),16)}};MySpace.UI.Effects.ColorAnimation.toColor=function(F,E,B){var D=F.toString(16);var C=E.toString(16);var A=B.toString(16);if(D.length==1){D="0"+D}if(C.length==1){C="0"+C}if(A.length==1){A="0"+A}return"#"+D+C+A};MySpace.UI.Effects.ColorAnimation.registerClass("MySpace.UI.Effects.ColorAnimation",MySpace.UI.Effects.InterpolatedAnimation);MySpace.UI.Effects.FadeEffect=function(){throw Error.invalidOperation()};MySpace.UI.Effects.FadeEffect.prototype={FadeIn:0,FadeOut:1};MySpace.UI.Effects.FadeEffect.registerEnum("MySpace.UI.Effects.FadeEffect");MySpace.UI.Effects.FadeAnimation=function(){MySpace.UI.Effects.FadeAnimation.initializeBase(this)};MySpace.UI.Effects.FadeAnimation.prototype={_effect:MySpace.UI.Effects.FadeEffect.FadeIn,get_effect:function(){return this._effect},set_effect:function(A){this._effect=A},getAnimatedValue:function(C){var B=0,A=1;if(this._effect===MySpace.UI.Effects.FadeEffect.FadeOut){B=1;A=0}return MySpace.UI.Effects.Glitz.interpolate(B,A,C)},onStart:function(){var A=0;if(this._effect===MySpace.UI.Effects.FadeEffect.FadeOut){A=1}this.setValue(A);if(A==0){this.get_target().style.visibility="visible"}},onEnd:function(){var A=1;if(this._effect===MySpace.UI.Effects.FadeEffect.FadeOut){A=0}this.setValue(A);if(A==0){this.get_target().style.visibility="hidden"}},setValue:function(A){MySpace.UI.Effects.Glitz.setElementOpacity(this.get_target(),A)}};MySpace.UI.Effects.FadeAnimation.registerClass("MySpace.UI.Effects.FadeAnimation",MySpace.UI.Effects.Animation);MySpace.UI.Effects.SlideEffect=function(){throw Error.invalidOperation()};MySpace.UI.Effects.SlideEffect.prototype={SlideIn:0,SlideOut:1};MySpace.UI.Effects.SlideEffect.registerEnum("MySpace.UI.Effects.SlideEffect");MySpace.UI.Effects.SlidingAnimation=function(){MySpace.UI.Effects.SlidingAnimation.initializeBase(this)};MySpace.UI.Effects.SlidingAnimation.prototype={_effect:MySpace.UI.Effects.SlideEffect.SlideIn,get_effect:function(){return this._effect},set_effect:function(A){this._effect=A},initialize:function(){this.get_target().style.overflow="hidden";var A=this.get_target().style.display;this.get_target().style.display="block";this.set_property("style");this.set_propertyKey("height");if(this._effect===MySpace.UI.Effects.SlideEffect.SlideIn){this.set_startValue(MySpace.UI.getContentBox(this.get_target()).h);this.set_endValue(0)}else{this.set_startValue(0);this.set_endValue(MySpace.UI.getContentBox(this.get_target()).h)}this.get_target().style.display=A},onStart:function(){if(this._effect===MySpace.UI.Effects.SlideEffect.SlideOut){this.get_target().style.display="block"}},onEnd:function(){if(this._effect===MySpace.UI.Effects.SlideEffect.SlideIn){this.get_target().style.display="none"}}};MySpace.UI.Effects.SlidingAnimation.registerClass("MySpace.UI.Effects.SlidingAnimation",MySpace.UI.Effects.LengthAnimation);Type.registerNamespace("MySpace.PhotoAlbums.Pages");MySpace.PhotoAlbums.Pages.photoalbumscommon=function(A){MySpace.PhotoAlbums.Pages.photoalbumscommon.initializeBase(this,[A])};MySpace.PhotoAlbums.Pages.photoalbumscommon.prototype={initialize:function(){},dispose:function(){}};MySpace.PhotoAlbums.Pages.photoalbumscommon.ValidateAlbumTitle=function(B){var A=document.getElementById(B).value.replace(/^\s+|\s+$/g,"");if(A.length>0){return true}else{return false}};MySpace.PhotoAlbums.Pages.photoalbumscommon.PreloadImage=function(A){var B=new Image();if(A!=null){B.src=A.src;return B}else{return A}};MySpace.PhotoAlbums.Pages.photoalbumscommon.FixNonCustomCover=function(B,D){var E={w:170,h:127};if(!B.complete){B=MySpace.PhotoAlbums.Pages.photoalbumscommon.PreloadImage(B)}B.style.cssFloat="left";if(B.width<E.w||B.width>E.w){B.width=E.w;B.style.width=E.w}var A=B.height/2;var C=E.h/2;var F=C-A;if(D!==undefined){D.style.marginTop=Math.round(F)+"px"}};MySpace.Application.add_DOMloaded(function(){Array.forEach($q("ul.albums img"),function(A){if(A.complete){MySpace.PhotoAlbums.Pages.photoalbumscommon.FixNonCustomCover(A,A)}else{$addHandler(A,"load",Function.createPartial(null,MySpace.PhotoAlbums.Pages.photoalbumscommon.FixNonCustomCover,A,A))}})});MySpace.PhotoAlbums.Pages.photoalbumscommon.FadeMessage=function(B){var A=$get(B);if(A!==null){A.style.width="100%";MySpace.PhotoAlbums.Pages.photoalbumscommon.FadeIn(B);setTimeout("MySpace.PhotoAlbums.Pages.photoalbumscommon.FadeOut('"+B+"')",4000)}};MySpace.PhotoAlbums.Pages.photoalbumscommon.FadeOut=function(A){var B=$create(MySpace.UI.Effects.FadeAnimation,{target:$get(A),effect:MySpace.UI.Effects.FadeEffect.FadeOut,duration:1});B.play()};MySpace.PhotoAlbums.Pages.photoalbumscommon.FadeIn=function(B){var A=$create(MySpace.UI.Effects.FadeAnimation,{target:$get(B),effect:MySpace.UI.Effects.FadeEffect.FadeIn,duration:1});A.play()};MySpace.PhotoAlbums.Pages.photoalbumscommon.MaxImage=function(B){if(B.height>90){var D=B.width*(90/B.height);B.style.height=90+"px";B.style.width=D+"px"}if(B.width>80){var D=B.height*(80/B.width);B.style.width=80+"px";B.style.height=D+"px"}var E="topEmptyBox"+B.title;var C="bottomEmptyBox"+B.title;var F=100-B.height;var A=F/2;B.vspace=A};MySpace.PhotoAlbums.Pages.photoalbumscommon.ResetDropDownList=function(){if(typeof(ddlAlbumsClientID)!=="undefined"&&ddlAlbumsClientID!==null){var A=$get(ddlAlbumsClientID);if(A!==null){A.selectedIndex=0}}MySpace.PhotoAlbums.Pages.photoalbumscommon.ClearNewAlbum();return true};MySpace.PhotoAlbums.Pages.photoalbumscommon.ClearNewAlbum=function(){if(typeof(newAlbumNameClientID)!=="undefined"&&newAlbumNameClientID!==null){$get(newAlbumNameClientID).value=""}if(typeof(txtLocationClientID)!=="undefined"&&txtLocationClientID!==null){$get(txtLocationClientID).value=""}if(typeof(rblAlbumPrivacyClientID)!=="undefined"&&rblAlbumPrivacyClientID!==null){var C=$get(rblAlbumPrivacyClientID);var A=C.getElementsByTagName("input");A[2].checked=true}var B=$get(btnMovePhotosClientID);if(B){B.value=MySpaceRes.ViewMorePicsPage.Move}};MySpace.PhotoAlbums.Pages.photoalbumscommon.ChangeMoveCopyCreateText=function(){if(typeof(newAlbumNameClientID)!=="undefined"&&newAlbumNameClientID!==null){var A=$get(newAlbumNameClientID);var C=$get(btnMovePhotosClientID);if(A.value.length==0){if(C){C.value=MySpaceRes.ViewMorePicsPage.Move}}else{if(C){C.value=MySpaceRes.ViewMorePicsPage.Create}if(typeof(ddlAlbumsClientID)!=="undefined"&&ddlAlbumsClientID!==null){var B=$get(ddlAlbumsClientID);if(B!==null){B.selectedIndex=0}}}}else{Sys.Debug.trace("newAlbumNameClientID is either undefined or null")}};MySpace.PhotoAlbums.Pages.photoalbumscommon.NewAlbumCheck=function(){var B;var A;B=$get(ddlAlbumsClientID);if(B!==null){A=$get(newAlbumNameClientID).value.trim();if(B.selectedIndex===0&&A.length===0){window.alert(MySpaceRes.ViewMorePicsPage.SelectAlbumToMove);return false}else{return true}}return false};Type.registerNamespace("MySpace.Web.Modules.PhotoAlbums.Services");MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums=function(){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.initializeBase(this);this._timeout=0;this._userContext=null;this._succeeded=null;this._failed=null};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.prototype={CreateAlbum:function(E,F,B,A,D,C,G){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"CreateAlbum",false,{hash:E,title:F,privacy:B,location:A},D,C,G)},DeleteAlbum:function(D,A,C,B,E){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"DeleteAlbum",false,{hash:D,albumId:A},C,B,E)},SaveCaption:function(C,A,D,B,E){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"SaveCaption",false,{imageId:C,caption:A},D,B,E)},GetSharedAlbumLink:function(A,B,D,C,E){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"GetSharedAlbumLink",false,{friendID:A,albumId:B},D,C,E)},GetNextPhoto:function(E,A,D,G,C,F,B,H){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"GetNextPhoto",false,{imageUserId:E,albumId:A,imageId:D,displayFriendId:G,authKey:C},F,B,H)},GetPhotosSequence:function(B,A,E,D,G,F,C,H){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"GetPhotosSequence",false,{friendId:B,albumId:A,imageId:E,authKey:D,direction:G},F,C,H)},GetPhotoComments:function(E,C,A,D,B,F){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"GetPhotoComments",false,{displayFriendId:E,imageId:C,pageNumber:A},D,B,F)},DeleteImageComment:function(E,B,C,D,A,F){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"DeleteImageComment",false,{displayFriendId:E,imageId:B,imageCommentId:C},D,A,F)},DeleteImageCommentsMultiple:function(E,B,C,D,A,F){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"DeleteImageCommentsMultiple",false,{displayFriendId:E,imageId:B,deleteList:C},D,A,F)},UpdateAlbumPrivacy:function(A,D,C,E,B,F){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"UpdateAlbumPrivacy",false,{albumId:A,albumPrivacy:D,token:C},E,B,F)},ClearLastUpdatedAlbum:function(B,A,C){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"ClearLastUpdatedAlbum",false,{},B,A,C)},MoveMultiplePhotos:function(E,B,A,F,D,C,G){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"MoveMultiplePhotos",false,{hash:E,albumId:B,photosToMoveString:A,newAlbumId:F},D,C,G)},MoveMultiplePhotosNewAlbum:function(C,E,F,B,H,A,I,G,D){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"MoveMultiplePhotosNewAlbum",false,{hash:C,currentAlbumId:E,photosToMoveString:F,NewAlbumName:B,location:H,privacy:A},I,G,D)},DeleteMultiplePhotos:function(E,A,C,D,B,F){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"DeleteMultiplePhotos",false,{hash:E,albumId:A,photosToDeleteString:C},D,B,F)},SetDefaultPhoto:function(D,B,C,A,E){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"SetDefaultPhoto",false,{hash:D,imageId:B},C,A,E)},ArrangeAlbums:function(D,B,C,A,E){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"ArrangeAlbums",false,{hash:D,clientAlbumIds:B},C,A,E)},ArrangePhotos:function(F,A,D,B,E,C,G){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"ArrangePhotos",false,{hash:F,clientImageIds:A,arrangedImageIds:D,albumId:B},E,C,G)},UpdateAlbum:function(F,B,G,A,D,E,C,H){return this._invoke(MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path(),"UpdateAlbum",false,{hash:F,albumId:B,albumTitle:G,location:A,albumPrivacy:D},E,C,H)}};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.registerClass("MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums",Sys.Net.WebServiceProxy);MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance=new MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums();MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.set_path=function(A){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance._path=A};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_path=function(){return MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance._path};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.set_timeout=function(A){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance._timeout=A};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_timeout=function(){return MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance._timeout};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.set_defaultUserContext=function(A){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance._userContext=A};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_defaultUserContext=function(){return MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance._userContext};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.set_defaultSucceededCallback=function(A){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance._succeeded=A};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_defaultSucceededCallback=function(){return MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance._succeeded};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.set_defaultFailedCallback=function(A){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance._failed=A};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.get_defaultFailedCallback=function(){return MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance._failed};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.set_path("/Modules/PhotoAlbums/Services/PhotoAlbums.asmx");MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.CreateAlbum=function(D,F,B,A,E,C,G){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.CreateAlbum(D,F,B,A,E,C,G)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.DeleteAlbum=function(C,A,D,B,E){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.DeleteAlbum(C,A,D,B,E)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.SaveCaption=function(C,A,D,B,E){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.SaveCaption(C,A,D,B,E)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.GetSharedAlbumLink=function(A,B,D,C,E){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.GetSharedAlbumLink(A,B,D,C,E)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.GetNextPhoto=function(E,A,D,F,C,G,B,H){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.GetNextPhoto(E,A,D,F,C,G,B,H)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.GetPhotosSequence=function(B,A,E,D,F,G,C,H){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.GetPhotosSequence(B,A,E,D,F,G,C,H)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.GetPhotoComments=function(D,C,A,E,B,F){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.GetPhotoComments(D,C,A,E,B,F)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.DeleteImageComment=function(D,B,C,E,A,F){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.DeleteImageComment(D,B,C,E,A,F)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.DeleteImageCommentsMultiple=function(D,B,C,E,A,F){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.DeleteImageCommentsMultiple(D,B,C,E,A,F)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.UpdateAlbumPrivacy=function(A,D,C,E,B,F){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.UpdateAlbumPrivacy(A,D,C,E,B,F)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.ClearLastUpdatedAlbum=function(B,A,C){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.ClearLastUpdatedAlbum(B,A,C)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.MoveMultiplePhotos=function(D,B,A,F,E,C,G){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.MoveMultiplePhotos(D,B,A,F,E,C,G)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.MoveMultiplePhotosNewAlbum=function(D,G,H,B,I,A,F,C,E){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.MoveMultiplePhotosNewAlbum(D,G,H,B,I,A,F,C,E)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.DeleteMultiplePhotos=function(D,A,C,E,B,F){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.DeleteMultiplePhotos(D,A,C,E,B,F)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.SetDefaultPhoto=function(C,B,D,A,E){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.SetDefaultPhoto(C,B,D,A,E)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.ArrangeAlbums=function(C,B,D,A,E){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.ArrangeAlbums(C,B,D,A,E)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.ArrangePhotos=function(E,A,D,B,F,C,G){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.ArrangePhotos(E,A,D,B,F,C,G)};MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.UpdateAlbum=function(E,B,G,A,D,F,C,H){MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums._staticInstance.UpdateAlbum(E,B,G,A,D,F,C,H)};Type.registerNamespace("MySpace.Application.Integration");if(typeof(MySpace.Application.Integration.CommentStatus)==="undefined"){MySpace.Application.Integration.CommentStatus=function(){throw Error.invalidOperation()};MySpace.Application.Integration.CommentStatus.prototype={Allowed:0,Denied:1,Tom:2,SpecialProfile:3,ApprovalRequired:4,DailyUsageExceeded:5,FriendshipRequired:6,InvalidImageId:7,ContainsBannedPhrases:8};MySpace.Application.Integration.CommentStatus.registerEnum("MySpace.Application.Integration.CommentStatus",true)}Type.registerNamespace("MySpace.Media.Domain");if(typeof(MySpace.Media.Domain.AlbumPrivacy)==="undefined"){MySpace.Media.Domain.AlbumPrivacy=function(){throw Error.invalidOperation()};MySpace.Media.Domain.AlbumPrivacy.prototype={Everyone:0,FriendsOnly:1,Me:2};MySpace.Media.Domain.AlbumPrivacy.registerEnum("MySpace.Media.Domain.AlbumPrivacy",true)}if(typeof(MySpace.Web.Modules.PhotoAlbums.Services.Direction)==="undefined"){MySpace.Web.Modules.PhotoAlbums.Services.Direction=function(){throw Error.invalidOperation()};MySpace.Web.Modules.PhotoAlbums.Services.Direction.prototype={Centered:0,Forward:1,Backward:-1};MySpace.Web.Modules.PhotoAlbums.Services.Direction.registerEnum("MySpace.Web.Modules.PhotoAlbums.Services.Direction",true)}Type.registerNamespace("MySpace.PhotoAlbums");MySpace.PhotoAlbums.ShareAlbums=function(A){MySpace.PhotoAlbums.ShareAlbums.initializeBase(this,[A])};MySpace.PhotoAlbums.ShareAlbums.prototype={_SharedAlbumLinkBtn:null,_SharedAlbumLinkBtnObject:null,_shareAlbumDiv:null,_shareAlbumDivObject:null,_loadingImage:null,_friendId:null,_albumId:null,_GetSharedAlbumLinkHandler:null,_sharedAlbumLinkSuccessHandler:null,_SharedAlbumLinkFailureHandler:null,_copyText:null,_contactBlasterLink:null,_lastAlbumUploaded:false,get_copyText:function(){return this._copyText},set_copyText:function(A){this._copyText=A},get_clipboardSwf:function(){return this._clipboardSwf},set_clipboardSwf:function(A){this._clipboardSwf=A},get_albumId:function(){return this.getQueryString().albumid},get_loadingImage:function(){return this._loadingImage},set_loadingImage:function(A){this._loadingImage=A},get_SharedAlbumLinkBtn:function(){if(this._SharedAlbumLinkBtnObject==null){this._SharedAlbumLinkBtnObject=$get(this._SharedAlbumLinkBtn)}return this._SharedAlbumLinkBtnObject},set_SharedAlbumLinkBtn:function(A){this._SharedAlbumLinkBtn=A},get_shareAlbumDiv:function(){if(this._shareAlbumDivObject==null){this._shareAlbumDivObject=$get(this._shareAlbumDiv)}return this._shareAlbumDivObject},set_shareAlbumDiv:function(A){this._shareAlbumDiv=A},get_contactBlasterLink:function(){return this._contactBlasterLink},set_contactBlasterLink:function(A){this._contactBlasterLink=A},get_lastAlbumUploaded:function(){return this._lastAlbumUploaded},set_lastAlbumUploaded:function(A){this._lastAlbumUploaded=A},getQueryString:function(){var A=window.location.href.substring(window.location.href.lastIndexOf("?")+1);return qsObj=MySpace.Util.parseNameValuePairs(A.toLowerCase(),"&","=")},initialize:function(){this._GetSharedAlbumLinkHandler=Function.createDelegate(this,this.GetSharedAlbumLink);this._sharedAlbumLinkSuccessHandler=Function.createDelegate(this,this.SharedAlbumLinkSuccess);this._SharedAlbumLinkFailureHandler=Function.createDelegate(this,this.SharedAlbumLinkFailure);$addHandlers(this.get_SharedAlbumLinkBtn(),{click:this._GetSharedAlbumLinkHandler},this);if(this.get_lastAlbumUploaded()||typeof(this.getQueryString().testing)!=="undefined"){this.launchContactBlaster()}},GetSharedAlbumLink:function(){this.get_loadingImage().style.display="";MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.GetSharedAlbumLink(MySpace.ClientContext.UserId,this.get_albumId(),this._sharedAlbumLinkSuccessHandler,this._SharedAlbumLinkFailureHandler)},SharedAlbumLinkSuccess:function(B){var A=document.createElement("input");A.id="sharedLinkBox";A.className="Sharedlinktext";A.value=B.albumLink+"&authKey="+B.authKey;var E=document.createElement("input");E.id="btnsharedLink";E.type="button";E.value=this.get_copyText();var D=document.createElement("div");D.className="copyButton";var C=document.createElement("div");if(this.get_shareAlbumDiv()!==null){this.get_shareAlbumDiv().className="";this.get_SharedAlbumLinkBtn().style.display="none";this.get_loadingImage().style.display="none";this.get_shareAlbumDiv().appendChild(A);C.appendChild(E);D.appendChild(C);this.get_shareAlbumDiv().appendChild(D);$addHandlers($get("sharedLinkBox"),{focus:Function.createDelegate(this,this._selectAndCopy)},this);$addHandlers($get("btnsharedLink"),{click:Function.createDelegate(this,this._selectAndCopy)},this)}},SharedAlbumLinkFailure:function(){alert(MySpaceRes.ViewMorePicsPage.ErrorAjaxAction)},_selectAndCopy:function(E){var A;if(E.target.tagName.toLowerCase()==="input"&&E.target.type==="text"){A=E.target}else{A=E.target.previousSibling}if(A===null){A=$get("sharedLinkBox")}A.select();if(A.createTextRange){var B=A.createTextRange();if(B){B.execCommand("Copy")}}else{var D=$get("flashcopier");if(D===null){var F=document.createElement("div");F.id="flashcopier";document.body.appendChild(F);D=F}D.innerHTML="";var C='<embed src="'+this.get_clipboardSwf()+'" FlashVars="clipboard='+encodeURIComponent(A.value)+'" width="0" height="0" type="application/x-shockwave-flash"></embed>';D.innerHTML=C}},launchContactBlaster:function(){var link=this.get_contactBlasterLink();if(link!==null){var launchText=link.href.substring(link.href.indexOf(":")+1);eval(launchText);MySpace.Web.Modules.PhotoAlbums.Services.PhotoAlbums.ClearLastUpdatedAlbum()}},dispose:function(){$clearHandlers(this.get_SharedAlbumLinkBtn());delete this._GetSharedAlbumLinkHandler;delete this._sharedAlbumLinkSuccessHandler;MySpace.PhotoAlbums.ShareAlbums.callBaseMethod(this,"dispose")}};MySpace.PhotoAlbums.ShareAlbums.registerClass("MySpace.PhotoAlbums.ShareAlbums",Sys.UI.Behavior);var ShareAlbumsCCB;Sys.Application.add_init(setupClientCodeBehind);function setupClientCodeBehind(){var B=null;if(typeof(swfPath)=="undefined"){return}var A={clipboardSwf:swfPath,copyText:copyText,shareAlbumDiv:"SharedAlbumMainDiv",SharedAlbumLinkBtn:"btngenerateLink",loadingImage:$get(generateLoading),contactBlasterLink:$get("ContactBlaster1"),lastAlbumUploaded:LastAlbumUploaded};ShareAlbumsCCB=$create(MySpace.PhotoAlbums.ShareAlbums,A,null,null,$get("SharedAlbumMainDiv"));B=$create(MySpace.UI.Tooltip,{content:msgToolTip,autoPos:true},null,null,$get("arrow_lt"))}(function(){var B=MySpace.ClientContext.FunctionalContext;if(!(B=="UserViewPicture"||B=="UserViewPictureComments"||B=="ViewTaggedPhotos")){return}MySpace.Util.applyWBRToElements($q("#photo_list div.caption"));Array.forEach($q("a.removeTag"),function(F){$addHandler(F,"click",D)});function D(F){var I=E(F.target);if(I){$get("hdnImageIdToRemove").value=I.imageId;$get("hdnImageUserIdToRemove").value=I.imageUserId}if(!C){C=true;$addHandler(document,"keydown",function(K){if(K.keyCode===Sys.UI.Key.esc){get_overlay().hide();$get("modalConfirmTagRemoval").style.display="none"}})}var J=$get("modalConfirmTagRemoval");get_overlay().show();J.style.display="inline";J.style.visibility="visible";J.style.left="0";var H=J.getElementsByTagName("div")[0];if(!H){return}width=parseInt(H.style.width)||400;var G=(window.screen.width/2)-(width/2);Sys.UI.DomElement.setLocation(H,G,document.body.scrollTop)}var C=false;function E(F){while(F&&!Sys.UI.DomElement.containsCssClass(F,"photoItem")){F=F.parentNode}if(F){var G=F.id.split("_");return{imageId:G[1],imageUserId:G[2],photoItem:F}}return null}Array.forEach($q("a.postPhotoComment"),function(F){$addHandler(F,"click",A)});function A(G){G.preventDefault();var F=window.location.toString().substring(window.location.toString().lastIndexOf("?")+1),K=MySpace.Util.parseNameValuePairs(F.toLowerCase(),"&","="),H=K.albumid||0;photoItem=G.target;while(photoItem&&!Sys.UI.DomElement.containsCssClass(photoItem,"photoItem")){photoItem=photoItem.parentNode}if(photoItem){var L=photoItem.id.split("_"),I=L[1],J=L[2]}MySpace.UI.addQuickPostScript(function(){$create(MySpace.UI.QuickPostPopup,{webServiceUrl:"/Modules/PhotoAlbums/Services/PhotosQuickPostService.asmx",webServiceParams:{friendId:J,albumId:H,imageId:I}},{success:function M(N,O){if(!(O&&O.data&&O.data.CommentStatus==MySpace.Application.Integration.CommentStatus.Allowed)){return}var P=$q("span.commentCount",photoItem,true);if(P){count=parseInt(P.innerHTML.trim().split(" ")[0]);P.innerHTML=String.format("{0} {1}",++count,MySpaceRes.ViewMorePicsPage.Comments)}}}).show()})}})();MySpace.UI.Tooltip=function(A){this._tipDiv=document.createElement("div");this._tipDiv.innerHTML='<div style="position:absolute"></div><div class="t"><div><div></div></div></div><div class="m"><div id="fhLeftContentBorder" class="fhlborder"></div><div id="fhContent"></div><div id="fhRightContentBorder" class="fhrborder"></div><div class="clear"></div></div><div class="b"><div><div></div></div></div><iframe src="javascript:false" scrolling="no" frameborder="0" style="filter:Alpha(opacity=0);position:absolute;top:0px;left:0px;display:none;z-index:1;"></iframe>';this._tipDiv.id="tooltipdiv";this._tipDiv.className="tooltipdiv "+this.get_cssClass();this._contentDiv=this._tipDiv.childNodes[2].childNodes[1];this._leftBorder=this._tipDiv.childNodes[2].firstChild;this._rightBorder=this._tipDiv.childNodes[2].childNodes[2];this._topBorder=this._tipDiv.childNodes[1];this._bottomBorder=this._tipDiv.childNodes[3];MySpace.UI.Tooltip.initializeBase(this,[A])};MySpace.UI.Tooltip.prototype={_arrowDiv:null,_arrowOffsetX:0,_arrowOffsetY:0,_arrowPos:null,_autoPos:true,_bottomBorder:null,_container:null,_contentDiv:null,_cssClass:"",_hideDelay:500,_hideHandler:null,_hover:true,_left:null,_leftBorder:null,_margin:10,_reflect:false,_rightBorder:null,_showDelay:0,_showHandler:null,_theme:"helper",_timerID:0,_tipDiv:null,_tipOffsetX:0,_tipOffsetY:0,_tipPos:"bottomright",_top:null,_topBorder:null,_width:0,get_arrowOffsetX:function(){return this._arrowOffsetX},set_arrowOffsetX:function(A){this._arrowOffsetX=A},get_arrowOffsetY:function(){return this._arrowOffsetY},set_arrowOffsetY:function(A){this._arrowOffsetY=A},get_arrowPos:function(){return this._arrowPos},set_arrowPos:function(A){this._arrowPos=A},get_autoPos:function(){return this._autoPos},set_autoPos:function(A){this._autoPos=A},get_container:function(){return this._container},set_container:function(A){this._container=A},get_content:function(){return this._contentDiv.innerHTML},set_content:function(A){this._clearContents();if(typeof(A)==="object"){this._contentDiv.appendChild(A)}else{this._contentDiv.innerHTML=A}},get_cssClass:function(){return this._cssClass||""},set_cssClass:function(A){this._cssClass=A},get_hideDelay:function(){return this._hideDelay},set_hideDelay:function(A){this._hideDelay=A},get_hover:function(){return this._hover},set_hover:function(A){this._hover=A},get_left:function(){return this._left},set_left:function(A){this._left=A},get_margin:function(){return this._margin},set_margin:function(A){this._margin=A},get_reflect:function(){return this._reflect},set_reflect:function(A){this._reflect=A},get_showDelay:function(){return this._showDelay},set_showDelay:function(A){this._showDelay=A},get_theme:function(){return this._theme},set_theme:function(A){this._theme=A},get_tipDiv:function(){return this._tipDiv},set_tipDiv:function(A){this._tipDiv=A},get_tipOffsetX:function(){return this._tipOffsetX},set_tipOffsetX:function(A){this._tipOffsetX=A},get_tipOffsetY:function(){return this._tipOffsetY},set_tipOffsetY:function(A){this._tipOffsetY=A},get_tipPos:function(){return this._tipPos},set_tipPos:function(A){this._tipPos=A},get_top:function(){return this._top},set_top:function(A){this._top=A},get_width:function(){return this._width},set_width:function(A){this._width=A},initialize:function(){this._hideHandler=Function.createDelegate(this,this._delayedHide);this._showHandler=Function.createDelegate(this,this._delayedShow);if(this._hover){$addHandler(this._element,"mouseover",this._showHandler);$addHandler(this._element,"mouseout",this._hideHandler);$addHandler(this._tipDiv,"mouseover",Function.createDelegate(this,this._clearTimerID));$addHandler(this._tipDiv,"mouseout",this._hideHandler)}if(this._getIsFixed()){this._tipDiv.style.position="fixed"}this._contentDiv.className=this._theme;this._tipDiv.firstChild.className=this._theme+"arrow";if(this._container){this._container.appendChild(this._tipDiv)}else{document.body.appendChild(this._tipDiv)}this._arrowDiv=this._tipDiv.firstChild;if(this._width){this._tipDiv.style.width=this._width+"px"}},_clearContents:function(){var B=this._contentDiv;for(var A=B.childNodes.length-1;A>=0;A--){B.removeChild(B.childNodes[A])}},dispose:function(){$clearHandlers(this._element);if(this._container){this._container.removeChild(this._tipDiv)}else{document.body.removeChild(this._tipDiv)}MySpace.UI.Tooltip.callBaseMethod(this,"dispose")},show:function(){this._setPos();this._tipDiv.style.display="block";this._raiseEvent("visibilityChanged")},hide:function(){this._tipDiv.style.display="none";this._raiseEvent("tooltipClosed")},_clearTimerID:function(){if(this._timerID){clearTimeout(this._timerID);this._timerID=0}},_delayedHide:function(A){this._clearTimerID();this._timerID=window.setTimeout(Function.createDelegate(this,this.hide),this._hideDelay)},_delayedShow:function(A){this._clearTimerID();this._timerID=window.setTimeout(Function.createDelegate(this,this.show),this._showDelay)},_raiseEvent:function(A){var C=this.get_events().getHandler(A);if(C){var B=new Sys.EventArgs();C(this,B)}},_setPos:function(){var P=tipY=0;var D;this._tipDiv.className="tooltipdiv "+this.get_cssClass();this._arrowDiv.className=this._theme+"arrow";this._arrowPos=null;this._rightBorder.className="fhrborder";this._leftBorder.className="fhlborder";this._topBorder.className="t";this._bottomBorder.className="b";var L=Sys.UI.DomElement.getBounds(this._element);var M=this._getTipDims();var K=document.compatMode;var C=(K=="BackCompat")?document.body.scrollLeft:document.documentElement.scrollLeft;var B=(K=="BackCompat")?document.body.scrollTop:document.documentElement.scrollTop;if(Sys.Browser.agent===Sys.Browser.InternetExplorer&&K!="BackCompat"){L.x-=C;L.y-=B}if(!this._getIsFixed()&&Sys.Browser.agent===Sys.Browser.InternetExplorer){L.x+=C;L.y+=B}if(this._autoPos){this._setAutoPos(L,M)}var H=MySpace.UI.getComputedStyle(this._tipDiv);var F=MySpace.UI.getComputedStyle(this._arrowDiv);var J=(this._tipPos.indexOf("right")>-1?1:this._tipPos.indexOf("left")>-1?3:this._tipPos.indexOf("top")>-1?4:2);var I=M.width;if(this._width){I=this._width}P=L.x+L.width;switch(J){case 2:Sys.UI.DomElement.addCssClass(this._arrowDiv,"top");Sys.UI.DomElement.addCssClass(this._tipDiv,"tooltipbottom");break;case 3:Sys.UI.DomElement.addCssClass(this._arrowDiv,"right");Sys.UI.DomElement.addCssClass(this._tipDiv,"tooltipleft");P=L.x-I;this._rightBorder.className="fhrborderns";this._leftBorder.className="fhlborderws";this._bottomBorder.className="blc";this._topBorder.className="tlc";break;case 4:this._bottomBorder.className="bc";this._topBorder.className="tc";Sys.UI.DomElement.addCssClass(this._arrowDiv,"bottom");Sys.UI.DomElement.addCssClass(this._tipDiv,"tooltiptop");break;default:Sys.UI.DomElement.addCssClass(this._arrowDiv,"left");Sys.UI.DomElement.addCssClass(this._tipDiv,"tooltipright")}var E=F.height.replace("px","")-0;var G=F.width.replace("px","")-0;if(this._tipPos.indexOf("bottom")>-1){tipY=(this._tipPos!="bottom"?this._reflect?L.y:L.y+L.height-E-this._margin:L.y+L.height);P=(this._tipPos=="bottom"?L.x-(I/2)+(L.width/2):P);this._arrowPos=this._arrowPos||"top"}else{if(this._tipPos.indexOf("top")>-1){tipY=L.y-M.height+(this._tipPos!="top"?E+this._margin:0);P=(this._tipPos=="top"?L.x-(I/2)+(L.width/2):P);this._arrowPos=this._arrowPos||"bottom"}else{tipY=L.y-(M.height/2)+(L.height/2)-(E/2);this._arrowPos=this._arrowPos||"middle"}}this._tipDiv.style.left=(P+this._tipOffsetX)+"px";this._tipDiv.style.top=(tipY+this._tipOffsetY)+"px";var Q,A="";switch(this._arrowPos){case"bottom":Q=(this._tipPos=="top"?M.height:M.height-this._margin-E);if(this._tipPos=="top"){A=(this._arrowOffsetX+(I/2)-(G/2))+"px"}break;case"middle":Q=((M.height/2)-(E/2));break;default:Q=(this._tipPos=="bottom"?-E:this._margin);if(this._tipPos=="bottom"){A=(this._arrowOffsetX+(I/2)-(G/2))+"px"}}this._arrowDiv.style.left=A;this._arrowDiv.style.top=(Q+this._arrowOffsetY)+"px";var N=this._tipDiv.lastChild;N.width=I+"px";N.height=M.height+"px";N.style.zIndex=-1;N.style.display="block";this._tipDiv.style.height=M.height+"px";var O=MySpace.UI.getContentBox(this._contentDiv);if(browser.isIE6x&&document.compatMode!="BackCompat"){O.w+=15;I+=11}if(O.w==0||O.w>=I-10){O.w=I-11}this._contentDiv.style.width=O.w+"px";this._tipDiv.style.width=I+"px";if(this._left){this._tipDiv.style.left=this._left+"px"}if(this._top){this._tipDiv.style.top=this._top+"px"}},_setAutoPos:function(D,F){this._clearTimerID();var A=(typeof(window.pageXOffset)!=="undefined")?window.pageXOffset:document.documentElement.scrollLeft;var H=(typeof(window.pageYOffset)!=="undefined")?window.pageYOffset:document.documentElement.scrollTop;var G=(window.innerWidth?window.innerWidth:document.documentElement.clientWidth);var E=(window.innerHeight?window.innerHeight:document.documentElement.clientHeight);var C=["topleft","topright","bottomleft","bottomright"];var B=3;B=(D.x-F.width>A?(D.y-H+F.height>E&&D.y-F.height>H?(D.x+D.width+F.width<G?2:1):D.x+D.width+F.width<G?4:3):(D.y-H+F.height>E?2:4));this._tipPos=C[B-1]},_getTipDims:function(){var A=this._tipDiv.lastChild;A.style.display="none";this._contentDiv.style.width="";this._tipDiv.style.height="";this._tipDiv.style.width="";this._tipDiv.style.width=(this._width?this._width+"px":"");this._tipDiv.style.display="block";var B=Sys.UI.DomElement.getBounds(this._tipDiv);if(B.width<1){B.width=250}this._tipDiv.style.display="none";return{height:B.height,width:B.width}},_getIsFixed:function(){var A;var C=this._element.parentNode;while(C!==null){var B=MySpace.UI.getComputedStyle(C);if(B){A=B.position;if(A==="fixed"){return true}}C=C.parentNode}return false},add_tooltipClosed:function(A){this.get_events().addHandler("tooltipClosed",A)},remove_tooltipClosed:function(A){this.get_events().removeHandler("tooltipClosed",A)},add_visibilityChanged:function(A){this.get_events().addHandler("visibilityChanged",A)},remove_visibilityChanged:function(A){this.get_events().removeHandler("visibilityChanged",A)}};MySpace.UI.Tooltip.registerClass("MySpace.UI.Tooltip",Sys.UI.Control);