function stripBorder_2_yp56fe11974aaaa(object) { object.each(function() { if( parseInt(jQuery(this).width() ) > 0) { jQuery(this).width( parseInt( jQuery(this).width() ) - parseInt(jQuery(this).css("border-left-width")) - parseInt(jQuery(this).css("border-right-width")) ); } else { jQuery(this).css("border-left-width", "0px"); jQuery(this).css("border-right-width", "0px"); } }); } function stripPadding_2_yp56fe11974aaaa(object) { object.each(function() { jQuery(this).width( parseInt( jQuery(this).width() ) - parseInt(jQuery(this).css("padding-left")) - parseInt(jQuery(this).css("padding-left")) ); }); } function strip_results_2_yp56fe11974aaaa() { stripPadding_2_yp56fe11974aaaa( jQuery("#yop-poll-container-2_yp56fe11974aaaa .yop_poll_li_result-2_yp56fe11974aaaa") ); stripBorder_2_yp56fe11974aaaa( jQuery("#yop-poll-container-2_yp56fe11974aaaa .yop-poll-result-bar-2_yp56fe11974aaaa") ); } jQuery(document).ready(function(e) { if(typeof window.strip_results_2_yp56fe11974aaaa == "function") strip_results_2_yp56fe11974aaaa(); if(typeof window.tabulate_answers_2_yp56fe11974aaaa == "function") tabulate_answers_2_yp56fe11974aaaa(); if(typeof window.tabulate_results_2_yp56fe11974aaaa == "function") tabulate_results_2_yp56fe11974aaaa(); }); function equalWidth_2_yp56fe11974aaaa(obj, cols, findWidest ) { findWidest = typeof findWidest !== "undefined" ? findWidest : false; if ( findWidest ) { obj.each(function() { var thisWidth = jQuery(this).width(); width = parseInt(thisWidth / cols); jQuery(this).width(width); jQuery(this).css("float", "left"); }); } else { var widest = 0; obj.each(function() { var thisWidth = jQuery(this).width(); if(thisWidth > widest) { widest = thisWidth; } }); width = parseInt( widest / cols); obj.width(width); obj.css("float", "left"); } } function tabulate_answers_2_yp56fe11974aaaa() { equalWidth_2_yp56fe11974aaaa( jQuery("#yop-poll-container-2_yp56fe11974aaaa .yop-poll-li-answer-2_yp56fe11974aaaa"), 1 ); //equalWidth_2_yp56fe11974aaaa( jQuery("#yop-poll-container-2_yp56fe11974aaaa .yop-poll-li-answer-2_yp56fe11974aaaa .yop-poll-results-bar-2_yp56fe11974aaaa div "), 1, true ); } function tabulate_results_2_yp56fe11974aaaa() { equalWidth_2_yp56fe11974aaaa( jQuery("#yop-poll-container-2_yp56fe11974aaaa .yop-poll-li-result-2_yp56fe11974aaaa"), 1 ); //equalWidth_2_yp56fe11974aaaa( jQuery("#yop-poll-container-2_yp56fe11974aaaa .yop-poll-li-result-2_yp56fe11974aaaa .yop-poll-results-bar-2_yp56fe11974aaaa div "), 1, true ); } jQuery(document).ready(function(){ runOnPollStateChange_2_yp56fe11974aaaa(); }); function runOnPollStateChange_2_yp56fe11974aaaa() { };