ui: tweak bottom sheet dialog transitions
Use a native slide animation for entering/editing bottom sheet dialogs, which looks a good amount nicer overall.
This commit is contained in:
@@ -0,0 +1,25 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
~ Copyright (C) 2018 The Android Open Source Project
|
||||
~
|
||||
~ Licensed under the Apache License, Version 2.0 (the "License");
|
||||
~ you may not use this file except in compliance with the License.
|
||||
~ You may obtain a copy of the License at
|
||||
~
|
||||
~ http://www.apache.org/licenses/LICENSE-2.0
|
||||
~
|
||||
~ Unless required by applicable law or agreed to in writing, software
|
||||
~ distributed under the License is distributed on an "AS IS" BASIS,
|
||||
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
~ See the License for the specific language governing permissions and
|
||||
~ limitations under the License.
|
||||
-->
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:duration="@integer/m3_sys_motion_duration_medium4"
|
||||
android:interpolator="@interpolator/m3_sys_motion_easing_emphasized">
|
||||
|
||||
<translate
|
||||
android:fromYDelta="100%p"
|
||||
android:toYDelta="0"/>
|
||||
|
||||
</set>
|
||||
@@ -0,0 +1,10 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<set xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<translate
|
||||
android:duration="@integer/m3_sys_motion_duration_medium3"
|
||||
android:interpolator="@interpolator/m3_sys_motion_easing_emphasized"
|
||||
android:fromYDelta="0"
|
||||
android:toYDelta="100%p"/>
|
||||
|
||||
</set>
|
||||
@@ -50,7 +50,13 @@
|
||||
</style>
|
||||
|
||||
<style name="Widget.Auxio.BottomSheet.Dialog" parent="ThemeOverlay.Material3.BottomSheetDialog">
|
||||
<item name="bottomSheetStyle">@style/Widget.Auxio.BottomSheet.Modal</item>
|
||||
<item name="bottomSheetStyle">@style/Widget.Auxio.BottomSheet.Modal</item>
|
||||
<item name="android:windowAnimationStyle">@style/Animation.Auxio.BottomSheet.Dialog</item>
|
||||
</style>
|
||||
|
||||
<style name="Animation.Auxio.BottomSheet.Dialog" parent="Animation.Material3.BottomSheetDialog">
|
||||
<item name="android:windowEnterAnimation">@anim/bottom_sheet_slide_in</item>
|
||||
<item name="android:windowExitAnimation">@anim/bottom_sheet_slide_out</item>
|
||||
</style>
|
||||
|
||||
<style name="Widget.Auxio.Image.Small" parent="">
|
||||
|
||||
Reference in New Issue
Block a user