Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 find(); | |
| 2 window.addEventListener("focus", find); | |
| 3 | |
| 4 function find() { | |
| 5 if (window == top) { | |
| 6 // Find all the RSS link elements. | |
| 7 var result = document.evaluate( | |
| 8 '//link[@rel="alternate"][contains(@type, "rss") or ' + | |
| 9 'contains(@type, "atom") or contains(@type, "rdf")]', | |
| 10 document, null, 0, null); | |
| 11 | |
| 12 var feeds = []; | |
| 13 var item; | |
| 14 while (item = result.iterateNext()) | |
| 15 feeds.push(item.href); | |
| 16 | |
| 17 chromium.extension.connect().postMessage(feeds); | |
| 18 } | |
| 19 } | |
| OLD | NEW |