]> git.wh0rd.org Git - tt-rss.git/commitdiff
prototypize creation of headlines-spacer
authorAndrew Dolgov <fox@madoka.volgo-balt.ru>
Wed, 3 Aug 2011 14:48:28 +0000 (18:48 +0400)
committerAndrew Dolgov <fox@madoka.volgo-balt.ru>
Wed, 3 Aug 2011 14:48:28 +0000 (18:48 +0400)
viewfeed.js

index 9d5af3adf23bfec08e7a7fc9f504a529da9a51af..a4ac946a3b47f285a529f9d07422692d2188766a 100644 (file)
@@ -73,9 +73,7 @@ function headlines_callback2(transport, feed_cur_page) {
                                        reply['headlines']['toolbar']);
 
                                var hsp = $("headlines-spacer");
-                               if (!hsp) hsp = document.createElement("DIV");
-
-                               hsp.id = "headlines-spacer";
+                               if (!hsp) hsp = new Element("DIV", {"id": "headlines-spacer"});
 
                                if (!_infscroll_disable)
                                        hsp.innerHTML = "<img src='images/indicator_tiny.gif'> " +
@@ -103,9 +101,7 @@ function headlines_callback2(transport, feed_cur_page) {
                                                c.domNode.appendChild(row);
                                        });
 
-                                       if (!hsp) hsp = document.createElement("DIV");
-
-                                       hsp.id = "headlines-spacer";
+                                       if (!hsp) hsp = new Element("DIV", {"id": "headlines-spacer"});
 
                                        if (!_infscroll_disable)
                                                hsp.innerHTML = "<img src='images/indicator_tiny.gif'> " +