Comments (4)
Could you please NSLog your self.image
size after the first line where you set the contentMode?
Just do a
NSLog(@"x:%f, y:%f, w:%f, h:%f", self.image.frame.origin.x, self.image.frame.origin.y, self.image.frame.size.width, self.image.frame.size.height);
from uiactivityindicator-for-sdwebimage.
Right after the contentMode line:
x:0.000000, y:44.000000, w:0.000000, h:0.000000
Right after the image is set with the url
x:6.000000, y:2.000000, w:40.000000, h:40.000000
In my story board the second one, 6, 2, 40 ,40 is what I have set for the UIImage box. The odd thing is it seems like it is not initialized or something. Maybe I need to set the frame before I load the setImageWithURL block?
from uiactivityindicator-for-sdwebimage.
aha! Setting the frame before the setImageWithUrl block worked!
[self.image setFrame:CGRectMake(6, 2, 40, 40)];
The weird thing is I wonder why the storyboard wasn't setting this ?
I suspect it has something to do with iOS 6 "autolayout". I never had this issue in iOS5 without autolayout. It seems like ever since I turned that one everything got hosed, but have to support iPhone 5 so.. O well lol
Anyway thanks for the help!
from uiactivityindicator-for-sdwebimage.
Yes, that was the problem!
The UIActvityIndicatorView is placed in the middle of the UIImageView... so, if the imageView is 0x0, the activityView will be placed in 0/2x0/2 (which is 0x0)!
Glad you solved!
from uiactivityindicator-for-sdwebimage.
Related Issues (18)
- Possible to not use method version? HOT 5
- UIActivityIndicator hugs left center when using auto layout HOT 2
- extra code need to be comment HOT 2
- How can i intergrate with SDWebImage? HOT 1
- The error in UIImageView+UIActivityIndicatorForSDWebImage.m HOT 11
- Support for sd_setBackgroundImageWithURL HOT 2
- Invalid context error HOT 2
- cocoapods / swift and SDWebImage imports HOT 7
- Integrate with SD WebImage HOT 2
- Complete closure is called 4 times per image HOT 5
- Update SDWebImage HOT 3
- Not Carthage Compatible
- Support for tvOS.
- SDWebImage 4.0.0 error HOT 2
- Memory leak in UIImageView+UIActivityIndicatorForSDWebImage.m HOT 1
- UIActivityIndicator not stopping on cancelCurrentImageLoad HOT 1
- removeActivityIndicator HOT 2
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 uiactivityindicator-for-sdwebimage.