",$("#chat-body").append(msg),$("#chat-body").scrollTop($("#chat-body")[0].scrollHeight)}function updateTips(e){var a=parseInt($("#tip-progress-goal").html()),t=parseInt($("#tip-progress-current").html()),s=100*t/a;$("#tip-progressbar").attr("aria-valuemax",a),$("#tip-progressbar").attr("aria-valuenow",t+e),$("#tip-progressbar").css("width",s+"%"),$("#tip-progress-current").html(t+e)}function customTip(){$("#custom-tip-modal").modal()}function tip(e){return cam4.balance i").hasClass("fa-volume-up")?($("#video").prop("muted",!0),$("#mute-btn > i").removeClass("fa-volume-up").addClass("fa-volume-off")):($("#video").prop("muted",!1),$("#mute-btn > i").removeClass("fa-volume-off").addClass("fa-volume-up"))}function displayGuestNotice(){$("#guest-notice-modal").modal()}function replaceAddons(e){var a={' ':Array("[hi]"),' ':Array("[yes]"),' ':Array("[no]"),' ':Array("[makelove]"),' ':Array("[play]"),' ':Array("[horny]"),' ':Array("[webcam]"),' ':Array("[busy]"),' ':Array("[brb]"),' ':Array("[bfn]"),' ':Array("[cool]"),' ':Array("[ok]"),' ':Array("[omg]"),' ':Array("[smiley]"),' ':Array("[talk]"),' ':Array("[kiss]"),' ':Array("[hot]"),' ':Array("[rocket]"),' ':Array("[censored]"),' ':Array("[approved]"),' ':Array("[whatsup]"),' ':Array("[mail]"),' ':Array("[fuck]"),' ':Array("[thankyou]")};for(var t in a)for(var s=0;s i").hasClass("fa-commenting-o")?($(".overlay-chat").hide(),$("#chat-message").hide(),$("#toggle-mobile-chat > i").removeClass("fa-commenting-o").addClass("fa-commenting")):($(".overlay-chat").show(),$("#chat-message").show(),$("#toggle-mobile-chat > i").removeClass("fa-commenting").addClass("fa-commenting-o"))}function positionMobileProgressBar(){var e=$("#chatroom-container").width()-$("#mute-btn").outerWidth(!0)-$("#private-btns").outerWidth(!0)-$("#tip-group").outerWidth(!0)-10;$("a.progress").width(e),$("a.progress").prependTo(".performer-actions"),$(".overlay-chat").width(.5*$("#chatroom-container").width()),$(".chatbox-input-wrapper").prependTo(".overlay-bottom")}function toggleVideoZoom(){"cover"==$("#video").css("object-fit")?$("#video").css("object-fit","contain"):$("#video").css("object-fit","cover")}RegExp.escape=function(e){return e.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}; function columnSize(id) { $('.layout-adjuster a').removeClass('active'); $('#'+id).addClass('active'); switch (id) { case 'three-cols' : $('.dynamic-col').removeClass('col-md-3 col-md-7-columns').addClass('col-md-4'); localStorage.setItem("columns", "three-cols"); break; case 'four-cols' : $('.dynamic-col').removeClass('col-md-7-columns col-md-4').addClass('col-md-3'); localStorage.setItem("columns", "four-cols"); break; case 'six-cols' : $('.dynamic-col').removeClass('col-md-4 col-md-3').addClass('col-md-7-columns'); localStorage.setItem("columns", "six-cols"); break; } } function showVideo(id){ //populate modal and show it $("#market-video-title").text($("#video-"+id).data('name')); $("#market-video-description").text($("#video-"+id).data('description')); $("#market-video-duration").text($("#video-"+id).data('duration')); $("#market-video-tags").text($("#video-"+id).data('tags')); $("#market-video-price").text($("#video-"+id).data('price')); if($("#video-"+id).data('purchased')){ $("#market-video-footer").hide(); $("#market-video-thumb").hide(); $("#market-video-video").attr('poster', $("#video-"+id).data('thumb')); $("#market-video-video-wrapper").show(); //load the video url $.get('/en/play-video/'+id, { }, function(data){ if(data.ok){ $("#market-video-loading").hide(); $("#market-video-video").attr('src', data.url).show().get(0).play(); } }, 'json'); } else{ $("#market-video-video").hide(); $("#market-video-video-wrapper").hide(); $("#market-video-footer").show(); $("#market-video-btn").attr('data-videoid', id); $("#market-video-thumb").css('background-image', 'url('+$("#video-"+id).data('thumb')+')').show(); } $('#market-video-modal').modal(); } function quickRegistration(e){ //populare the real registration form and show it $("#member_username").val($("#quick-username").val()); $("#member_email").val($("#quick-email").val()); $("#member_password").val($("#quick-pwd").val()); $("#member_password_confirmation").val($("#quick-pwd-conf").val()); showRegisterModal(); e.preventDefault(); return false; } function toggleFilters(){ $('#page-wrapper').toggleClass('toggled'); }