aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorScott Jackson <daneren2005@gmail.com>2015-03-10 18:26:33 -0700
committerScott Jackson <daneren2005@gmail.com>2015-03-10 18:26:33 -0700
commitec16b487769752f7bc4c32567bebfc23537fe3c9 (patch)
tree09ba12f8a8d3b7328c35ce2b60172a90a369885e
parent1f3cd08dc8082e23eed1f3ccd88c24614eb897c2 (diff)
downloaddsub-ec16b487769752f7bc4c32567bebfc23537fe3c9.tar.gz
dsub-ec16b487769752f7bc4c32567bebfc23537fe3c9.tar.bz2
dsub-ec16b487769752f7bc4c32567bebfc23537fe3c9.zip
Fade theme change when changed from settings
-rw-r--r--res/anim/fade_in.xml5
-rw-r--r--res/anim/fade_out.xml5
-rw-r--r--src/github/daneren2005/dsub/activity/SubsonicActivity.java1
3 files changed, 11 insertions, 0 deletions
diff --git a/res/anim/fade_in.xml b/res/anim/fade_in.xml
new file mode 100644
index 00000000..c41db065
--- /dev/null
+++ b/res/anim/fade_in.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="utf-8"?>
+<alpha xmlns:android="http://schemas.android.com/apk/res/android"
+ android:duration="500"
+ android:fromAlpha="0.0"
+ android:toAlpha="1.0" /> \ No newline at end of file
diff --git a/res/anim/fade_out.xml b/res/anim/fade_out.xml
new file mode 100644
index 00000000..d615f2a1
--- /dev/null
+++ b/res/anim/fade_out.xml
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="utf-8"?>
+<alpha xmlns:android="http://schemas.android.com/apk/res/android"
+ android:duration="500"
+ android:fromAlpha="1.0"
+ android:toAlpha="0.0" /> \ No newline at end of file
diff --git a/src/github/daneren2005/dsub/activity/SubsonicActivity.java b/src/github/daneren2005/dsub/activity/SubsonicActivity.java
index 20ff568f..e3ade434 100644
--- a/src/github/daneren2005/dsub/activity/SubsonicActivity.java
+++ b/src/github/daneren2005/dsub/activity/SubsonicActivity.java
@@ -137,6 +137,7 @@ public class SubsonicActivity extends ActionBarActivity implements OnItemSelecte
// Make sure to update theme
if (theme != null && !theme.equals(Util.getTheme(this)) || fullScreen != Util.getPreferences(this).getBoolean(Constants.PREFERENCES_KEY_FULL_SCREEN, false)) {
restart();
+ overridePendingTransition(R.anim.fade_in, R.anim.fade_out);
}
populateDrawer();