I am currently working on a media player streamer project, and to facilitate keeping track of the current song, current progression, playlist, etc, I thought about creating a static class with those fields so I can update them from anywhere, including my Service, and also access the updated values from everywhere else.
My question is: is such approach a bad practice?
Just as extra information, I have a fragment that upon a track is selected, opens a DialogFragment with a media player. The user can close the DialogFragment, but the song will still play. Later on, the user can either select the same song or click on the "now playing" button, and the DialogFragment SHOULD resume where the song currently is. Right now it doesn't do that... Therefore, I thought about the above scenario.
If that is indeed bad practice, how would you guys normally handle this type of situation?
Thanks! =]