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
1ヶ月でAndroidカメラアプリ開発(2/4)
Search
sakebook
April 04, 2016
Programming
0
1k
1ヶ月でAndroidカメラアプリ開発(2/4)
Adobe Creative SDKを使った写真加工アプリの開発のスライドです。全4回。
sakebook
April 04, 2016
Tweet
Share
More Decks by sakebook
See All by sakebook
私とスクラム私とコミュニティ私とOST
sakebook
0
37
目指せKotlin 100%
sakebook
1
2.3k
Make full use of Chrome Custom Tabs
sakebook
3
3.1k
Chrome Custom Tabsを使いこなそう
sakebook
1
2.4k
1ヶ月でAndroidカメラアプリ開発(1/4)
sakebook
1
1.8k
1ヶ月でAndroidカメラアプリ開発(3/4)
sakebook
0
990
1ヶ月でAndroidカメラアプリ開発(4/4)
sakebook
0
950
Other Decks in Programming
See All in Programming
Outline View in SwiftUI
1024jp
1
160
EventSourcingの理想と現実
wenas
6
2.1k
Generative AI Use Cases JP (略称:GenU)奮闘記
hideg
0
160
qmuntal/stateless のススメ
sgash708
0
120
Synchronizationを支える技術
s_shimotori
1
150
飲食業界向けマルチプロダクトを実現させる開発体制とリアルな現状
hiroya0601
1
400
PLoP 2024: The evolution of the microservice architecture pattern language
cer
PRO
0
1.7k
Kaigi on Rails 2024 - Rails APIモードのためのシンプルで効果的なCSRF対策 / kaigionrails-2024-csrf
corocn
5
3.4k
Vue3の一歩踏み込んだパフォーマンスチューニング2024
hal_spidernight
3
3.1k
GCCのプラグインを作る / I Made a GCC Plugin
shouth
1
150
AWS IaCの注目アップデート 2024年10月版
konokenj
3
3.1k
2万ページのSSG運用における工夫と注意点 / Vue Fes Japan 2024
chinen
3
1.3k
Featured
See All Featured
Keith and Marios Guide to Fast Websites
keithpitt
408
22k
Six Lessons from altMBA
skipperchong
26
3.5k
Build your cross-platform service in a week with App Engine
jlugia
229
18k
Building Better People: How to give real-time feedback that sticks.
wjessup
363
19k
Gamification - CAS2011
davidbonilla
80
5k
How to Think Like a Performance Engineer
csswizardry
19
1.1k
Practical Orchestrator
shlominoach
186
10k
jQuery: Nuts, Bolts and Bling
dougneiner
61
7.5k
No one is an island. Learnings from fostering a developers community.
thoeni
19
3k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
27
4.2k
Performance Is Good for Brains [We Love Speed 2024]
tammyeverts
3
370
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
280
13k
Transcript
̍ϲ݄Ͱ ANDROIDΧϝϥΞϓϦ։ൃ @Trunk ञຊ৳ 2016/3/20
ຊͷྲྀΕ • ϨΠΞτͷجຊࣝ • ActivityͷϥΠϑαΠΫϧ • ΠϕϯτϋϯυϦϯά • Widgetͷঢ়ଶཧ •
(Χϝϥݺͼग़͠) • (ը૾ड͚औΓ) • Aviaryઃఆ
ACTIVITY
ACTIVITY ≒ ը໘ • ActivityUIΛ࣋ͭը໘ʹඞਢ • ը໘xmlͰ࡞Δ • ಈతʹੜ͍ͨ͠ͷίʔυͰఆٛ •
ը໘Λߏ͢Δxml ϨΠΞτͱΟδΣοτͰΓཱͭ
LAYOUT
LAYOUT • WidgetViewΛҰఆͷنଇʹج͖ͮஔ͢Δ ͨΊͷͷ • ҰͭͷxmlʹϨΠΞτෳ͋ͬͯྑ͍ • ͷϨΠΞτඞͣҰͭ
͍͔ͭ͘հ • LinearLayout • ্͔ΒԼɺࠨ͔ΒӈͳͲɺॱংʹ٧Ίͯஔ͢ΔϨΠΞτ • RelativeLayout • ஔͨ͠ଞͷίϯϙʔωϯτͱͷҐஔؔΛఆٛ͠ͳ͕Β ஔ͢ΔϨΠΞτ
• FrameLayout • ࠨ্Λىͱͯ͠ɺࢠཁૉͰ͋Δͱ͖ લ໘ʹදࣔ͞ΕΔϨΠΞτ
XMLͷઃఆ • setContentView(Int id)
• εςʔλεόʔ • ΞΫγϣϯόʔ (πʔϧόʔ) • φϏήʔγϣϯόʔ ϨΠΞτ෦
None
None
WIDGET
WIDGET
ߴසग़ • Button • ϘλϯΛஔ͍ͨ͠ͱ͖ʹ͏ • TextView • ܾΊΒΕͨจࣈΛஔ͍ͨ͠ͱ͖ʹ͏ •
ImageView • ը૾Λද͍ࣔͨ͠ͱ͖ʹ͏
࣮श • ͕ࣗ࡞Γ͍ͨΞϓϦͷϨΠΞτΛߟ͑ ࣮ͯ͠ΈΔ
ϥΠϑαΠΫϧ
ϥΠϑαΠΫϧ • Activityಉ࢜ͷԁͳΓऔΓΛॿ͢Δ • ෳͷActivity • ϥΠϑαΠΫϧ ≒ ঢ়ଶભҠ
None
• onCreate • Activity͕ॳΊͯ ࡞ΒΕͨͱ͖ • onStart • Activity͕Ϣʔβʹ ݟ͑ΔΑ͏ʹͳΔલ
• onResume • Activity͕ දࣔ͞Εͨͱ͖ • onPause • ผͷActivity͕ දࣔ͞ΕΔͱ͖
• onStop • Activity͕ ݟ͑ͳ͘ͳͬͨ࣌ • onRestart • Activity͕ఀࢭͨ͠ޙ ࠶։࢝͞ΕΔલ
• onDestroy • Activity͕ ഁغ͞ΕΔલ • Activity͕ड͚औΔ ࠷ޙͷݺͼग़͠
ৄࡉ • http://dev.classmethod.jp/smartphone/android/ android-tips-21-activity-lifecycle/
ΠϕϯτϋϯυϦϯά
ΠϕϯτϋϯυϦϯά • Πϕϯτ • ϢʔβͷԿ͔͠Βͷߦಈ ෦ͷॲཧͷಛఆͷλΠϛϯά • ΠϕϯτΛదͳλΠϛϯάͰΩϟον͠ దͳॲཧΛߦ͏ɻ
ϘλϯΛΫϦοΫ • ButtonͷWidgetΛઃஔ • Button͕ΫϦοΫ͞Εͨ࣌ʹߦ͏ॲཧΛهड़ • ButtonͷΫϦοΫΠϕϯτΛϋϯυϦϯά
BUTTONͷWIDGETΛઃஔ • xml
BUTTON͕ΫϦοΫ͞Εͨ࣌ ʹߦ͏ॲཧΛهड़ • setOnClickListenerʹ࣮Λͯ͋͛͠Δ • Listener = Interface
࣮ ϋϯυϦϯά
ϋϯυϦϯά + ࣮
࣮? ϋϯυϦϯά
ผΫϥεͰ࣮ • MyCustomClick.class
࣮? ϋϯυϦϯά
ಉ͡ΫϥεͰ࣮ • ࣮͕هड़͞Ε͍ͯΔͷͰthis͕͑Δɻ
࣮͠·͢એݴ
SET_ON_CLICKҎ֎ͷϦεφʔ • setOn̋̋Ͱ༻ҙ͞Ε͍ͯΔɻ • ొ/ղআ͕ඞཁͳͷ add/remove register/unregister ͳͲɺ໋໊نଇͰผͰ͖Δ
࣮श • ͕ࣗ࡞Γ͍ͨΞϓϦͷ͍͔ͭ͘ͷwidgetͰ ΠϕϯτϋϯυϦϯάΛઃఆ͢Δ
WIDGETͷঢ়ଶ
BUTTON͕ΫϦοΫ͞Εͨ࣌ • ͳΜͲΫϦοΫͰ͖Δ • ΫϦοΫͰ͖͔ͨͲ͏͔Θ͔Βͳ͍ • ΫϦοΫՄೳͳঢ়ଶ͔ෆ໌
ͳΜͲΫϦοΫͰ͖Δ • ϝʔϧΛૹΔͳͲɺෳճ͞ΕͯࠔΔͷ ͕͋Δ • View#setEnabled(boolean) • Viewͷঢ়ଶΛɺ༗ޮ/ແޮʹ͢Δ
ΫϦοΫͰ͖͔ͨͲ͏͔ Θ͔Βͳ͍ ΫϦοΫՄೳͳঢ়ଶ͔ෆ໌ • ϢʔβʹϑΟʔυόοΫΛ༩͑Δ
ແޮͳঢ়ଶ ༗ޮͰ ԡ͞Ε͍ͯΔঢ়ଶ ༗ޮͰ ԡ͞Εͯͳ͍ঢ়ଶ
AVIARY
AVIARY • ΤσΟλʔػೳผSDK • https://creativesdk.adobe.com/docs/android/ #/articles/imageediting/index.html • Ұॹʹ͍͖ͬͯ·͠ΐ͏ɻ