(function(){var c=getTemplateMode()!="mixed"?Flavors.Global.namespace("Flavors.TemplateGroup"):Flavors.Global.namespace("Flavors.TemplateGroupLarge"),f=Flavors.Logger.getLogger(c.__name__),g={};c.init=function(){for(var a in accounts)if($("#service_"+a).hasClass("panel-box-large")){c.registerPanel(a);c.preparePanel(a)}if(Flavors.Controller)for(var d in g)if(Flavors.Controller.CSS_RULES[d])for(var e in g[d])Flavors.Controller.CSS_RULES[d].push(g[d][e])};c.preparePanel=function(a){f("preparePanel() serviceAnchor="+
a);if(a in c.services){var d=c.services[a];if(d.initialized)return d;var e=d.element;$(e).sectionSwitcher();$(e).find("DIV.section.audio").each(function(){$(this).is(":visible")&&$(this).musicPlayer(".track")}).end().find("DIV.section.gallery").each(function(){var b=$(this).find(".items .item:first .img-pending").length;if(b==0)b=$(this).find(".items .item:first img").length;f("minPageSize for service "+a+": "+b);if($(this).is(":visible")){$(this).deferredImageLoad({batchSize:b,loadNow:1});$(this).slidePanel()}else $(this).deferredImageLoad({batchSize:b});
$(this).find("DIV.section-body DIV.items DIV.item DIV.item-individual A.video-thumbnail").clickToSwitchEmbed()}).end().find("DIV.section.status").each(function(){$(this).is(":visible")&&$(this).slidePanel({loadNow:true})}).end().find("DIV.section.video").each(function(){$(this).is(":visible")&&$(this).clickToEmbed()}).end().find("DIV.section.blog").each(function(){if($(this).is(":visible")){$(this).deferredImageLoad({batchSize:5,loadNow:1});var b=$(this).find(".items .item:first object").length;$(this).deferredEmbedLoad({batchSize:1,
loadNow:b,embedSize:"large"})}else{$(this).deferredImageLoad({batchSize:5});$(this).deferredEmbedLoad({batchSize:1,embedSize:"large"})}$(this).blogNav();$(this).embedResize("large")}).end().find(".google-map").each(function(){$(this).googleMap($(this).attr("rel"))}).end();if($(e).is(".formspring")){$("#formspring-submit").css({"text-decoration":"none"}).hover(function(){$(this).css("background-color",primary_font_color_holder)},function(){$(this).css("background-color",link_font_color_holder)});$("#formspring-form").ajaxForm({url:get_formspring_url(),
dataType:"json",success:function(b){b&&b.success?$("#formspring-message").html('Your question has been sent. <a id="formspring-close" href="#">Ask another.</a>'):$("#formspring-message").html('An error occured sending your question. <a id="formspring-close" href="#">Try again.</a>')},beforeSubmit:function(){if($.trim($("#formspring-form textarea").val())==""){$("#formspring-message").html("Please enter a question.");$("#formspring-message").show();return false}$("#formspring-form").fadeOut(100,function(){$("#formspring-message").html("Sending your question to Formspring...");
$("#formspring-message").show()})}});$("#formspring-close").live("click",function(b){b.preventDefault();$("#formspring-message").html("");$("#formspring-message").hide(0,function(){$("#formspring-form textarea").val("");$("#formspring-form").show()})})}d.initialized=true;return d}};c.services={};c.registerPanel=function(a){f("large register() serviceAnchor="+a);c.services[a]={initialized:false};c.services[a]=new Flavors.Panel(a)}})();

