Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Practical WatchKit Development (UIKonf 2015)
Search
Sponsored
·
Ship Features Fearlessly
Turn features on and off without deploys. Used by thousands of Ruby developers.
→
Claus Höfele
May 18, 2015
Programming
290
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Practical WatchKit Development (UIKonf 2015)
Presentation at UIKonf 2015 in Berlin
http://www.uikonf.com
Claus Höfele
May 18, 2015
More Decks by Claus Höfele
See All by Claus Höfele
Server-Side Swift (iOSDevUK 7)
choefele
0
240
Running Swift Code on AWS Lambda (CocoaHeads 01/2017)
choefele
0
380
Swift server applications with Docker (Swift.Berlin #21)
choefele
0
340
Practical WatchKit Development (CocoaHeads 04/2015)
choefele
0
110
Developing Apps for the Watch
choefele
0
160
Other Decks in Programming
See All in Programming
1B+ /day規模のログを管理する技術
broadleaf
0
130
LLMによるContent Moderationの本番運用の裏側と品質担保への挑戦
suikabar
3
840
初めてのKubernetes 本番運用でハマった話
oku053
0
120
ローカルLLMでどこまでコードが書けるか -拡張版 / How much code can be written on a local LLM Extended
kishida
12
4.7k
使用 Meilisearch 建立新聞搜尋工具
johnroyer
0
130
Hatena Engineer Seminar #37「言語モデルの活用に関する研究」
slashnephy
0
510
Generative UI & AI-Assistants for Your Angular Solutions
manfredsteyer
PRO
1
160
Hunting Vulnerabilities in Symfony with LLMs
vinceamstoutz
0
580
【やさしく解説 設計編・中級 #6】良いアーキテクチャとは ~ 一本の登り道の、行き先 ~
panda728
PRO
0
140
Claude Team Plan導入・ガイド
tk3fftk
0
170
SREは、MCPとSRE Agentをこう使え!
kazumax55
0
150
どこまでゆるくて許されるのか
tk3fftk
0
470
Featured
See All Featured
世界の人気アプリ100個を分析して見えたペイウォール設計の心得
akihiro_kokubo
PRO
72
40k
Practical Tips for Bootstrapping Information Extraction Pipelines
honnibal
25
2k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
133
19k
Visual Storytelling: How to be a Superhuman Communicator
reverentgeek
2
590
The #1 spot is gone: here's how to win anyway
tamaranovitovic
3
1.1k
The AI Revolution Will Not Be Monopolized: How open-source beats economies of scale, even for LLMs
inesmontani
PRO
3
3.6k
AI: The stuff that nobody shows you
jnunemaker
PRO
8
820
Building AI with AI
inesmontani
PRO
1
1.1k
The Curse of the Amulet
leimatthew05
2
13k
Helping Users Find Their Own Way: Creating Modern Search Experiences
danielanewman
31
3.2k
Navigating Team Friction
lara
192
16k
Creating an realtime collaboration tool: Agile Flush - .NET Oxford
marcduiker
35
2.5k
Transcript
Practical WatchKit Development @claushoefele
Kleinanzeigen TransitHopper
WatchKit App WatchKit Extension iOS App WatchKit App vs Extension
None
Interactive Notifications
class TripDetailInterfaceController: WKInterfaceController { @IBOutlet private weak var map: WKInterfaceMap!
override func awakeWithContext(context: AnyObject?) { super.awakeWithContext(context) ... } override func willActivate() { super.willActivate() ... } }
map.addAnnotation(coordinate, withPinColor: .Red) let coordinateRegion = MKCoordinateRegionMakeWithDistance[...] map.setRegion(coordinateRegion)
Tables
Paging
Hides when loading Off On
None
WatchKit App WatchKit Extension Requesting Data
WatchKit App WatchKit Extension iOS App openParentApplication()
private func callParentApp() { let userInfo = ["input": "data"] WKInterfaceController.openParentApplication(userInfo)
{ replyInfo, error in println("reply \(replyInfo)") } } func application(_:handleWatchKitExtensionRequest:reply:) Calling the Parent App
Handoff
User Location Permissions WatchKit App WatchKit Extension iOS App When
In Use Always
WatchKit Extension iOS App Sharing Data
None
let defaults = NSUserDefaults(suiteName: "group.com.claushoefele.T")! func updateObjectForKey<T: NSCoding>(key: String, item:
T) { let data = NSKeyedArchiver.archivedDataWithRootObject(item) defaults.setObject(data, forKey: key) }
WatchKit Extension iOS App Signalling
func sendDarwinNotification(identifier: String) { let darwinNotificationCenter = CFNotificationCenterGetDarwinNotifyCenter() CFNotificationCenterPostNotification(darwinNotificationCenter, identifier,
nil, nil, 1); } CFNotificationCenterAddObserver
Data Sync
“A WatchKit app complements your iOS app; it does not
replace it.” –Apple Watch HIG
“Anything that could show the user a progress spinner (however
briefly) is a failure on my part.” –David Smith
“[…] many of us — developers included — are still figuring out how
this device fits into daily life […]” –M.G. Siegler
Practical WatchKit Development @claushoefele http://slack.fiveminutewatchkit.com