Size of superview
1. I'm adding a UIView to a UIScrollView.
2. I set the frame for the UIView to CGRectMake(0, 0, 200, 200) and thus expect the view to be 200 in width and 200 in height.
3. I then add a child UIView to my UIView.
4. In the child view's view controller I then try to resize the child UIView to the same size as it's parent.
The problem is that it expands to the width and height of the entire application window, instead of just the parent view. Also, if I try to get the width and height of the parent UIView from the child view's view controller using self.view.superview.frame.size or self.view.superview.bounds.height I get the width and height of the entire application window instead of just the parent view.
Why is this? Shouldn't self.view.superview.bounds or self.view.superview.frame (what's the difference between these two properties, by the way?) return a width and height of 200, since that's what I set the frame of the superview to when I added it to my UIScrollView?
Message was edited by: Andreas Lindahl
Windows XP