This library is a simple DSL for your apple remote. It uses the AppleRemote.framework for Objective-C (by Martin Kahr) and RubyCocoa to hook it all up. It seems pointless, but was fun to write.
- Author
-
Rob Hurring (rob@zerobased.com)
- Copyright
-
Copyright © 2002 Zerobased, LLC
-
www.rubycocoa.com/appleremote/1 for the idea
-
Martin Kahr (www.martinkahr.com/source-code/) for the awesome AppleRemote framework
-
RubyCocoa (rubycocoa.sourceforge.net/HomePage) for being awesome.
Once you’re up and running with RubyCocoa, compiling the framework is pretty trivial. Theres instructions in the lib/framework/src/README file
play do puts "I'm playing... (Playing? #{playing?})" end pause do puts "I'm paused... (Playing? #{playing?})" end menu do if playing? puts "Do something with the menu while we're in 'play' state" else puts "Do something with the menu while we're not in the 'play' state" end end up(:up) do puts "The volume-up key is down." end up(:down) do puts "The volume-up key is released." end # See other files for more examples... As for cool stuff to do? I leave that to you.