Comments (11)
你好,可否提供这个Demo与我了解一下。
from jhud.
你在第二个 item 进去-->next-->touch一下-->马上 pop 回去,就会看到内存泄露的弹框
CBWEmptyViewDemo副本.zip
from jhud.
我看了下,定时器在没有调用hide方法就返回而导致,应该是类方法中的objc函数可能导致,
暂时没有更好的办法,建议使用实例方法。😂
from jhud.
其实这个是objc_setAssociatedObject的OBJC_ASSOCIATION_RETAIN_NONATOMIC导致的,但是您的换成OBJC_ASSOCIATION_ASSIGN会崩溃
from jhud.
Yeah ,这个我有测试过,所以现在迫于所学有限,不好下手啊。😂
from jhud.
根据WWDC 2011, Session 322 (第36分钟左右)发布的内存销毁时间表,被关联的对象在生命周期内要比对象本身释放的晚很多。它们会在被 NSObject -dealloc 调用的 object_dispose() 方法中释放。
看下这个
http://nshipster.cn/associated-objects/
from jhud.
🙂 好。
道友可以先尝试JHUD.m中注掉 的 hideForView:(UIView *)view 方法来隐藏。
from jhud.
如上所言,我参考了MBProgressHUD,移除了OBJC相关方法,使用+hideForView:(UIView *)view来实现隐藏的目的。
已更新JHUD。
from jhud.
@xeroxmx 学习了一波,兄弟能提供下内存泄露的一些解决方法吗?目前使用MLeaksFinder,有时就算知道哪里出了问题,也有些无从下手的感觉,不知道如何修改
from jhud.
@zzgo 也苦恼于内存泄露的代码在哪里, MLeaksFinder只会显示类,不会显示具体的哪一些代码内存,上次遇到 SEL 作为属性用 strong,结果内存泄漏了,找了半天才找到,要用 weak
from jhud.
😂
from jhud.
Related Issues (10)
- 那个转圈效果 咋不弄个gif图片呢 HOT 6
- 背景颜色建议默认为透明 HOT 2
- 文字为空时,circle建议垂直居中
- pod 安装失败 HOT 1
- 横竖屏切换问题 HOT 1
- indicatorViewSize这个是做什么的 HOT 1
- 螢幕打橫時 HOT 3
- 真棒 👍 HOT 1
- 并没有一个叫做hide的类方法啊,read me是不是需要更新了 HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from jhud.