本文整理汇总了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();
}