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
760
Other Decks in Technology
See All in Technology
Amazon Kendra GenAI Index 登場でどう変わる? 評価から学ぶ最適なRAG構成
naoki_0531
0
110
宇宙ベンチャーにおける最近の情シス取り組みについて
axelmizu
0
110
Snykで始めるセキュリティ担当者とSREと開発者が楽になる脆弱性対応 / Getting started with Snyk Vulnerability Response
yamaguchitk333
2
180
Opcodeを読んでいたら何故かphp-srcを読んでいた話
murashotaro
0
190
オプトインカメラ:UWB測位を応用したオプトイン型のカメラ計測
matthewlujp
0
170
Wantedly での Datadog 活用事例
bgpat
1
440
AWS re:Invent 2024 ふりかえり
kongmingstrap
0
130
LINEヤフーのフロントエンド組織・体制の紹介【24年12月】
lycorp_recruit_jp
0
530
Amazon VPC Lattice 最新アップデート紹介 - PrivateLink も似たようなアップデートあったけど違いとは
bigmuramura
0
190
新機能VPCリソースエンドポイント機能検証から得られた考察
duelist2020jp
0
220
MLOps の現場から
asei
6
640
WACATE2024冬セッション資料(ユーザビリティ)
scarletplover
0
200
Featured
See All Featured
How GitHub (no longer) Works
holman
311
140k
Bash Introduction
62gerente
608
210k
[RailsConf 2023] Rails as a piece of cake
palkan
53
5k
Principles of Awesome APIs and How to Build Them.
keavy
126
17k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
127
18k
Into the Great Unknown - MozCon
thekraken
33
1.5k
The Art of Programming - Codeland 2020
erikaheidi
53
13k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
2
170
Gamification - CAS2011
davidbonilla
80
5.1k
Adopting Sorbet at Scale
ufuk
73
9.1k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
6
520
jQuery: Nuts, Bolts and Bling
dougneiner
61
7.5k
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ΞϓϦ୯ମͰମݧΛಧ͚Δඞཁ͕͋Δ
࣭ٙԠ