<feed xmlns='http://www.w3.org/2005/Atom'>
<title>Copy-Mailto/CopyMailto.xcodeproj/project.pbxproj, branch master</title>
<subtitle>Copy email addresses from `mailto:` links instead of opening an email client</subtitle>
<link rel='alternate' type='text/html' href='https://git.teddywing.com/Copy-Mailto/'/>
<entry>
<title>Rename "CopyMailto" Xcode project to "Copy Mailto"</title>
<updated>2018-09-05T22:08:25+00:00</updated>
<author>
<name>Teddy Wing</name>
</author>
<published>2018-09-05T22:08:25+00:00</published>
<link rel='alternate' type='text/html' href='https://git.teddywing.com/Copy-Mailto/commit/?id=4e2eea2beb2705e028226fe0300d17a7e223ec3c'/>
<id>4e2eea2beb2705e028226fe0300d17a7e223ec3c</id>
<content type='text'>
I like it better with the space in between. Normally I'm used to not
using spaces, but since you can here, do it.

Following this guide to rename the project:
https://digitalleaves.com/blog/2017/06/rename-xcode-project/

Not yet finished, but committing this stage of the rename now.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
I like it better with the space in between. Normally I'm used to not
using spaces, but since you can here, do it.

Following this guide to rename the project:
https://digitalleaves.com/blog/2017/06/rename-xcode-project/

Not yet finished, but committing this stage of the rename now.
</pre>
</div>
</content>
</entry>
<entry>
<title>Make "Quit" button work on "q" or "Escape" key press</title>
<updated>2018-09-05T21:10:18+00:00</updated>
<author>
<name>Teddy Wing</name>
</author>
<published>2018-09-05T21:10:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.teddywing.com/Copy-Mailto/commit/?id=b44d11312c8dd908a8e6d3c83e8f9773a893e15c'/>
<id>b44d11312c8dd908a8e6d3c83e8f9773a893e15c</id>
<content type='text'>
Previously I only had a key equivalent on the "Escape" key because you
can only set a single key equivalent. But I wanted the "Quit" button to
work on both "Escape" and "q" presses.

I tried to do this by overriding `performKeyEquivalent:`:

    - (BOOL)performKeyEquivalent:(NSEvent *)theEvent
    {
        if ([[theEvent characters] isEqualToString:@"q"] ||
            [theEvent keyCode] == kVK_Escape) {
        NSLog(@"%@", theEvent);
            return YES;
        }

        return [super performKeyEquivalent:theEvent];
    }

The method was called and it logged correctly, but the `IBAction`
wouldn't run. Maybe this doesn't work for what I want it to? Can't
figure out what the problem is.

Didn't want to deal any more so just overrode `keyDown:` instead and got
rid of the `IBAction`, just terminating the application in code.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Previously I only had a key equivalent on the "Escape" key because you
can only set a single key equivalent. But I wanted the "Quit" button to
work on both "Escape" and "q" presses.

I tried to do this by overriding `performKeyEquivalent:`:

    - (BOOL)performKeyEquivalent:(NSEvent *)theEvent
    {
        if ([[theEvent characters] isEqualToString:@"q"] ||
            [theEvent keyCode] == kVK_Escape) {
        NSLog(@"%@", theEvent);
            return YES;
        }

        return [super performKeyEquivalent:theEvent];
    }

The method was called and it logged correctly, but the `IBAction`
wouldn't run. Maybe this doesn't work for what I want it to? Can't
figure out what the problem is.

Didn't want to deal any more so just overrode `keyDown:` instead and got
rid of the `IBAction`, just terminating the application in code.
</pre>
</div>
</content>
</entry>
<entry>
<title>Turn off Sandbox</title>
<updated>2018-09-05T18:16:38+00:00</updated>
<author>
<name>Teddy Wing</name>
</author>
<published>2018-09-05T18:16:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.teddywing.com/Copy-Mailto/commit/?id=42778b8279444872811b855989d4d2fdec2572bf'/>
<id>42778b8279444872811b855989d4d2fdec2572bf</id>
<content type='text'>
Turns out you can't register yourself as the default app handler when in
a sandbox, which apparently is the default when creating a new Xcode
project.

&gt; that’s all…. except that I’m running my application in a Sandbox
&gt; environment, and it returns the error -54 !
&gt;
&gt; After trying to find a solution for this, and on the
&gt; devforums.apple.com forum, it seems that there is currently no
&gt; solution, Apple just decided to remove that feature since Yosemite….
&gt; It still works on Mavericks.  That of course very disappointing, and
&gt; even not mentioned in the Apple’s documentation.

(https://blog.sovapps.com/make-your-application-reply-to-mailto-links/)

Fuck that. Turn off sandboxing. Yay it works now.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Turns out you can't register yourself as the default app handler when in
a sandbox, which apparently is the default when creating a new Xcode
project.

&gt; that’s all…. except that I’m running my application in a Sandbox
&gt; environment, and it returns the error -54 !
&gt;
&gt; After trying to find a solution for this, and on the
&gt; devforums.apple.com forum, it seems that there is currently no
&gt; solution, Apple just decided to remove that feature since Yosemite….
&gt; It still works on Mavericks.  That of course very disappointing, and
&gt; even not mentioned in the Apple’s documentation.

(https://blog.sovapps.com/make-your-application-reply-to-mailto-links/)

Fuck that. Turn off sandboxing. Yay it works now.
</pre>
</div>
</content>
</entry>
<entry>
<title>Add `DefaultURLHandler`; Get current handler for `mailto` URLs</title>
<updated>2018-09-05T17:00:55+00:00</updated>
<author>
<name>Teddy Wing</name>
</author>
<published>2018-09-05T17:00:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.teddywing.com/Copy-Mailto/commit/?id=da31291a965ea898a59a0859c7e455144eaea195'/>
<id>da31291a965ea898a59a0859c7e455144eaea195</id>
<content type='text'>
Add a class to get the current bundle handler for `mailto` URLs. It will
be extended to set CopyMailto as the default handler after saving the
original.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add a class to get the current bundle handler for `mailto` URLs. It will
be extended to set CopyMailto as the default handler after saving the
original.
</pre>
</div>
</content>
</entry>
<entry>
<title>Change project to build for older OSes</title>
<updated>2018-09-05T16:09:56+00:00</updated>
<author>
<name>Teddy Wing</name>
</author>
<published>2018-09-05T15:22:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.teddywing.com/Copy-Mailto/commit/?id=69d948f117df445d1cb1060ebda9afd967a58f74'/>
<id>69d948f117df445d1cb1060ebda9afd967a58f74</id>
<content type='text'>
Set deployment target to OS X 10.6 and the Xcode project to Xcode 3.2.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Set deployment target to OS X 10.6 and the Xcode project to Xcode 3.2.
</pre>
</div>
</content>
</entry>
<entry>
<title>New Xcode 9.2 (9C40b) project</title>
<updated>2018-09-05T15:20:59+00:00</updated>
<author>
<name>Teddy Wing</name>
</author>
<published>2018-09-05T15:20:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.teddywing.com/Copy-Mailto/commit/?id=9b38dbaef7e8e29ee2ee08204facadd408d2e378'/>
<id>9b38dbaef7e8e29ee2ee08204facadd408d2e378</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
