移除分享的结果的Toast

This commit is contained in:
zlzw 2023-04-01 11:33:20 +08:00
parent 5657d5a00b
commit c4ae047a4b
3 changed files with 1 additions and 7 deletions

View File

@ -33,17 +33,14 @@ public class FacebookShare extends AbsShareInterface {
dialog.registerCallback(callbackManager, new FacebookCallback<Sharer.Result>() { dialog.registerCallback(callbackManager, new FacebookCallback<Sharer.Result>() {
@Override @Override
public void onSuccess(Sharer.Result result) { public void onSuccess(Sharer.Result result) {
ToastUtil.show("Facebook分享成功");
} }
@Override @Override
public void onCancel() { public void onCancel() {
ToastUtil.show("Facebook分享取消");
} }
@Override @Override
public void onError(@NonNull FacebookException e) { public void onError(@NonNull FacebookException e) {
ToastUtil.show("Facebook分享失败:"+e.toString());
} }
}); });
dialog.show(content); dialog.show(content);

View File

@ -36,18 +36,15 @@ public class MessengerShare extends AbsShareInterface {
dialog.registerCallback(callbackManager, new FacebookCallback<Sharer.Result>() { dialog.registerCallback(callbackManager, new FacebookCallback<Sharer.Result>() {
@Override @Override
public void onSuccess(Sharer.Result result) { public void onSuccess(Sharer.Result result) {
ToastUtil.show("Messenger分享成功:"+result.getPostId());
callback.onSuccess(); callback.onSuccess();
} }
@Override @Override
public void onCancel() { public void onCancel() {
ToastUtil.show("Messenger分享取消");
} }
@Override @Override
public void onError(@NonNull FacebookException e) { public void onError(@NonNull FacebookException e) {
ToastUtil.show("Messenger分享失败:" + e.toString());
e.printStackTrace(); e.printStackTrace();
} }
}); });

View File

@ -120,7 +120,7 @@ public class SharePopDialog extends AbsDialogPopupWindow {
private ShareBuilder builder(int type) { private ShareBuilder builder(int type) {
ShareBuilder builder = ShareBuilder.builder(type); ShareBuilder builder = ShareBuilder.builder(type);
builder.setText(String.format(WordUtil.getString(R.string.dialog_share_info), StringUtil.isEmpty(anchorName) ? "" : anchorName)); // builder.setText(String.format(WordUtil.getString(R.string.dialog_share_info), StringUtil.isEmpty(anchorName) ? "" : anchorName));
builder.setUid(uid); builder.setUid(uid);
builder.setAnchorId(anchorId); builder.setAnchorId(anchorId);
builder.setAnchorName(anchorName); builder.setAnchorName(anchorName);