https://github.com/m1ga/ti.mediacontrol
Android Media control: notification and lock-screen audio player for Titanium SDK
https://github.com/m1ga/ti.mediacontrol
android audio lockscreen player titanium-module titanium-sdk
Last synced: 22 days ago
JSON representation
Android Media control: notification and lock-screen audio player for Titanium SDK
- Host: GitHub
- URL: https://github.com/m1ga/ti.mediacontrol
- Owner: m1ga
- License: other
- Created: 2022-08-29T19:29:27.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2024-04-12T07:17:32.000Z (about 2 years ago)
- Last Synced: 2025-01-27T07:12:02.788Z (over 1 year ago)
- Topics: android, audio, lockscreen, player, titanium-module, titanium-sdk
- Language: Java
- Homepage:
- Size: 1.94 MB
- Stars: 1
- Watchers: 1
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# Android Media control: notification and lock-screen audio player for Titanium SDK

## Installation
* download the module from [dist](https://github.com/m1ga/ti.mediacontrol/tree/main/android/dist)
* put the ZIP into you project root
* add `ti.mediacontrol` to your tiapp.xml `` section.
## Methods
* createPlayer(options): creates a new player + notification.
Options:
* showNext: show the next button
* showPrevious: show the previous button
* title: first row (title)
* text: second row (text)
* backgroundImage: background image of the player
* close(): close the player/dismiss the notification.
* updateInfo({title: "", text: ""}): change both strings at the same time
* play(): puts the player into play mode
* pause(): puts the player into pause mode
* setMetadata(options): sets the track metadata
Options:
* title: Text
* artist: Text
* album: Text
## Properties
* backgroundImage: change the background image of the player
* title: change the first row (title)
* text: change the second row (text)
## Constants
* PLAY
* PAUSE
* NEXT
* PREVIOUS
## Events
* changeStatus: is fired when the status of the player changes. It will return `status` with one of the constants.
## Example
check [examples/app.js](https://github.com/m1ga/ti.mediacontrol/tree/main/example) for a full example.
## License
MIT
## Author
* Michael Gangolf