mirror of
https://github.com/purplecabbage/phonegap-plugins.git
synced 2026-04-24 03:00:11 -04:00
25 lines
507 B
JavaScript
25 lines
507 B
JavaScript
/**
|
|
*
|
|
* Phonegap share plugin for Android
|
|
* Kevin Schaul 2011
|
|
*
|
|
*/
|
|
|
|
var Share = function() {};
|
|
|
|
Share.prototype.show = function(content, success, fail) {
|
|
return PhoneGap.exec( function(args) {
|
|
success(args);
|
|
}, function(args) {
|
|
fail(args);
|
|
}, 'Share', '', [content]);
|
|
};
|
|
|
|
PhoneGap.addConstructor(function() {
|
|
/**
|
|
* Phonegap version < 1.0
|
|
* use the following line
|
|
*/
|
|
// PhoneGap.addPlugin('share', new Share());
|
|
PluginManager.addService("Share","com.schaul.plugins.share.Share");
|
|
}); |