Skip to content
Browse files

add customized invoke

  • Loading branch information...
1 parent bf49711 commit 5cb6690a984da663fe3d7d4cade76e2e04bf6f60 @btspoony committed Feb 14, 2013
Showing with 13 additions and 0 deletions.
  1. +13 −0 client/social_qq.js
View
13 client/social_qq.js
@@ -13,22 +13,35 @@ social.init = function(initOpt) {
};
social.invite = function(options, callback) {
+ options = options || {};
if( callback )
options.onSuccess = options.onSuccess || callback;
fusion2.dialog.invite(options);
}
social.share = function(options, callback) {
+ options = options || {};
if( callback )
options.onSuccess = options.onSuccess || callback;
fusion2.dialog.sendStory(options);
}
social.buy = function(options, callback){
+ options = options || {};
+ if( callback )
+ options.onSuccess = options.onSuccess || callback;
options.sandbox = sandbox;
fusion2.dialog.buy(options);
}
+social.invoke = function(name, options, callback){
+ options = options || {};
+ if( callback )
+ options.onSuccess = options.onSuccess || callback;
+ options.sandbox = sandbox;
+ fusion2.dialog[name](options);
+}
+
social.checkBalance = function( callback ) {
var options = {};
options.onClose = callback;

0 comments on commit 5cb6690

Please sign in to comment.
Something went wrong with that request. Please try again.