1<?xml version="1.0" encoding="utf-8"?> 2<!-- 3 ~ Copyright (C) 2024 The Android Open Source Project 4 ~ 5 ~ Licensed under the Apache License, Version 2.0 (the "License"); 6 ~ you may not use this file except in compliance with the License. 7 ~ You may obtain a copy of the License at 8 ~ 9 ~ http://www.apache.org/licenses/LICENSE-2.0 10 ~ 11 ~ Unless required by applicable law or agreed to in writing, software 12 ~ distributed under the License is distributed on an "AS IS" BASIS, 13 ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 14 ~ See the License for the specific language governing permissions and 15 ~ limitations under the License. 16 --> 17 18<MotionScene xmlns:android="http://schemas.android.com/apk/res/android" 19 xmlns:app="http://schemas.android.com/apk/res-auto"> 20 21 <Transition 22 android:id="@+id/transition_primary" 23 app:constraintSetStart="@id/expanded_header_primary" 24 app:constraintSetEnd="@id/collapsed_header_primary"> 25 26 <OnSwipe 27 app:dragDirection="dragUp" 28 app:onTouchUp="stop" 29 app:touchAnchorId="@+id/bottom_scroll_view" 30 app:touchAnchorSide="top" /> 31 </Transition> 32 33 <ConstraintSet android:id="@+id/expanded_header_primary"> 34 35 <Constraint 36 android:id="@+id/preview_header" 37 android:layout_height="@dimen/customization_picker_preview_header_expanded_height" 38 app:layout_constraintEnd_toEndOf="parent" 39 app:layout_constraintStart_toStartOf="parent" 40 app:layout_constraintTop_toTopOf="parent" /> 41 </ConstraintSet> 42 43 <ConstraintSet android:id="@+id/collapsed_header_primary"> 44 45 <Constraint 46 android:id="@+id/preview_header" 47 android:layout_height="@dimen/customization_picker_preview_header_collapsed_height" 48 app:layout_constraintEnd_toEndOf="parent" 49 app:layout_constraintStart_toStartOf="parent" 50 app:layout_constraintTop_toTopOf="parent" /> 51 </ConstraintSet> 52 53 <ConstraintSet android:id="@+id/secondary"> 54 55 <Constraint 56 android:id="@+id/preview_header" 57 app:layout_constraintBottom_toTopOf="@+id/preview_guideline_in_secondary_screen" 58 app:layout_constraintEnd_toEndOf="parent" 59 app:layout_constraintStart_toStartOf="parent" 60 app:layout_constraintTop_toTopOf="parent" /> 61 62 <Constraint 63 android:id="@+id/bottom_scroll_view" 64 android:alpha="0.0" 65 app:layout_constraintTop_toBottomOf="@+id/preview_header" 66 app:layout_constraintStart_toStartOf="parent" 67 app:layout_constraintEnd_toEndOf="parent" 68 app:layout_constraintBottom_toBottomOf="parent" /> 69 70 <Constraint 71 android:id="@+id/preview_guideline_in_secondary_screen" 72 app:layout_constraintGuide_end="0dp" /> 73 74 <Constraint 75 android:id="@+id/customization_picker_bottom_sheet" 76 android:alpha="1.0" 77 android:layout_height="wrap_content" 78 android:translationY="0dp" 79 app:layout_constraintStart_toStartOf="parent" 80 app:layout_constraintEnd_toEndOf="parent" 81 app:layout_constraintTop_toBottomOf="parent" /> 82 </ConstraintSet> 83</MotionScene>