title: Change and apply theme at runtime in Android
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/2482848/how-to-change-current-theme-at-runtime-in-android">How to change current Theme at runtime in Android</a>  </p>
  </blockquote>
  
  
  
  <p>I have an Android application where I allow users to switch between themes at runtime. Switching a theme is easy but <a href="https://developer.android.com/reference/android/view/ContextThemeWrapper.html#setTheme%28int%29" rel="nofollow noreferrer">the theme isn't applied until the activity is recreated.</a> I found a way to <a href="https://stackoverflow.com/questions/9446193/theme-programmatically-set-how-to-reload-activity-to-apply">apply the theme to current activity</a> but if the user presses back button previous screens still have the old theme. How can I change theme for those activities? Example of app that supports it: <a href="https://play.google.com/store/apps/details?id=ch.teamtasks.tasks&amp;hl=en" rel="nofollow noreferrer">Tasks Free</a></p>