This is a browser Extension for Safari and Google Chrome. If you want to see its guts, check out global.html in either folder. latest_post.js/contentscript.js is an injected script that simply extracts the URL that Tumblr's abacus uses to check for new posts.
If you're interested in modifying the extension, I suggest you sign up for the Safari Developer Program and get a Signing Certificate.