This page was exported from phaq [ http://phaq.phunsites.net ] Export date:Sat Apr 20 1:00:34 2024 / +0000 GMT ___________________________________________________ Title: Make OS X run custom actions upon DVD insert --------------------------------------------------- I'm currently ripping my complete DVD collection off to MKV (Matroska) format, so I can stream them across my home network. So I sought a way to have my OS X give me the choice to either start DVD Player or MakeMKV upon inserting a DVD. First I wrote a little AppleScript which gives me the choice. If I'm not taking any action, it will play the DVD automatically after 5 seconds, so it's very similar to the default behaviour of OS X. So just run Apple Script-Editor and store this code to a convenient location you like (usually it's ~/Library/Scripts). if not appIsRunning("DVD Player") and not appIsRunning("MakeMKV") then with timeout of 3600 seconds display dialog "Bitte wählen Sie gewünschte Aktion:" with title "Aktion für DVD" buttons {"Cancel", "DVD abspielen", "DVD rippen"} cancel button "Cancel" giving up after (5) end timeout if button returned of result is "DVD rippen" then display dialog "Starte MakeMKV" buttons {"OK"} giving up after 2 tell application "MakeMKV" to activate else if button returned of result is "Cancel" then quit else display dialog "Starte DVD-Player" buttons {"OK"} giving up after 2 tell application "DVD Player" to activate end if end if on appIsRunning(appName) tell application "System Events" to (name of processes) contains appName end appIsRunning Then go to system properties and select CDs & DVDs properties. Beneath "When you a insert a Video-DVD" choose "Run Script" and locate the script file you created before. From now on, you'll be presented with a selection prompt. Doing nothing will automatically start the DVD Player, or the DVD Ripper, if you choose to do so. Quiet cool, isn't it? ;-) --------------------------------------------------- Images: http://phaq.phunsites.net/files/2011/12/dvdaction1-300x119.jpg http://phaq.phunsites.net/files/2011/12/dvdaction2-300x96.png --------------------------------------------------- --------------------------------------------------- Post date: 2011-12-11 11:44:39 Post date GMT: 2011-12-11 10:44:39 Post modified date: 2011-12-11 20:29:57 Post modified date GMT: 2011-12-11 19:29:57 ____________________________________________________________________________________________ Export of Post and Page as text file has been powered by [ Universal Post Manager ] plugin from www.gconverters.com