Skip to content

cordova plugin for detecting or listing installed on the device apps names and app packages

Notifications You must be signed in to change notification settings

leyserkids/installedApps

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Cordova Installed Apps Plugin

Simple plugin that implement following two features:

  • detect special packages whether install on android device
  • returns all of the installed apps, their names and their packages on android devices.
  • check whether the Remote Push Notification is enabled.

##Install

recomended

$ cordova plugin add https://github.com/leyserkids/installedApps.git --save

Using

    var success = function( object ) {
        console.log( object );
    }
  
    var failure = function() {
        alert("Error calling Installed Apps Plugin");
    }

    installedApps.havePackages(['com.grapecity.leyserkids.parent'], success, failure);

Or

   // not recommended, as the name of app may not be unified
   installedApps.haveNames(['Leyserkids-P'], success, failure);

Or

   installedApps.getPackages( success, failure);

Or

   installedApps.getNames( success, failure);

Or

    installedApps.getNamesAndPackages( success, failure);

Or

	// In the 1st arg of the success callback, 0 stands for disabled while 1 stands for enabled
    installedApps.checkNotificationEnabled( success, failure);
  • For haveXXX api, result will be array of booleans.
  • For getXXX api, result will be array of objects, each containing name, package or both.

It works great with this plugin for starting apps from cordova http://plugins.cordova.io/#/package/com.hutchind.cordova.plugins.launcher

About

cordova plugin for detecting or listing installed on the device apps names and app packages

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 58.2%
  • Objective-C 28.8%
  • JavaScript 13.0%