title: How to share object for all app's activities
body: <p>I have an animation that I want to apply on every button in my app. So I don't want to call AnimationUtils.loadAnimation() in every activity onCreate method. I would like to call this method only one time when the app is launched to initialize my animation object, and then get it (with a getter) in my different activities.
  I'm new in Android programming, I was planning to use a Singleton pattern but it looks like to be &quot;unsafe&quot; in Android related to this article and other Stackoverflow pages. (<a href="https://programmerr47.medium.com/singletons-in-android-63ddf972a7e7" rel="nofollow noreferrer">https://programmerr47.medium.com/singletons-in-android-63ddf972a7e7</a>)</p>
  <p>Is there anyway to create my Animation at app launching and share it between every activity ?  And does it worth to do some optimization ?</p>