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
MotionLayout in 5min
Search
itome
October 09, 2018
Programming
160
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
MotionLayout in 5min
itome
October 09, 2018
More Decks by itome
See All by itome
今日始め るCloudflare Browser Rendering
itome
2
340
Android accessibility and automated check tools
itome
1
5.1k
Accessibility in CATS
itome
4
2.5k
Introduce_Owl.pdf
itome
0
120
Introducing Android Accessibility Test with Accessibility Testing Framework
itome
1
800
Introduction of accessibility for mobile development
itome
0
260
Architecture_for_mobile_development.pdf
itome
0
280
Android_Accessibility_Suite.pdf
itome
0
170
Introducing Owl
itome
0
1.2k
Other Decks in Programming
See All in Programming
過去最大のMCPアップデート! 2026-07-28 RC版の謎に迫る
licux
6
320
さぁV100、メモリをお食べ・・・
nilpe
0
140
A2UI という光を覗いてみる
satohjohn
1
130
軽量Java基盤の設計 DIコンテナに頼らない、長期保守と1秒起動の実現 JJUG CCC 2026 Spring
macha64
0
510
LLM本来の能力を解き放つサンドボックス技術とAI民主化への適用
yukukotani
3
3.9k
AIで効率化できた業務・日常
ochtum
0
130
メソッドのジェネリクスでGoの夢は広がるか? / Kyoto.go #65
utgwkk
3
760
OSもどきOS
arkw
0
560
AIだと陥りがちなJakarta EE最新技術への移行時の落とし穴と解決策
tnagao7
0
110
Spec Driven Development | AI Summit Lisbon
danielsogl
PRO
0
190
ふつうのFeature Flag実践入門
irof
7
3.9k
そのテスト、説明できますか?~LWテスト戦略FW~のご紹介
nakahara
0
120
Featured
See All Featured
Building Adaptive Systems
keathley
44
3.1k
Darren the Foodie - Storyboard
khoart
PRO
3
3.4k
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
The Power of CSS Pseudo Elements
geoffreycrofte
82
6.3k
jQuery: Nuts, Bolts and Bling
dougneiner
66
8.5k
Collaborative Software Design: How to facilitate domain modelling decisions
baasie
1
250
The SEO identity crisis: Don't let AI make you average
varn
0
490
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
508
140k
Making Projects Easy
brettharned
120
6.7k
First, design no harm
axbom
PRO
2
1.2k
Noah Learner - AI + Me: how we built a GSC Bulk Export data pipeline
techseoconnect
PRO
0
200
So, you think you're a good person
axbom
PRO
2
2.1k
Transcript
5ͰΘ͔Δ MotionLayout ! https://twitter.com/itometeam " https://github.com/itome # https://medium.com/@itometeam potatotips #55
Takeshi Tsukamoto
1min MotionLayoutͱʁ
1min MotionLayoutͱʁ ɾӈͷΑ͏ͳΞχϝʔγϣϯ͕؆୯ʹ࣮Ͱ͖Δ ɾConstraintLayout2.0.0͔Βಋೖ ɾConstraintLayoutͱಉ༷ʹϨΠΞτΛΜͰɺ ɹMotionSceneͱ͍͏ΞχϝʔγϣϯఆٛϑΝΠϧΛ ɹΛࢦఆ͢Δ͚ͩͰ࣮Ͱ͖Δ
2min MotionLayoutͷ͍ํ
5 2min MotionLayout͍ํ εϫΠϓͰҠಈ͢ΔӈͷΑ͏ͳϨΠΞτ Λ࡞ͬͯΈ·͢ɻ
6 2min MotionLayout͍ํ <?xml version="1.0" encoding="utf-8"?> <android.support.constraint.motion.MotionLayout … app:layoutDescription="@xml/scene_01" tools:showPaths="true">
<View android:id="@+id/button" android:layout_width="64dp" android:layout_height="64dp" android:background="@color/colorAccent" android:text="Button" /> </android.support.constraint.motion.MotionLayout> ConstraintLayoutΛ MotionLayoutʹஔ͖͑ layoutDescriptionʹ sceneϑΝΠϧΛࢦఆ
7 2min MotionLayout͍ํ <?xml version="1.0" encoding="utf-8"?> <MotionScene xmlns:android="http://schemas.android.com/apk/res/android" xmlns:motion="http://schemas.android.com/apk/res-auto"> <Transition
motion:constraintSetEnd="@+id/end" motion:constraintSetStart="@+id/start" motion:duration="1000"> <OnSwipe motion:dragDirection="dragRight" motion:touchAnchorId="@id/button" motion:touchAnchorSide="right" /> </Transition> <ConstraintSet android:id="@+id/start">…</ConstraintSet> <ConstraintSet android:id="@+id/end">…</ConstraintSet> </MotionScene> constraintSetStartͱ constraintSetEndʹ࢝ͱऴͷ ConstraintSetΛࢦఆ ΞχϝʔγϣϯͷτϦΨʔΛ ࢦఆ͢Δ
8 2min MotionLayout͍ํ <ConstraintSet android:id="@+id/start"> <Constraint android:id="@id/button" android:layout_width="64dp" android:layout_height="64dp" android:layout_marginStart="8dp"
motion:layout_constraintBottom_toBottomOf="parent" motion:layout_constraintStart_toStartOf="parent" motion:layout_constraintTop_toTopOf="parent" /> </ConstraintSet> <ConstraintSet android:id="@+id/end"> <Constraint android:id="@id/button" android:layout_width="64dp" android:layout_height="64dp" android:layout_marginEnd="8dp" motion:layout_constraintBottom_toBottomOf="parent" motion:layout_constraintEnd_toEndOf="parent" motion:layout_constraintTop_toTopOf="parent" /> </ConstraintSet> layout_ଐੑͷΈΛࢦఆ͢Δ ※ݩͷϨΠΞτϑΝΠϧʹ ࢦఆͨ͠layout_ଐੑશͯ Ϧηοτ͞ΕΔͷͰҙ
1min ଞʹԿ͕Ͱ͖Δͷʁ
10 1min ଞʹԿ͕Ͱ͖Δʁ ɾlayout_Ҏ֎ͷଐੑΛมߋ͍ͨ͠ →CustomAttributeͰࢦఆͰ͖·͢ʂ
11 1min ଞʹԿ͕Ͱ͖Δʁ ɾ࢝ͱऴҎ֎ͰଐੑΛมߋ͍ͨ͠ →KeyframeͰࢦఆͰ͖·͢ʂ
1min Ͱ͖ͳ͍͜ͱͳ͍ͷʁ
13 1min Ͱ͖ͳ͍͜ͱͳ͍ͷʁ ɾ3ͭҎ্ͷঢ়ଶΛͭϨΠΞτ ɾ૬ରͰભҠ͢ΔΞχϝʔγϣϯ ɾෳํͷυϥοάΛΞχϝʔγϣϯͷτϦΨʔʹ͢Δ ɾଙཁૉҎԼʹΞχϝʔγϣϯΛద༻͢Δ ͜Μͳ͜ͱΛ͍ͨ͠ͱ͖ଞͷΞχϝʔγϣϯ࣮Λݕ౼͠·͠ΐ͏
14 1min Ͱ͖ͳ͍͜ͱͳ͍ͷʁ ݱࡏͷ࠷৽όʔδϣϯ(ConstraintLayout2.0.0-alpha2)Ͱ VisibilityͳͲͷಈతͳมߋ͕Ͱ͖·ͤΜɻ 2.0.0-alpha3Ͱमਖ਼༧ఆΒ͍͠ͷͰͦΕ·Ͱͪ·͠ΐ͏
͋Γ͕ͱ͏͍͟͝·ͨ͠ ! https://twitter.com/itometeam " https://github.com/itome # https://medium.com/@itometeam Takeshi Tsukamoto