Category: Apple Computer

Swift 3: Distance between two CGPoints 0

Swift 3: Distance between two CGPoints

Here it is in Swift 3, it’s a little different. I tried to use hypotf but it didn’t like CGFloat subtraction.

 

Protocol/delegates in Swift 3.0 0

Protocol/delegates in Swift 3.0

I declare this day a fine day having discovered non-Objective-C protocols! No more @objc protocol usage. Now it’s as simple as something like this:

And then in implementation

This is a really...

Shaking a macOS Window 0

Shaking a macOS Window

There may come a time when you’d like to shake a macOS application’s window (or one of them) to reinforce an event. In my case, I am creating a macOS application that serves as...

WatchOS 2.2.2 Debug Symbols A.W.O.L. 0

WatchOS 2.2.2 Debug Symbols A.W.O.L.

On Jul 18th Apple released several operating system updates. WatchOS 2.2.2 was one of those released updates. Four days ago. Since installation I have been unable to debug watch extensions on my real device...

WatchConnectivity gotcha. willActivate() 1

WatchConnectivity gotcha. willActivate()

This may seem simple for many who have been busy developing Watch extensions for the Apple Watch, but it stumped me for about a minute. Not long, but long enough for me to slap...

Swift: When you have an Optional String you need to remove 0

Swift: When you have an Optional String you need to remove

Recently I have been developing an iOS app that comes with a companion Apple Watch extension. I wanted to play with the communication between iOS and WatchOS using

via

It was working well...

Swift: Bose SoundTouch device discovery using Bonjour 0

Swift: Bose SoundTouch device discovery using Bonjour

Are you a developer wanting to use the Bose SoundTouch Developer APIs to create an experience that drives SoundTouch devices? Are you interested in implementing Bonjour discovery AND resolving IP Addresses without using Objective-C...

Swift: Bonjour, NSNetService & IP Addresses 2

Swift: Bonjour, NSNetService & IP Addresses

Good morning. At least it’s a good morning here. I have recently been exploring Bonjour in Swift – I have never investigated Bonjour as a concept as networking is one of the weaker areas...

Multi-platform API for Google Nearby Messages 0

Multi-platform API for Google Nearby Messages

I happened upon a video presentation from Google I/O 2016 that I felt was interesting. It was called “Introducing Nearby: Physical proximity within and without apps – Google I/O 2016”. I present it here...