PDA

¸ðµç ±â´ÉÀ» Æ÷ÇÔÇØ¼­ º¸±â : AppleScript: ÆÄ¿öºÏ »ç¿îµå ÀÔÃâ·Â ¼¼ÆÃÀ» ºí·çÅõ½º Çìµå¼ÂÀ¸·Î ¼³Á¤


albireo
2005/09/05, 04:51 PM
ºí·çÅõ½º Çìµå¼ÂÀ» ¾²´Ùº¸´Ï »ç¿îµå ÀÔÃâ·Â ¼¼ÆÃÀ» ¼ö½Ã·Î º¯°æÇØ Áà¾ß ÇÒ ¶§°¡ ÀÖ¾î ºÒÆíÇÏ´õ±º¿ä.

¿¹ÄÁµ¥ Skype °ú °°ÀÌ ¾ÖÇø®ÄÉÀÌ¼Ç ÀÚü ³»¿¡¼­ µ¶ÀÚÀûÀÎ »ç¿îµå ÀÔÃâ·Â ¼Ò½º ¼¼ÆÃÀ» ÇÒ ¼ö ÀÖµµ·Ï ÇØ ÁØ´Ù¸é Æí¸®ÇÏÁö¸¸, iSay ¿Í °°ÀÌ System Preferences > Sound ¿¡¼­ ÁöÁ¤ÇÏ´Â ½Ã½ºÅÛ ¿ÍÀÌµå ¼¼ÆÃ¿¡ µû¸£´Â ¾ÖÇø®ÄÉÀ̼ÇÀÇ °æ¿ì, ¾µ ¶§¸¶´Ù ºí·çÅõ½º·Î º¯°æÇϱ⵵ ±ÍÂú°í ¾²°í ³ª¼­ ´Ù½Ã µ¹·Á ³õ±âµµ ±ÍÂú½À´Ï´Ù.

÷ºÎÇÏ´Â ¾ÖÇýºÅ©¸³Æ®´Â ´Ü¹ø¿¡ »ç¿îµåÀÔ·Â ¼Ò½º¿Í Ãâ·Â ¼Ò½º¸¦ °¢°¢ ºí·çÅõ½º Çìµå¼Â ¸ðµå·Î ¹Ù²ãÁÝ´Ï´Ù. ¼­µÎÀÇ µÎ Ç׸ñ¸¸ º¯°æÇÏ¸é ¿øÇÏ´Â ´Ù¸¥ ¼Ò½º·Îµµ (³»À彺ÇÇÄ¿ ȤÀº »ç¿îµå½ºÆ½½º µî) ¹Ù²ã¾µ ¼ö ÀÖ½À´Ï´Ù.

-- This AppleScript set sound input & output sources of PowerBook to Bluetooth headset (or anything you want with little modification). Mac OS X 10.4 or later required.
-- Written by Hongsun Yoon, M.D., Albireo Project, September 2005

set target_input to "PLT 510 v.D"
set target_output to "PLT 510 v.D"

tell application "System Preferences" to activate
tell application "System Events"
get properties
tell process "System Preferences"
click menu item "Sound" of menu "View" of menu bar 1
delay 2
-- Output source setting
click radio button "Output" of tab group 1 of window "Sound"
set theRows to every row of table 1 of scroll area 1 of tab group 1 of window "Sound"
set theOutputs to {} as list
repeat with aRow in theRows
if (value of text field 1 of aRow as text) is equal to target_output then
set selected of aRow to true
exit repeat
end if
end repeat
-- Input source setting
click radio button "Input" of tab group 1 of window "Sound"
set theRows to every row of table 1 of scroll area 1 of tab group 1 of window "Sound"
set theInputs to {} as list
repeat with aRow in theRows
if (value of text field 1 of aRow as text) is equal to target_input then
set selected of aRow to true
exit repeat
end if
end repeat
end tell
end tell

tell application "System Preferences" to quit

gnarly
2006/02/07, 08:14 PM
°¨»çÇÕ´Ï´Ù.

zook
2006/09/15, 08:54 PM
±×¸²°ú °°Àº ¿¡·¯ ¸Þ¼¼Áö°¡ ¶ß´Â±º¿ä. Á¤È®È÷´Â Àß ¸ð¸£°ÚÁö¸¸ ¾Æ¸¶µµ

click menu item "Sound" of menu "View" of menu bar 1

¿©±â¼­ ¿À·ù°¡ ¹ß»ýÇÏ´Â °Í °°½À´Ï´Ù. ŸÀ̰Ű¡ ¾÷µ¥ÀÌÆ® µÇ¸é¼­ ¸Þ´º°¡ ¹Ù²ï°É±î¿ä?

click menu item "Sound" of menu "View" of menu bar

À§Ã³·³ º¯°æÇϸé menu bar¶ó´Â °ÍÀÌ ¾ø´Ù°í ³ª¿É´Ï´Ù. :-!

gluebyte
2006/09/15, 09:17 PM
½Ã½ºÅÛ È¯°æ ¼³Á¤ÀÇ "¼Õ½¬¿î »ç¿ë (Universal Access)"¿¡¼­ ¸Ç ¹Ø¿¡ ÀÖ´Â "º¸Á¶ Àåºñ »ç¿ë (Enable Access for Assistive Devices)" ¿É¼ÇÀÌ ÄÑÁ® ÀÖ¾î¾ß ÇÕ´Ï´Ù.

±×¸®°í, ¾ð¾î°¡ ÇÑ±Û »óÀ§ÀÏ °æ¿ì¿£ ¸Þ´º Ç׸ñµµ Çѱ۷Π¹Ù²ãÁà¾ß Çϰí¿ä:

click menu item "»ç¿îµå" of menu "º¸±â" of menu bar 1
...
click radio button "Ãâ·Â" of tab group 1 of window "»ç¿îµå"