Archive for May 19, 2015

Tuesday, May 19, 2015

NSFileCoordinator Improvement in iOS 8.2

Tom Harrington (tweet):

However last week the tech note was updated, and the above section now reads:

When you create a shared container for use by an app extension and its containing app in iOS 8.0 or later, you are obliged to write to that container in a coordinated manner to avoid data corruption. However, you must not use file coordination APIs directly for this in iOS 8.1.x and earlier. [emphasis mine]

That’s great! In iOS 8.2 or higher, the obvious approach should now be safe.

Previously: iOS IPC via NSFileCoordinator and NSFilePresenter.

Update (2015-07-28): Richard Turton:

This dictionary can then be written to a specified location in the shared folder. The write has to be atomic, to ensure that the other processes don’t start reading the file before it is written. NSDictionary has a writeToURL: atomically: method that can be used for this.

Interested members of the app group can then detect the writing of this file by monitoring a folder using GCD. The details of this can be seen in the FolderWatcher class in the linked project.

[…]

The limitations of the Darwin Notification Centre and the complexities of writing to and reading from a file make the above solution suitable for only a small number of cases.

Firing Well

Jean-Louis Gassée:

Of course, there is a second type of review, or, more accurately, there isn’t one. If the individual’s performance fails to meet requirements, the message should be succinct and clear: We need to part company. There’s no need to drag the victim through a painful and pointless Performance Improvement Process. (I will briefly address the in-between pass/fail configuration below.)

The termination of a work relationship can be just as clean and respectful as a positive review… and Firing Well starts with a sane and honest hiring process.

Apple Watch User-Experience Appraisal

Raluca Budiu:

That’s why perhaps the most striking feature of the Apple watch is how much it seems to have embraced teeny-tiny targets. To unlock the screen you have to type your pin on a minuscule numerical pad. And the application screen uses a plethora of tiny circles (representing apps) organized in a focus-plus-context visualization — the center of the screen is the focus and has the largest circles, and as you get further out, the icons get smaller. Launching an app is an adventure — not only because the icons (in-focus ones included) are too small even for the tiniest pinkies, but also because deciphering them requires good eyes, or at least diligence and the will to scroll around and bring them in focus.

[…]

The deck of cards (a full-page relative of the carousel) is a presentation model that goes back at least 20 years. Cards provide sequential instead of direct access and usually should be reserved for content that has a clearly sequential nature (e.g., books) or for lists with just a few elements. Yet, on the watch, the deck of cards is preferable to the the alternative list interface, which often requires going back and forth between a list view and an item-detail view (a form of pogo sticking), and thus involves multistep navigation. Plus, with the deck of cards, users can easily trigger the contextual menu (to save the story for later reading on the phone, for example) for each item right away, whereas in the list view users must navigate to the detail to invoke the contextual menu corresponding to that item.

[…]

The average interaction with an app on the phone is about 70 seconds and about half the duration of a web session on a computer. On the watch, we can expect the average session size to be substantially shorter. Think of the information that people care for and that they can access easily in just a few seconds. That’s what you should offer on the watch.

Thanks, Ted Landau

Ted Landau:

The first time I was paid for writing about the Mac was in 1985 when A+ magazine published a reader’s tip I submitted. It detailed how to use ResEdit to modify the Welcome to Macintosh message. For 300 words, I got paid $50. It was far from a momentous event. At the time, I didn’t expect it to lead anywhere. My day job was still as a professor of psychology. But, as it turned out, the reader’s tip was the spark that ignited a flame.

[…]

The result has been three decades of doing things I thoroughly enjoyed and getting paid for doing them. Who could ask for more?

Which brings me to today. I’ve decided to call it quits and hang up my virtual pen. What I expect to be the last article I get paid to write was posted to Macworld last December.

Previously: MacFixIt Is Gone.