find();
window.addEventListener("focus", find);

function find() {
  if (window == top) {
    // Find all the RSS link elements.
    var result = document.evaluate(
        '//link[@rel="alternate"][contains(@type, "rss") or ' +
        'contains(@type, "atom") or contains(@type, "rdf")]',
        document, null, 0, null);

    var feeds = [];
    var item;
    while (item = result.iterateNext())
      feeds.push(item.href);

    chromium.extension.connect().postMessage(feeds);
  }
}

find();
window.addEventListener("focus", find);

function find() {
  if (window == top) {
    // Find all the RSS link elements.
    var result = document.evaluate(
        '//link[@rel="alternate"][contains(@type, "rss") or ' +
        'contains(@type, "atom") or contains(@type, "rdf")]',
        document, null, 0, null);

    var feeds = [];
    var item;
    while (item = result.iterateNext())
      feeds.push(item.href);

    chrome.extension.connect().postMessage(feeds);
  }
}

Fix an occurence of 'chromium' that didn't get changed to 'chrome'
Fix an  occurence of 'chromium' that didn't get changed to 'chrome'

Review URL: http://codereview.chromium.org/115049

git-svn-id: de016e52bd170d2d4f2344f9bf92d50478b649e0@15486 0039d316-1c4b-4281-b951-d872f2087c98
