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
Gunosy for Apple Watchができるまで
Search
Yusuke Kawanabe
May 27, 2015
Technology
6
820
Gunosy for Apple Watchができるまで
GunosyのGlance画面を作るために作ったライブラリ
https://github.com/jeffsuke/GlanceWordRainbowImage
Yusuke Kawanabe
May 27, 2015
Tweet
Share
More Decks by Yusuke Kawanabe
See All by Yusuke Kawanabe
Presentation with Coordinators
ykawanabe
4
750
Other Decks in Technology
See All in Technology
SREが投資するAIOps ~ペアーズにおけるLLM for Developerへの取り組み~
takumiogawa
1
420
安心してください、日本語使えますよ―Ubuntu日本語Remix提供休止に寄せて― 2024-11-17
nobutomurata
1
1k
Platform Engineering for Software Developers and Architects
syntasso
1
520
TanStack Routerに移行するのかい しないのかい、どっちなんだい! / Are you going to migrate to TanStack Router or not? Which one is it?
kaminashi
0
600
Exadata Database Service on Dedicated Infrastructure(ExaDB-D) UI スクリーン・キャプチャ集
oracle4engineer
PRO
2
3.2k
CysharpのOSS群から見るModern C#の現在地
neuecc
2
3.5k
ドメインの本質を掴む / Get the essence of the domain
sinsoku
2
160
B2B SaaSから見た最近のC#/.NETの進化
sansantech
PRO
0
880
[CV勉強会@関東 ECCV2024 読み会] オンラインマッピング x トラッキング MapTracker: Tracking with Strided Memory Fusion for Consistent Vector HD Mapping (Chen+, ECCV24)
abemii
0
220
複雑なState管理からの脱却
sansantech
PRO
1
150
10XにおけるData Contractの導入について: Data Contract事例共有会
10xinc
6
660
『Firebase Dynamic Links終了に備える』 FlutterアプリでのAdjust導入とDeeplink最適化
techiro
0
130
Featured
See All Featured
The Power of CSS Pseudo Elements
geoffreycrofte
73
5.3k
A Modern Web Designer's Workflow
chriscoyier
693
190k
Distributed Sagas: A Protocol for Coordinating Microservices
caitiem20
329
21k
Large-scale JavaScript Application Architecture
addyosmani
510
110k
Learning to Love Humans: Emotional Interface Design
aarron
273
40k
Building Your Own Lightsaber
phodgson
103
6.1k
Reflections from 52 weeks, 52 projects
jeffersonlam
346
20k
Product Roadmaps are Hard
iamctodd
PRO
49
11k
The World Runs on Bad Software
bkeepers
PRO
65
11k
Music & Morning Musume
bryan
46
6.2k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
169
50k
A better future with KSS
kneath
238
17k
Transcript
Gunosy for Apple Watch ͕Ͱ͖Δ·Ͱ גࣜձࣾGunosyɹ։ൃຊ෦ ᬒ༤հ
@jeffsuke iOS App Developer https://github.com/jeffsuke ࠓͷWWDC ҆શͳҬʹധ·Εͦ͏Ͱ͢
WWDC2014ʹ͓͚Δ@jeffsuke॓ധઌۙ
SFةݥͳҬϚοϓ ֎লϗʔϜϖʔδΑΓ
Gunosy • ใΩϡϨʔγϣϯαʔϏε • 900ສμϯϩʔυ • ࣾһͷඪ४ݴޠGoΒ͍͠
֓ཁ • Apple Watch্ͰշదͳମݧΛ࣮ݱ͢Δ·Ͱؤ ுͬͨ
࣍ • Apple WatchΞϓϦ֓ཁ • Watch Appͷ࠷దԽ • Glanceͷ࠷దԽ •
ਃޙͷ
Gunosy for Apple WatchͰग़དྷΔ͜ͱ Glance Watch app
Apple WatchΞϓϦ ΞϓϦຊମ Extension Watch app Storyboard Image assets Controller,
Model Setter UIEvent
Apple WatchΞϓϦͷΈ • ՄೳͳݶΓը૾Apple Watchଆʹอଘ͓ͯ͘͠ • ද͍ࣔͯ͠Δviewͷใऔಘग़དྷͳ͍
Watch Appʹ͓͚Δ࠷దԽ
Gunosyʹ͓͚ΔWatch App • Alamofire • SwiftyJSON • API͔Βड͚औͬͨͷใΛݩʹ هࣄΛදࣔɻৄࡉϖʔδͰɺຊମʹ อଘɺຊମͰ։͘ࣄ͕Ͱ͖Δɻ
• ඳը·ͰΛ࠷ʹ͢Δ • iPhoneͱAppleWatchͷ௨৴ΛݮΒ͢ • อଘग़དྷΔͷอଘ͢Δ ϙΠϯτ ֓ཁ
willActivate()ͷ׆༻ • initͱawakeͰͷॲཧΛ࠷খݶʹ 1. Watch App͕ݺͼग़͞ΕΔ 2. Storyboard͕ಡΈࠐ·ΕΔ 3. ରը໘ͷinit,
awake͕Δ 4. Watch্Ͱը໘͕දࣔ͞ΕΔ 5. willActivate()͕ݺΕΔ ىಈ·Ͱͷखॱ
willActivate()ͷ׆༻
WKInterfaceGroupͷར༻ • Placeholderͱͯ͠ • ؙ֯
addCachedImage • BLEͷҝ௨৴ʹ੍ݶ͕͋ΔɻՄೳͳݶΓ࠶ར༻͢Δը૾ Ωϟογϡ • ֤ΞϓϦ5MB·ͰΩϟογϡՄೳ • kiavashfaisali/KFSwiftImageLoaderͱ͔͏ͱศརͬΆ͍ ࢀߟɿ https://developer.apple.com/library/ios/documentation/General/Conceptual/WatchKitProgrammingGuide/Images.html
http://qiita.com/_tid_/items/55667b00ce158a28428a
addCachedImage ಡΈࠐΈ อଘ
Watch Appʹ͓͚Δ࠷దԽ • ϥΠϑαΠΫϧΛΓඳըՄೳͳ͔Βॱ࣍ඳը ͢Δ • ը૾ՄೳͳݶΓWatchຊମʹ
Glanceʹ͓͚Δ࠷దԽ
Gunosyʹ͓͚ΔGlance • API͔Βड͚औͬͨͷใΛݩʹ ը૾Λදࣔɻ࣌ܭ̍ը໘Ͱχϡʔε͕ ͔Δମݧɻ • ਓʹݟͤͯࣗຫͨ͘͠ͳΔػೳ Glance • ಡΈࠐΈ·Ͱͷ͕࣌ؒϙΠϯτ
• ͻͱͰ͔ΔUI ϙΠϯτ ֓ཁ
ՄೳͳݶΓΩϟογϡ͢Δ • ڞ௨ͷAppGroupΛઃఆ͠ɺNSUserDefault ͰඞཁͳσʔλΛڞ༗ͨ͠ɻ • [[NSUserDefaults alloc] initWithSuiteName:@“group.mycompany.my app"] App
Group ը૾Ωϟογϡ • addCachedImage
ຊମͰը૾Λੜ͢Δ
ຊମͰը૾Λੜ͢Δ
GithubͰެ։͍ͯ͠·͢ • https://github.com/jeffsuke/GlanceWordRainbowImage
Glanceʹ͓͚Δ࠷దԽ • ը૾ʹඳը͢Δ͜ͱͰෳࡶͳදݱΛ࣮ݱ • ՄೳͳݶΓը૾ΛΩϟογϡ͓ͯ͘͠
ਃޙͷ
ϦδΣΫτͷ • ൃചͰ͋Δ4/24Λࢦͯ͠։ൃ • ͔͠͠ೋͷϦδΣΫτ • ೋͷమΛ౿·ͳ͍Tips
ϦδΣΫτࣄྫ̍ • Watch appΛ͏લʹҰiPhoneͷ ىಈΛཁٻ͠ɺϦδΣΫτɻ • Υον୯ମͰҙຯͷ͋ΔػೳΛఏ ڙͰ͖͍ͯͳ͍ҝɺຊମΞϓϦͰೝ ূΛ࣮ߦ͢Δ͜ͱʹɻ •
ͨͩ͠ɺJALUberϩάΠϯΛཁ ٻ͢ΔΞϓϦଘࡏ͢ΔͷͰɺϩά ΠϯͳΒྑ͍ͷ͔ɻ
ϦδΣΫτࣄྫ̎ • iPhoneͰಡΉϘλϯΛԡͯ͠ WatchΞϓϦͰͷมԽ͕ͳ͍ͨΊϦ δΣΫτɻ • openParentApplication:reply:Λ༻͍ ͯ։͍͔ͨͲ͏͔Λฦ͢ มߋલ มߋޙ
ϦδΣΫτࣄྫ̎ Watchଆ ຊମଆ
ϦδΣΫτͷ·ͱΊ • Apple Watch୯ମͰମݧ͕Γཱ͍ͬͯΔඞཁ͕ ͋Δ
Apple Watch·ͱΊ • Apple WatchΞϓϦόΠφϦʹՄೳͳݶΓViewؔ ࿈ͷཁૉΛؚΊ͓ͯ͘ • ෳࡶͳॲཧExtensionɺ͕͔͔࣌ؒΔॲཧຊ ମΞϓϦͰ࣮ࢪ •
WatchΞϓϦ୯ମͰମݧΛಧ͚Δඞཁ͕͋Δ
࣭ٙԠ