code: public final void restoreDefaults() {
          SharedPreferences sharedPreferences = getPreferenceManager().getSharedPreferences();
  
          if (getPreferenceScreen() != null) {
              restoreDefaults(getPreferenceScreen(), sharedPreferences);
          }
      }
docs: Restores the default values of all preferences, which are contained by the fragment.