Skip to content

Latest commit

 

History

History
 
 

audioplayers

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

audioplayers_tizen

pub package

The Tizen implementation of audioplayers.

Usage

This package is not an endorsed implementation of audioplayers. Therefore, you have to include audioplayers_tizen alongside audioplayers as dependencies in your pubspec.yaml file.

dependencies:
  audioplayers: ^5.1.0
  audioplayers_tizen: ^3.0.2

Then you can import audioplayers in your Dart code:

import 'package:audioplayers/audioplayers.dart';

For detailed usage, see https://pub.dev/packages/audioplayers#usage.

Required privileges

To use this plugin in a Tizen application, you may need to declare the following privileges in your tizen-manifest.xml file.

<privileges>
  <privilege>http://tizen.org/privilege/mediastorage</privilege>
  <privilege>http://tizen.org/privilege/externalstorage</privilege>
  <privilege>http://tizen.org/privilege/internet</privilege>
</privileges>
  • The mediastorage privilege (http://tizen.org/privilege/mediastorage) is required to play audio files located in the internal storage.
  • The externalstorage privilege (http://tizen.org/privilege/externalstorage) is required to play audio files located in the external storage.
  • The internet privilege (http://tizen.org/privilege/internet) is required to play any URLs from network.

For detailed information on Tizen privileges, see Tizen Docs: API Privileges.

Supported APIs

  • AudioPlayer.play (AudioContext not supported)
  • AudioPlayer.setAudioContext (not supported)
  • AudioPlayer.setPlayerMode
  • AudioPlayer.pause
  • AudioPlayer.stop
  • AudioPlayer.resume
  • AudioPlayer.release
  • AudioPlayer.seek
  • AudioPlayer.setBalance (not supported)
  • AudioPlayer.setVolume
  • AudioPlayer.setReleaseMode
  • AudioPlayer.setPlaybackRate
  • AudioPlayer.setSource
  • AudioPlayer.setSourceUrl
  • AudioPlayer.setSourceDeviceFile
  • AudioPlayer.setSourceAsset
  • AudioPlayer.setSourceBytes
  • AudioPlayer.getDuration
  • AudioPlayer.getCurrentPosition
  • AudioPlayer.dispose
  • AudioLogger.logLevel (not supported)
  • AudioPlayer.global.setAudioContext (not supported)

Limitations

  • onPlayerComplete event will not be fired when ReleaseMode is set to loop which differs from the behavior specified in the documentation. And playback rate will reset to 1.0 when audio is replayed.
  • setVolume will have no effect on TV devices.