Show
Ignore:
Timestamp:
08/03/08 14:59:26 (4 months ago)
Author:
cho45
Message:
  • 同じページのをもってきたとき Expand がつかないことがあったのを修正
  • 自分のエントリについてる delete ボタンがダブるのを修正
Files:
1 modified

Legend:

Unmodified
Added
Removed
  • lang/javascript/userscripts/hatena.haiku.expandrepliestree.user.js

    r17014 r17017  
    4848                }); 
    4949 
     50                // remove script added links 
     51                $X("./div/div/span[@class='delete']/img", entry).forEach(function (i) { 
     52                        i.parentNode.removeChild(i); 
     53                }); 
     54 
    5055                Global.Hatena.Haiku.Pager.dispatchEvent('loadedEntries', entry.parentNode.wrappedJSObject || entry.parentNode); 
    5156                return entry; 
     
    6065                        // 深すぎるので、さらに展開するためのリンクをつけたうえで終了する。 
    6166                        return next(function (i) { 
    62                         //var entries = $X("//div[@class='entries']/div[@class='entry'][.//img[@alt='Reply to'] or .//span[@class='replies']/a]"); 
    63                                 if (!$X("boolean( .//a[.//img[@alt='Reply to'] and not(@class = '__loaded')] | .//span[@class='replies']/a[not(@class = '__loaded')] )", entry)) return; 
    64                                 log("level too deep. Please click the link to expand more."); 
     67                                log([entry, "too deep"]); 
     68                                if (!$X("boolean( ./div/div/a[.//img[@alt='Reply to'] and not(@class = '__loaded')] | ./div/div/span[@class='replies']/a[not(@class = '__loaded')] )", entry)) return; 
     69                                entry._gm_expandreplies_applied = false; 
    6570                                addExpandLink(entry, function () { 
    6671                                        log("expand more -> child"); 
    6772                                        return expandReplies(entry, LEVEL); 
    6873                                }); 
    69                         }); 
     74                        }).error(function (e) { alert(e) }); 
    7075                } 
    7176