pkamb / PowerKey

Remap your Macbook's power key to Forward Delete
MIT License
229 stars 29 forks source link

Add “Script” as a key replacement option #19

Closed dlh closed 9 years ago

dlh commented 10 years ago

This branch adds Script as a key replacement option.

I was having an issue with a service I wrote and globally bound to the F13 key (System Preferences → Keyboard → Shortcuts). F13 would launch the service, but only after I clicked the app menu (which holds the Services sub-menu)—it seems others have had the same issue. Thus, PowerKey would not consistently work on my headless media-server.

Note: I did not update the etc/screenshots/remappingOptions_small.png screenshot.

pkamb commented 10 years ago

Beautiful, thanks! Will test this and pull it in soon.

dlh commented 10 years ago

I pushed a small change to better handle when the user presses the script-open-panel's cancel button.

pkamb commented 10 years ago

@dlh did you push that change? I only see the one commit d759664ead565b7dee82b4cef0bcbb0186882332

dlh commented 10 years ago

I rebased and force-pushed.

pkamb commented 10 years ago

Thanks, I've pushed this to the script branch rather than merge the PR into master.

I think we should support AppleScript files before releasing this.

I like the minimal UI of selecting a file by simply selecting the "script" key replacement, but it's confusing when you can't Open a file (such as an AppleScript file) from the panel. Open button seems to not work. We'll need to disable to Open button, grey out invalid files, present some kind of error text, etc.

Thanks for your work on this! Feel free to continue working on it or I will polish it up for the next release.

pkamb commented 9 years ago

Thank you for your work on this @dlh! I've (finally) released Script and AppleScript functionality in v1.3:

https://github.com/pkamb/PowerKey/releases/tag/v1.3