07/18/2022, 10:21 PM
Change background color of fragments dynamically from a switch I am trying to have all fragments change to the background color of red using a SwitchPreferenceCompat but am having trouble writing the listener code and MainActivity code. I have tried some things but am not too familiar with how to write the listener code to be able to write the mainactivity code to use it properly. I am not really looking for a solution but rather being pointed in the right direction. Thank you Here's the relevant code: Preferences xml...