本文整理匯總了Java中cn.sharesdk.framework.ShareSDK.logDemoEvent方法的典型用法代碼示例。如果您正苦於以下問題:Java ShareSDK.logDemoEvent方法的具體用法?Java ShareSDK.logDemoEvent怎麽用?Java ShareSDK.logDemoEvent使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類cn.sharesdk.framework.ShareSDK
的用法示例。
在下文中一共展示了ShareSDK.logDemoEvent方法的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: showEditPage
import cn.sharesdk.framework.ShareSDK; //導入方法依賴的package包/類
public final void showEditPage(final Platform platform) {
beforeFinish = new Runnable() {
public void run() {
boolean isSilent = isSilent();
boolean isCustomPlatform = platform instanceof CustomPlatform;
boolean isUseClientToShare = isUseClientToShare(platform);
if (isSilent || isCustomPlatform || isUseClientToShare) {
shareSilently(platform);
} else {
ShareParams sp = formateShareData(platform);
if (sp != null) {
// 編輯分享內容的統計
ShareSDK.logDemoEvent(3, null);
if (getCustomizeCallback() != null) {
getCustomizeCallback().onShare(platform, sp);
}
impl.showEditPage(activity, platform, sp);
}
}
}
};
finish();
}
示例2: showEditPage
import cn.sharesdk.framework.ShareSDK; //導入方法依賴的package包/類
public final void showEditPage(final Platform platform) {
beforeFinish = new Runnable() {
public void run() {
boolean isSilent = isSilent();
boolean isCustomPlatform = platform instanceof CustomPlatform;
boolean isUseClientToShare = isUseClientToShare(platform);
if (isSilent || isCustomPlatform || isUseClientToShare) {
shareSilently(platform);
} else {
ShareParams sp = formateShareData(platform);
if (sp != null) {
// 編輯分享內容的統計
ShareSDK.logDemoEvent(3, null);
if (getCustomizeCallback() != null) {
getCustomizeCallback().onShare(platform, sp);
}
impl.showEditPage(activity, platform, sp);
}
}
}
};
finish();
}
示例3: onCancel
import cn.sharesdk.framework.ShareSDK; //導入方法依賴的package包/類
public final void onCancel(Platform platform, int action) {
Message msg = new Message();
msg.arg1 = 3;
msg.arg2 = action;
msg.obj = platform;
UIHandler.sendMessage(msg, this);
// 分享失敗的統計
ShareSDK.logDemoEvent(5, platform);
}
示例4: onClick
import cn.sharesdk.framework.ShareSDK; //導入方法依賴的package包/類
public void onClick(View v) {
if (v.getTag() != null) {
String tag = (String) v.getTag();
if (tag.equals("close")) {
for (Platform plat : this.platforms) {
ShareSDK.logDemoEvent(5, plat);
}
finish();
} else if (tag.equals("ok")) {
onShareButtonClick(v);
}
}
}
示例5: onError
import cn.sharesdk.framework.ShareSDK; //導入方法依賴的package包/類
public final void onError(Platform platform, int action, Throwable t) {
t.printStackTrace();
Message msg = new Message();
msg.arg1 = 2;
msg.arg2 = action;
msg.obj = t;
UIHandler.sendMessage(msg, this);
// 分享失敗的統計
ShareSDK.logDemoEvent(4, platform);
}
示例6: onClick
import cn.sharesdk.framework.ShareSDK; //導入方法依賴的package包/類
public void onClick(View v) {
int i;
if (v.equals(this.llTitle.getBtnBack())) {
Platform plat = null;
for (i = 0; i < this.views.length; i++) {
if (this.views[i].getVisibility() == 4) {
plat = this.platformList[i];
break;
}
}
if (plat != null) {
ShareSDK.logDemoEvent(5, plat);
}
finish();
} else if (v.equals(this.llTitle.getBtnRight())) {
this.shareParamMap.put("text", this.etContent.getText().toString());
this.platforms.clear();
for (i = 0; i < this.views.length; i++) {
if (this.views[i].getVisibility() != 0) {
this.platforms.add(this.platformList[i]);
}
}
if (this.platforms.size() > 0) {
setResultAndFinish();
return;
}
int resId = R.getStringRes(this.activity, "select_one_plat_at_least");
if (resId > 0) {
Toast.makeText(getContext(), resId, 0).show();
}
} else if (v instanceof FrameLayout) {
((FrameLayout) v).getChildAt(1).performClick();
} else if (v.getVisibility() == 4) {
v.setVisibility(0);
} else {
v.setVisibility(4);
}
}
示例7: show
import cn.sharesdk.framework.ShareSDK; //導入方法依賴的package包/類
@SuppressWarnings("unchecked")
public void show(Context context) {
HashMap<String, Object> shareParamsMap = new HashMap<String, Object>();
shareParamsMap.putAll(params);
MobSDK.init(context.getApplicationContext());
ShareSDK.initSDK(context);
// 打開分享菜單的統計
ShareSDK.logDemoEvent(1, null);
int iTheme = 0;
try {
iTheme = ResHelper.parseInt(String.valueOf(shareParamsMap.remove("theme")));
} catch (Throwable t) {}
OnekeyShareTheme theme = OnekeyShareTheme.fromValue(iTheme);
OnekeyShareThemeImpl themeImpl = theme.getImpl();
themeImpl.setShareParamsMap(shareParamsMap);
themeImpl.setDialogMode(shareParamsMap.containsKey("dialogMode") ? ((Boolean) shareParamsMap.remove("dialogMode")) : false);
themeImpl.setSilent(shareParamsMap.containsKey("silent") ? ((Boolean) shareParamsMap.remove("silent")) : false);
themeImpl.setCustomerLogos((ArrayList<CustomerLogo>) shareParamsMap.remove("customers"));
themeImpl.setHiddenPlatforms((HashMap<String, String>) shareParamsMap.remove("hiddenPlatforms"));
themeImpl.setPlatformActionListener((PlatformActionListener) shareParamsMap.remove("callback"));
themeImpl.setShareContentCustomizeCallback((ShareContentCustomizeCallback) shareParamsMap.remove("customizeCallback"));
if (shareParamsMap.containsKey("disableSSO") ? ((Boolean) shareParamsMap.remove("disableSSO")) : false) {
themeImpl.disableSSO();
}
themeImpl.show(context.getApplicationContext());
}
示例8: prepareForEditPage
import cn.sharesdk.framework.ShareSDK; //導入方法依賴的package包/類
private void prepareForEditPage(Platform platform) {
if (formateShareData(platform)) {
ShareParams sp = shareDataToShareParams(platform);
if (sp != null) {
// 編輯分享內容的統計
ShareSDK.logDemoEvent(3, null);
if (customizeCallback != null) {
customizeCallback.onShare(platform, sp);
}
showEditPage(context, platform, sp);
}
}
}
示例9: cancelAndFinish
import cn.sharesdk.framework.ShareSDK; //導入方法依賴的package包/類
/** 取消分享時,執行的方法 */
private void cancelAndFinish() {
// 分享失敗的統計
ShareSDK.logDemoEvent(5, platform);
finish();
}
示例10: onFinish
import cn.sharesdk.framework.ShareSDK; //導入方法依賴的package包/類
public boolean onFinish() {
if (this.canceled) {
ShareSDK.logDemoEvent(2, null);
}
return super.onFinish();
}