123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124 |
- // using System.Collections;
- // using cn.sharesdk.unity3d;
- // using GFGGame.Launcher;
- // using UnityEngine;
- //
- // namespace GFGGame
- // {
- // public class QDShareManager : SingletonBase<QDShareManager>
- // {
- // public void Init()
- // {
- // QDShareManagerInit.Instance.shareSDKListener = new ShareSDKListener();
- // }
- //
- // //回传用户隐私授权结果
- //
- // /// <summary>
- // /// 构造分享信息 SetShareType
- // /// </summary>
- // /// <param name="text">分享的文字</param>
- // /// <param name="imageUrl">iOS平台,本地以及网络图片都使用此方法</param>
- // /// <param name="imageUrlArr">分享一组图片</param>
- // /// <param name="title">分享的标题</param>
- // /// <param name="titleUrl">标题的网络链接(QQ和QQ空间使用 )</param>
- // /// <param name="site"></param>
- // /// <param name="siteUrl"></param>
- // /// <param name="url">分享的链接(微信,微博,易信,Facebook等平台)</param>
- // /// <param name="comment"></param>
- // /// <param name="musicUrl"></param>
- // /// <param name="shareType">分享类型(微信,易信) ContentType</param>
- // /// <returns></returns>
- // public ShareContent NewStructureShareContent(string text, string imageUrl, string[] imageUrlArr, string title,
- // string titleUrl,
- // string site,
- // string siteUrl,
- // string url,
- // string comment,
- // string musicUrl, int shareType)
- // {
- // ShareContent content = new ShareContent();
- // content.SetText(text);
- // content.SetImageUrl(imageUrl);
- // content.SetImageArray(imageUrlArr);
- // content.SetTitle(title);
- // content.SetTitleUrl(titleUrl);
- // content.SetSite(site);
- // content.SetSiteUrl(siteUrl);
- // content.SetUrl(url);
- // content.SetComment(comment);
- // content.SetMusicUrl(musicUrl);
- // content.SetShareType(shareType);
- // return content;
- // }
- //
- // /// <summary>
- // /// 回传用户隐私授权结果给sdk
- // /// </summary>
- // /// <param name="granted"></param>
- // public void SubmitPolicyGrantResult(bool granted = true)
- // {
- // QDShareManagerInit.Instance.mobsdk.submitPolicyGrantResult(granted);
- // }
- //
- // //通过分享菜单分享
- // public int ShowPlatformList(PlatformType[] platforms, ShareContent shareContent)
- // {
- // return QDShareManagerInit.Instance.shareSDK.ShowPlatformList(platforms, shareContent, 100, 100);
- // }
- //
- // //直接通过编辑界面分享
- // public int ShowShareContentEditor(PlatformType platformType, ShareContent shareContent)
- // {
- // return QDShareManagerInit.Instance.shareSDK.ShowShareContentEditor(platformType, shareContent);
- // }
- //
- // //直接分享
- // public int ShareContent(PlatformType platformType, ShareContent shareContent)
- // {
- // return QDShareManagerInit.Instance.shareSDK.ShareContent(platformType, shareContent);
- // }
- // }
- //
- // public class ShareSDKListener : IShareSDKListener
- // {
- // public void OnAuthResult(int reqID, ResponseState state, PlatformType type, Hashtable result)
- // {
- // Debug.Log($"OnAuthResult");
- // }
- //
- // public void OnGetUserInfoResult(int reqID, ResponseState state, PlatformType type,
- // Hashtable result)
- // {
- // Debug.Log($"OnGetUserInfoResult");
- // }
- //
- // public void OnShareResult(int reqID, ResponseState state, PlatformType type, Hashtable result)
- // {
- // if (state == ResponseState.Success)
- // {
- // ShareRecordSProxy.ReqShareRecord().Coroutine();
- // }
- //
- // Debug.Log($"OnShareResult state:" + state);
- // }
- //
- // public void OnGetFriendsResult(int reqID, ResponseState state, PlatformType type,
- // Hashtable result)
- // {
- // Debug.Log($"OnGetFriendsResult");
- // }
- //
- // public void OnFollowFriendResult(int reqID, ResponseState state, PlatformType type,
- // Hashtable result)
- // {
- // Debug.Log($"OnFollowFriendResult");
- // }
- //
- // public void OnIsClientValidForAndroidResult(int reqID, ResponseState state, PlatformType type,
- // Hashtable result)
- // {
- // Debug.Log($"OnFollowFriendResult");
- // }
- // }
- // }
|