Skip to content

Instantly share code, notes, and snippets.

@bluewhalelabs
Created June 18, 2011 22:14
Show Gist options
  • Save bluewhalelabs/1033554 to your computer and use it in GitHub Desktop.
Save bluewhalelabs/1033554 to your computer and use it in GitHub Desktop.
Turntable Growler
// ==UserScript==
// @name Turntable Growler
// @namespace http://fluidapp.com
// @description Creates growl notifications for chat in turntable
// @include *
// @author Gregarious Narain
// ==/UserScript==
(function () {
if (window.fluid) {
setTimeout(fluid_turntable_chat, 5000);
}
})();
function fluid_turntable_chat() {
jQuery('.messages').bind('DOMSubtreeModified',function(e) {
if (e.target.className === '') {
txt = jQuery(e.target);
window.fluid.showGrowlNotification({
title: "Turntable",
description: txt.prev().text() + ' ' + txt.text(),
priority: 1,
sticky: false
})
}
});
}
@bluewhalelabs
Copy link
Author

To install this you have to:

  1. Install Growl - http://growl.info
  2. Install Fluid - http://fluidapp.com
  3. Launch Fluid and create a new app for Turntable - http://cl.ly/0P2P1a0M0V1M2i1q1a0u
  4. Launch your Turntable app
  5. Create a new user script - http://cl.ly/3J0y172L3q1n0K0U2123
  6. Paste this script above in there
  7. Go to a room in Turntable and reload once to start the code (this is a bug i'll fix)

@mager
Copy link

mager commented Jun 20, 2011

whoa

@dshaw
Copy link

dshaw commented Jun 21, 2011

U R AWESOME mod (insert at line 26):
jQuery('#btn_upvote').click();

// this might get you banned.

@dshaw
Copy link

dshaw commented Jun 21, 2011

Actually, doesn't work, so we're good. Thought I could always drag out my real click simulator codez, but I love these guys and I can drag my hands away from the keyboard every ~5 mins and actually click.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment