Had to recast Boolean to String from shared prefs to match the library I'm using, but it works. The timer restarts if the preference is checked.