ios如何把微博gif添加到QQ收藏店铺gif中,讲详细点

有大神知道新浪微博gif图点开后是另一张图是怎么做的吗?_ps吧_百度贴吧
&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&签到排名:今日本吧第个签到,本吧因你更精彩,明天继续来努力!
本吧签到人数:0成为超级会员,使用一键签到本月漏签0次!成为超级会员,赠送8张补签卡连续签到:天&&累计签到:天超级会员单次开通12个月以上,赠送连续签到卡3张
关注:1,866,293贴子:
有大神知道新浪微博gif图点开后是另一张图是怎么做的吗?收藏
就是这条微博的配图
应该是设置两帧动画,而且不循环
其实就是两张图合成了一张GIF,看起来像是切换了而已
登录百度帐号推荐应用
为兴趣而生,贴吧更懂你。或微博里那些GIF 视频 是怎么做出来的? 求解_百度知道13282人阅读
IOS开发笔记(248)
第一步:在targets-&info-&url types中添加一项,命名为wb+appid(到官网开放平台去申请)
第二步:写一个分享功能类
// 省略头文件
@interface HYBShareSDKHelper : NSObject
+ (void)registerShareSDK;
+ (BOOL)handleOpenURL:(NSURL *)
+ (BOOL)handleOpenURL:(NSURL *)url sourceApplication:(NSString *)sourceApplication annotation:(id)
// 调用此方法来分享信息
typedef void (^HYBShareCompletion)(BOOL successful);
+ (void)shareWithContent:(NSString *)content
toController:(UIViewController *)controller
pngImage:(UIImage *)pngImage
title:(NSString *)title
url:(NSString *)url
mediaType:(SSPublishContentMediaType)mediaType
shareViewDelegate:(id&ISSShareViewDelegate&)shareViewDelegate
completion:(HYBShareCompletion)
外部调用上面封装的方法来实现功能
HYBShareSDKHelper.m
CustomSharedSDKDemo
#import &HYBShareSDKHelper.h&
#import &HYBAppCommonInfoTool.h&
#import &HYBShareView.h&
#define kShareSDKAppKey @&&
#define kShareSDKAppSecret @&&
#define kSinaWeiboAppKey @&&
#define kSinaWeiboAppSecret @&&
@implementation HYBShareSDKHelper
+ (void)registerShareSDK {
[ShareSDK registerApp:kShareSDKAppKey];
// 添加新浪微博应用
NSString *redirectUri = @&&;
// 添加新浪微博应用
[ShareSDK connectSinaWeiboWithAppKey:kSinaWeiboAppKey
appSecret:kSinaWeiboAppSecret
redirectUri:redirectUri];
// 当使用新浪微博客户端分享的时候需要按照下面的方法来初始化新浪的平台
connectSinaWeiboWithAppKey:kSinaWeiboAppKey
appSecret:kSinaWeiboAppSecret
redirectUri:redirectUri
weiboSDKCls:[WeiboSDK class]];
+ (BOOL)handleOpenURL:(NSURL *)url {
return [ShareSDK handleOpenURL:url wxDelegate:self];
+ (BOOL)handleOpenURL:(NSURL *)url sourceApplication:(NSString *)sourceApplication annotation:(id)annotation {
return [ShareSDK handleOpenURL:url sourceApplication:sourceApplication annotation:annotation wxDelegate:self];
// 这里是自己定制的弹出分享UI
+ (void)showShareViewInController:(UIViewController *)controller completion:(HYBShareClickBlock)completion {
HYBShareView *sv = [[HYBShareView alloc] initWithImages:@[@&sns_wx_icon&, @&sns_wx_fr_icon&, @&sns_qq_icon&, @&sns_qzone_icon&, @&sns_sina_icon&] titles:@[@&微信好友&, @&微信朋友圈&, @&QQ好友&, @&QQ空间&, @&新浪微博&] completion:^(NSUInteger index) {
if (completion) {
completion(index);
[sv showInController:controller];
+ (void)shareWithContent:(NSString *)content
toController:(UIViewController *)controller
pngImage:(UIImage *)pngImage
title:(NSString *)title
url:(NSString *)url
mediaType:(SSPublishContentMediaType)mediaType
shareViewDelegate:(id&ISSShareViewDelegate&)shareViewDelegate
completion:(HYBShareCompletion)completion {
// 分享内容
id&ISSContent& sharedContent = [ShareSDK content:content
defaultContent:content
image:[ShareSDK pngImageWithImage:pngImage]
title: title
description:@&自己看着办&
mediaType:mediaType];
// 验证参数
id&ISSAuthOptions& authOptions = [ShareSDK authOptionsWithAutoAuth:YES
allowCallback:YES
authViewStyle:SSAuthViewStyleFullScreenPopup
viewDelegate:nil
authManagerViewDelegate:nil];
// 显示分享列表
[self showShareViewInController:controller completion:^(NSUInteger index) {
if (index == 4) {// 新浪微博
[self shareToSinaWeiboWithContent:sharedContent authOptions:authOptions content:content pngImage:pngImage completion:^(BOOL successful) {
if (completion) {
completion(successful);
// 分享到Sina weibo
+ (void)shareToSinaWeiboWithContent:(id&ISSContent&)sharedContent
authOptions:(id&ISSAuthOptions&)authOptions
content:(NSString *)content
pngImage:(UIImage *)pngImage
completion:(HYBShareCompletion)completion {
[sharedContent addSinaWeiboUnitWithContent:content
image:[ShareSDK pngImageWithImage:pngImage]];
// if haven authorized, then call
if (![ShareSDK hasAuthorizedWithType:ShareTypeSinaWeibo]) {
[ShareSDK authWithType:ShareTypeSinaWeibo options:authOptions result:^(SSAuthState state, id&ICMErrorInfo& error) {
if (state == SSAuthStateSuccess) {
id&ISSShareOptions& shareOptions = [ShareSDK simpleShareOptionsWithTitle:@&美容总监&
shareViewDelegate:nil];
[ShareSDK clientShareContent:sharedContent
type:ShareTypeSinaWeibo
authOptions:authOptions
shareOptions:shareOptions
statusBarTips:YES
result:^(ShareType type, SSResponseState state, id&ISSPlatformShareInfo& statusInfo, id&ICMErrorInfo& error, BOOL end) {
if (completion && end) {
DDLogVerbose(@&%@&, error.errorDescription);
completion(state == SSPublishContentStateSuccess);
} else {// use client share to Sina App Client
id&ISSShareOptions& shareOptions = [ShareSDK simpleShareOptionsWithTitle:@&美容总监&
shareViewDelegate:nil];
[ShareSDK clientShareContent:sharedContent
type:ShareTypeSinaWeibo
authOptions:authOptions
shareOptions:shareOptions
statusBarTips:YES
result:^(ShareType type, SSResponseState state, id&ISSPlatformShareInfo& statusInfo, id&ICMErrorInfo& error, BOOL end) {
if (completion && end) {
DDLogVerbose(@&%@&, error.errorDescription);
completion(state == SSPublishContentStateSuccess);
参考知识库
* 以上用户言论只代表其个人观点,不代表CSDN网站的观点或立场
访问:1388615次
积分:16080
积分:16080
排名:第423名
原创:489篇
转载:60篇
评论:272条
阅读:19874
文章:17篇
阅读:10265
(28)(1)(1)(2)(16)(2)(13)(30)(17)(12)(6)(1)(2)(44)(6)(14)(17)(29)(18)(3)(33)(30)(10)(16)(4)(5)(2)(19)(1)(1)(26)(25)(116)(2)(8)(1)(1)iphone怎么保存微博gif图_百度知道微博里gif动态图片怎么保存,急急急_百度知道}

我要回帖

更多关于 微信怎么收藏gif图片 的文章

更多推荐

版权声明:文章内容来源于网络,版权归原作者所有,如有侵权请点击这里与我们联系,我们将及时删除。

点击添加站长微信