GithubHelp home page GithubHelp logo

gss-crd / cordova-plugin-mediacontrol Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mediakitapp/cordova-plugin-mediacontrol

0.0 0.0 0.0 22 KB

Cordova Plugin Media Control

Home Page: https://www.inteapps.com/

License: Apache License 2.0

JavaScript 8.18% Objective-C 36.59% Java 55.24%

cordova-plugin-mediacontrol's Introduction

Cordova Plugin Media Controls

Enable speaker mode and correctly display the multimedia volume when lowering or raising.

Although the object is attached to the global scoped window, it is not available until after the deviceready event.

  • Cordova
document.addEventListener("deviceready", onDeviceReady, false);
function onDeviceReady() {
  console.log(MediaControls);
}
  • Ionic
/* Create interface for working */
window.MediaControls.setModeAudio(...) 

Install Ionic / Cordova

  • Cordova
npm i cordova-plugin-media-control
cordova plugin add cordova-plugin-media-control
  • Ionic
npm i cordova-plugin-media-control
npx cap sync

Permissions Android

<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />

API

setModeAudio(...)

setModeAudio(mode: string) => Promise<{ state: boolean; }>
Param Type Description
mode string Value speaker for active Speaker or normal for disabled

Returns: Promise<{ state: boolean; }>


cordova-plugin-mediacontrol's People

Contributors

mediakitapp avatar vantist avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.