]> git.mxchange.org Git - friendica.git/blobdiff - view/theme/frost-mobile/js/main.js
Merge pull request #2874 from Hypolite/bug/fix-pgettext-typo
[friendica.git] / view / theme / frost-mobile / js / main.js
index 926de5d253f81f3db40a5e38c4c5352b57051671..3ec2421df2f0a9888db6fc2b7efe1d2db08fa3e5 100644 (file)
@@ -13,7 +13,6 @@
                if($(listID).is(":visible")) {
                        $(listID).hide();
                        $(listID+"-wrapper").show();
-                       alert($(listID+"-wrapper").attr("id"));
                }
                else {
                        $(listID).show();
@@ -34,7 +33,6 @@
        var src = null;
        var prev = null;
        var livetime = null;
-       var msie = false;
        var stopped = false;
        var totStopped = false;
        var timer = null;
@@ -49,9 +47,7 @@
        $(function() {
                $.ajaxSetup({cache: false});
 
-               msie = $.browser.msie ;
-               
-               collapseHeight();
+               //collapseHeight();
 
                /* setup tooltips *//*
                $("a,.tt").each(function(){
                        if(livetime) {
                                clearTimeout(livetime);
                        }
-                       livetime = setTimeout(liveUpdate, 10000);
+                       livetime = setTimeout(liveUpdate, 5000);
                        return;
                }
                if(livetime != null)
 
                in_progress = true;
                var udargs = ((netargs.length) ? '/' + netargs : '');
-               var update_url = 'update_' + src + udargs + '&p=' + profile_uid + '&page=' + profile_page + '&msie=' + ((msie) ? 1 : 0);
+               var update_url = 'update_' + src + udargs + '&p=' + profile_uid + '&page=' + profile_page;
 
                $.get(update_url,function(data) {
                        in_progress = false;
                                $('body').css('cursor', 'auto');
                        }
                        /* autocomplete @nicknames */
-                       $(".comment-edit-form  textarea").contact_autocomplete(baseurl+"/acl");
+                       $(".comment-edit-form  textarea").editor_autocomplete(baseurl+"/acl");
 
                        // setup videos, since VideoJS won't take care of any loaded via AJAX
                        if(typeof videojs != 'undefined') videojs.autoSetup();
                        elemName = elems + ' ' + elemName;
                }
                $(elemName).each(function() {
-                       if($(this).height() > 350) {
-                               $('html').height($('html').height());
-                               $(this).divgrow({ initialHeight: 300, showBrackets: false, speed: 0 });
-                               $(this).addClass('divmore');
-                               $('html').height('auto');
-                       }
+                       $('html').height($('html').height());
+                       $(this).readmore({maxheight:350 , moreLink:'<a href="#" class="showmore">+ Show more</a>', lessLink:'<a href="#" class="showmore">+ Show less</a>'});
+                       $(this).addClass('divmore');
+                       $('html').height('auto');
                });
        }