Ext.namespace("Sun");Sun.showAjaxError=function(a){Ext.Msg.alert(Sun.Strings.ApplicationTitle,Sun.Strings.InvalidAjaxResponseMsg)};Sun.logout=function(){document.location.href="/admin/logout"};Sun.loadApp=function(url,callback,scope){Ext.Ajax.addListener("requestcomplete",function(c,r,o){eval(r.responseText)},null,{single:true});Ext.Ajax.addListener("requestcomplete",callback,scope,{single:true});Ext.Ajax.request({url:url,failure:function(response,options){alert("The application could not be loaded because the server sent an invalid response. Please try again later.")}})};Ext.QuickTips.init();Ext.Ajax.addListener("requestException",function(d,a,b){Sun.showAjaxError(a)});Ext.namespace("Sun.Strings");Sun.Strings.ApplicationTitle="Sun Area Technical Institute";Sun.Strings.InvalidAjaxResponseMsg="The server did not send a valid response. Please try again later.";Ext.namespace("Sun.Strings.CMS.Event");Sun.Strings.CMS.Event.OverviewWindowTitle="Events";Sun.Strings.CMS.Event.NewEventWindowTitle="New Event";Ext.namespace("Sun.Strings.CMS.Asset");Sun.Strings.CMS.Asset.UploadPanelTitle="Upload Asset";Ext.namespace("Sun.Strings.Directory.User");Sun.Strings.Directory.User.SelectionFieldEmptyText="No users match your query.";Sun.Strings.Directory.User.SelectionFieldBlankText="You must select a user.";Sun.Strings.Directory.User.SelectionFieldLabel="User";Ext.ns("Sun");Sun.VideoWindow=function(a){if(!a){a={}}html='<object width="425" height="344"><param name="movie" value="http://www.youtube.com/v/'+a.video+'&hl=en_US&fs=1&"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/'+a.video+'&hl=en_US&fs=1&" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"></embed></object>';Sun.VideoWindow.superclass.constructor.call(this,Ext.apply({autoWidth:true,autoHeight:true,layout:"fit",html:html,modal:true},a))};Ext.extend(Sun.VideoWindow,Ext.Window);