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
Xebia WatchKit TechEvent
Search
Simone Civetta
December 03, 2014
Programming
0
170
Xebia WatchKit TechEvent
Simone Civetta
December 03, 2014
Tweet
Share
More Decks by Simone Civetta
See All by Simone Civetta
2021: CI for Mobile: State of The Art
viteinfinite
0
380
MVI : une architecture robuste et moderne pour vos applications mobiles
viteinfinite
2
530
Cross-Platform Modules with Kotlin/Native (v. 2018.10)
viteinfinite
0
110
Face Recognition with Vision & Core ML
viteinfinite
1
1.1k
Shared Cross-Platform Modules with Kotlin/Native
viteinfinite
1
320
Server-Side Swift @ Devoxx FR
viteinfinite
0
120
Swift on the Raspberry PI
viteinfinite
0
130
Server-Side Swift
viteinfinite
0
84
Be the Quality You Want to See in Your App [Swift Edition]
viteinfinite
1
430
Other Decks in Programming
See All in Programming
エンジニアの「手元の自動化」を加速するn8n 2026.02.27
symy2co
0
160
Claude Code Skill入門
mayahoney
0
390
Rで始めるML・LLM活用入門
wakamatsu_takumu
0
180
AI時代でも変わらない技術コミュニティの力~10年続く“ゆるい”つながりが生み出す価値
n_takehata
2
750
DevinとClaude Code、SREの現場で使い倒してみた件
karia
1
1.1k
Vuetify 3 → 4 何が変わった?差分と移行ポイント10分まとめ
koukimiura
0
140
The Past, Present, and Future of Enterprise Java
ivargrimstad
0
560
Everything Claude Code OSS詳細 — 5層構造の中身と導入方法
targe
0
110
What Spring Developers Should Know About Jakarta EE
ivargrimstad
0
520
AI Assistants for Your Angular Solutions
manfredsteyer
PRO
0
140
Go 1.26でのsliceのメモリアロケーション最適化 / Go 1.26 リリースパーティ #go126party
mazrean
1
400
オブザーバビリティ駆動開発って実際どうなの?
yohfee
3
850
Featured
See All Featured
Ruling the World: When Life Gets Gamed
codingconduct
0
170
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
110
Building Experiences: Design Systems, User Experience, and Full Site Editing
marktimemedia
0
440
The Cost Of JavaScript in 2023
addyosmani
55
9.8k
The Director’s Chair: Orchestrating AI for Truly Effective Learning
tmiket
1
130
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
122
21k
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
38
2.8k
Leo the Paperboy
mayatellez
4
1.5k
DevOps and Value Stream Thinking: Enabling flow, efficiency and business value
helenjbeal
1
150
The Limits of Empathy - UXLibs8
cassininazir
1
260
Product Roadmaps are Hard
iamctodd
PRO
55
12k
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
340
Transcript
None
Développeurs ?
Watch
Le produit
None
Modèles —Sport (349$) —Classic —Edition Versions, 2 tailles : —42mm
(312x390px ~335ppi) —38mm (272x340px ~335ppi)
Personnalisation
OS
Apple Watch et iOS Compatible uniquement avec iOS 8.2+
Interface
Interface —1 couronne (digital crown) —sélection —zoom in/out —1 bouton
physique (conversation button) —favoris — Pay
Interface —Siri
Interface —Feedback haptique
Interface graphique
Interface graphique —Home screen —Glances —Applications
Home screen
Glances
Capteurs —Accéleromètre —Gyroscope —GPS —Moniteur cardiaque
Pay
Batterie —~1 jour environ —rechargement avec connecteur magnétique
Date de sortie —Printemps 2015 —(St Valentin ?)
None
Le SDK —Première release le 18 nov. 2014 —Deuxième version
en mi-2015 (WWDC ?)
Les fonctionnalités —Gérer notifications —Écrans glances —Applications non natives1 1
La logique est exécutée sur l'iPhone
Les fonctionnalités / 2 —Applications natives en V2
WatchKit en détail
Aujourd'hui... Une application WatchKit est : —une extension d'une application
iPhone —un écran secondaire
Pour commencer : glossaire —Watch App : executé sur la
montre —Extension : executé sur iPhone
Extensions iOS
Extension iOS / 1
Extension iOS / 2 —L'extension est un applicatif indépendant contenu
dans le bundle d'un .app iOS
Architecture
Architecture / 1 —La Watch App est lancée depuis un
bundle contenant storyboard et ressources statiques
Architecture / 2 —L'interaction de l'utilisateur déclenche l'exécution de code
dans l'extension
None
Interface utilisateur
Interface utilisateur / 1 —L'interface est réalisable seulement via Storyboard
—L'IHM est installée dans la Watch App
Interface utilisateur / 2 —Les Scenes du Storyboard ne peuvent
pas être modifiées par l'extension iPhone à runtime —L'extension peut afficher/cacher des éléments à l'intérieur de la Watch App
Les composants
Les composants / 1 —Les composants WatchKit (buttons, labels, etc)
sont proxifiés —L'extension manipule un objet proxy (WKInterface*) —Il n'est pas possible de créer programmatiquement des éléments visuels
Les composants / 2 —Une extension peut contrôler : —Taille
(Height/Width) —Alpha —Visibilité (propriété hidden) —Hidden = Gone
Les composants / 3 —WKInterfaceController —WKInterfaceGroup —WKInterfaceTable —WKInterfaceButton —WKInterfaceDate —WKInterfaceImage
—WKInterfaceLabel —WKInterfaceMap —WKInterfaceSeparator —WKInterfaceSlider
Les composants / 3 —WKInterfaceController —WKInterfaceGroup —WKInterfaceTable —WKInterfaceButton —WKInterfaceDate —WKInterfaceImage
—WKInterfaceLabel —WKInterfaceMap —WKInterfaceSeparator —WKInterfaceSlider
WKInterfaceController —Équivalent de UIViewController —Un controlleur par écran —Target/Action pattern
—Peu modulaire —Context-based
WKInterfaceController Context —init(context context: AnyObject!) — contextForSegueWithIdentifier(_ :) —pushControllerWithName(_ name:
String!, context context: AnyObject!)
Cycle de vie —WA : Create Storyboard —E : initWithContext:
—E : willActivate —E : action methods —E : didDeactivate
None
WKInterfaceGroup —cf. Layout sur Android —Horizontaux/Verticaux —Taille paramétrable, qui peut
dépendre du contenu/conteneur —Fit content —Relative to container
WKInterfaceTable —Similaires aux tableaux de iOS —Pas de sections /
footers / headers
WKInterfaceTable —Chaque row est associée à un type de row
(rowType) —Chaque rowType est associé à un controller —setNumberOfRows(_:withRowType:) —setRowTypes(_ rowTypes: [AnyObject]!) —table(_ table: WKInterfaceTable!, didSelectRowAtIndex rowIndex:
WKInterfaceTable Toutes les méthodes de délégation de la Table sont
déclarées dans le Controller
None
WKInterfaceMap —Plan statique qui peut contenir max 5. annotations —Dessiné
par l'extension et envoyé ensuite à la Watch App
WKInterfaceDate —Libellé de date avec format paramétrable —La valeur est
calculée directement par la Watch App
Navigation
Navigation —Pop/Push (cf. UINavigationController) —Page-based —Présentation modale
Navigation techniques —Segues —pushControllerWithName(_ name: String!, context context: AnyObject!) —
presentControllerWithName(_:con text:) — presentControllerWithNames(_:co ntexts:)
Notes
Glances —Un écran Glance est une micro- application mono-page —Il
est le launcher d'une application Watch App
Storyboard —Le storyboard est l'outil de définition de l'interface utilisateur
d'une Watch App
Tips 'n Tricks —Utilisez les frameworks dynamiques —Modifiez les propriétés
des Schemes —Activez le mode "External display -> Apple Watch" dans le menu du simulateur
Hands on !