mwphotobrowser

Cocoapods遇到CDN: trunk URL couldn't be downloaded: https://raw.githubusercontent.com/CocoaPods/Specs/master/Specs...

拟墨画扇 提交于 2020-01-18 15:10:18
最近自己做了一个cocoapod库,代码改好了,先本地验证一下podspec pod lib lint MWPhotoBrowser.podspec --use-libraries --allow-warnings 报错了 e failed - 10 error(s): CDN: trunk URL couldn't be downloaded: https://raw.githubusercontent.com/CocoaPods/Specs/master/Specs/c/8/7/MBProgressHUD/0.5/MBProgressHUD.podspec.json, error: Failed to open TCP connection to raw.githubusercontent.com:443 (Connection refused - connect(2) for "raw.githubusercontent.com" port 443) 。。。 原因出在MWPhotoBrowser引用了另一个库MBProgressHUD,验证的过程中,需要下载MBProgressHUD,下载失败了。 为什么会失败呢?因为我现在用的cocoapods版本是1.8.4,默认的源是这个 trunk - Type: CDN - URL: https://cdn.cocoapods

解决MWPhotoBrowser中的SDWebImage加载大图导致的内存警告问题

无人久伴 提交于 2019-12-14 18:21:55
【推荐】2019 Java 开发者跳槽指南.pdf(吐血整理) >>> iOS开发 · 2015-01-22 11:31 MWPhotoBrowser是一个非常不错的照片浏览器,在github的star接近3000个,地址:https://github.com/mwaterfall/MWPhotoBrowser.git MWPhotoBrowser来加载小图1M以下的都应该不会有内存警告的问题。如果遇到大图,3M、4M、5M的大图,很有可能导致内存警告。最近我就遇到这个问题,很是头疼。来回滑动查看照片内存飙到100M以上: 网上查了很多资料,都没有解决问题。 我们来看一下MWPhotoBrowser,其实MWPhotoBrowser用的是SDWebImage来下载图片的。地址:https://github.com/rs/SDWebImage.git 在github看到SDWebImage的介绍,后面说到: Future Enhancements LRU memory cache cleanup instead of reset on memory warning 看到这个真是欲哭无泪啊。 再去看看SDWebImage的,有个人提问了: How to disable "memory cache"? I don't want memory cache, it used a lot of

MWPhotoBrowser into Tabbar Controller

懵懂的女人 提交于 2019-12-12 05:35:49
问题 I use MWPhotoBrowser to make an image Gallery. If i make a new controller(push) all work fine. Although i want to add MWPhotoBrowser into a custom ViewController which is into a TabBarController . I got this with these lines of code. [self addChildViewController:browser]; [[self view] addSubview:[browser view]]; [browser didMoveToParentViewController:self]; The problem is that when i change the orientation(rotate the device) only a part of screen works. The rest seems to be dead.I suppose