Jump to content

Puck

Member
  • Posts

    5
  • Joined

  • Last visited

Posts posted by Puck

  1. Hi there,

    after I updated to OS X 10.9 Mavericks. The Script didn't work. 

    I found this one which works except not passing the {query} to the Post Notification.

    tell application "System Preferences"
    	set current pane to pane "com.apple.preference.keyboard"
    end tell
    
    tell application "System Events"
    	if UI elements enabled then
    		tell tab group 1 of window "Keyboard" of process "System Preferences"
    			click checkbox "Use all F1, F2, etc. keys as standard function keys"
    
    			if (do shell script "defaults read -g com.apple.keyboard.fnState") = "1" then
    				set fnStateRead to "Special Keys - Volume, iTunes..."
    			else
    				set fnStateRead to "Function Keys - F1, F2, F3..."
    			end if
    
    			do shell script "~/Applications/terminal-notifier.app/Contents/MacOS/terminal-notifier -message \"Function Swapper, an AS & Shell script\" -title \"" & fnStateRead & "\"  -activate com.orderedbytes.ControllerMate4"
    
    		end tell
    	else
    		tell application "System Preferences"
    			set current pane ¬
    				to pane "com.apple.preference.universalaccess"
    			display dialog ¬
    				"UI element scripting is not enabled. Check \"Enable access for assistive devices\""
    		end tell
    	end if
    end tell
    
    tell application "System Preferences"
    	quit
    end tell
    

    Hope this helps.

     

    Have fun!

  2. Hey everybody,

     

    love to see all those workflows emerge and being able to use them.

    Now it's time to share my own very first workflow :)

     

    This workflow toggles Type2Phone and Bluetooth

     

    By typing ‘tnb‘ within Alfred an Applescript is started to either

    turn bluetooth on and launch Type2Phone or

    quit Type2Phone and switch bluetooth off

    depending if Bluetooth is active right now or not.

     

    Type2Phone%20and%20Bluetoth.png

     

    Download the Workflow

     

    This Workflow requires:

    #1 the Software Type2Phone, which lets you use your Macs Keyboard to type on your iPhone (App Store Link).

    #2 blueutil. It's a commandline-tool to turn Bluetooth on and off.

    I tested it under OS X 10.8.4.

     

    Notice:

    I noticed the workflow doesn't bring Typ2Phone to the foreground. Additionally Type2phone does not start up reliably. Any tips?

×
×
  • Create New...