setCurrentSourceForMediaType method

void setCurrentSourceForMediaType(
  1. {required MediaType mediaType,
  2. required MediaSource mediaSource}
)

For a given MediaType, set the selected media source.

Implementation

void setCurrentSourceForMediaType({
  required MediaType mediaType,
  required MediaSource mediaSource,
}) {
  _preferences.put(
      'current_source/${mediaType.uniqueKey}', mediaSource.uniqueKey);
}