From d03533b9b98cc5acdf4b77ab1aabdc31b27f7ada Mon Sep 17 00:00:00 2001 From: Hermes Junior Date: Thu, 9 Jul 2020 13:38:15 +0200 Subject: [PATCH] Add settings screen animations. --- .../infinityforreddit/Activity/SettingsActivity.java | 1 + app/src/main/res/anim/enter_from_left.xml | 7 +++++++ app/src/main/res/anim/enter_from_right.xml | 7 +++++++ app/src/main/res/anim/exit_to_left.xml | 7 +++++++ app/src/main/res/anim/exit_to_right.xml | 7 +++++++ 5 files changed, 29 insertions(+) create mode 100644 app/src/main/res/anim/enter_from_left.xml create mode 100644 app/src/main/res/anim/enter_from_right.xml create mode 100644 app/src/main/res/anim/exit_to_left.xml create mode 100644 app/src/main/res/anim/exit_to_right.xml diff --git a/app/src/main/java/ml/docilealligator/infinityforreddit/Activity/SettingsActivity.java b/app/src/main/java/ml/docilealligator/infinityforreddit/Activity/SettingsActivity.java index 4a1be2c3..4e59c42b 100644 --- a/app/src/main/java/ml/docilealligator/infinityforreddit/Activity/SettingsActivity.java +++ b/app/src/main/java/ml/docilealligator/infinityforreddit/Activity/SettingsActivity.java @@ -139,6 +139,7 @@ public class SettingsActivity extends BaseActivity implements fragment.setTargetFragment(caller, 0); getSupportFragmentManager().beginTransaction() + .setCustomAnimations(R.anim.enter_from_right, R.anim.exit_to_left, R.anim.enter_from_left, R.anim.exit_to_right) .replace(R.id.frame_layout_settings_activity, fragment) .addToBackStack(null) .commit(); diff --git a/app/src/main/res/anim/enter_from_left.xml b/app/src/main/res/anim/enter_from_left.xml new file mode 100644 index 00000000..63b97c30 --- /dev/null +++ b/app/src/main/res/anim/enter_from_left.xml @@ -0,0 +1,7 @@ + + + + diff --git a/app/src/main/res/anim/enter_from_right.xml b/app/src/main/res/anim/enter_from_right.xml new file mode 100644 index 00000000..81e36503 --- /dev/null +++ b/app/src/main/res/anim/enter_from_right.xml @@ -0,0 +1,7 @@ + + + + diff --git a/app/src/main/res/anim/exit_to_left.xml b/app/src/main/res/anim/exit_to_left.xml new file mode 100644 index 00000000..c7860ef8 --- /dev/null +++ b/app/src/main/res/anim/exit_to_left.xml @@ -0,0 +1,7 @@ + + + + diff --git a/app/src/main/res/anim/exit_to_right.xml b/app/src/main/res/anim/exit_to_right.xml new file mode 100644 index 00000000..0bb959fb --- /dev/null +++ b/app/src/main/res/anim/exit_to_right.xml @@ -0,0 +1,7 @@ + + + +