Wake up your display with Adium and Applescript

I had a problem with Adium: After 3 minutes of inactivity, my monitor goes to sleep. With the laptops volume turned low I would not notice any incoming messages whenever I was playing a game or anything that made some level of noise.

Back when I used windows, Miranda woke up my display when it received a message. That was an option I missed from Adium. The solution to this was pretty simple though. Adium provides the possibility to execute an Applescript on events. So I wrote a litte script to wake up my display and bound that to the “Message received (initial)” event. The script? Not very impressive:

tell application "System Events" to key code 59

But it works! :)

(Key Code 59 is the CTRL key, so you don’t accidentally trigger anything by firing it)

2 Comments for 'Wake up your display with Adium and Applescript'

Nice tip ;} Thx

Mark

Hey Jan, many thanks for the tip, I had found it was doing the job great.
However after a while I noticed that if I was trying to type when someone else sent me a message, that it would then drop a number of the characters that I typed.
I guess it would work better if the Adium folks implemented wake-display as a proper event.
Kind regards, Mark.

Write a comment

Trackback: http://jan.varwig.org/archive/wake-up-your-display-with-adium-and-applescript/trackback
Comment-Feed: RSS2