View Full Version : static pointer to UIView problem

Feb 27, 2009, 07:59 PM
I have a UIView in my nib file, defined in the appdelegate as:
IBOutlet UIView *board;

I then have a singleton class called 'facade' with:
UIView *board;

From the appdelegate I set 'facade.board = board;'

Then from another class, I retrieve facade.board and I can see that the memory addresses for 'facade.board' is pointing to where it should. However, I can't add to the subview or iterate over the subviews. There're no errors or warning, it just doesn't do anything. But it does have some handle on it because [facade.board.subviews count] works!

Does anyone have any idea what could be up? I can add subviews to the board if i pass the UIView as a reference, but not when I set it in and retrieve it from the singleton.

Thanks in advance.