Hi,
I'm using the NGUITools.AddChild() method to dynamically create dialogs from my resources folder within NGUI. The problem is that some of those dialogs need to anchor to the edges of the screen, which I only know how to do by setting the anchors to UIRoot. I can't do that when I'm creating a prefab of a single dialog, since the prefab can't store a reference to my UIRoot instance.
My workaround right now is to intsantiate an entirely new UIRoot prefab with my anchor-requiring dialog embedded in it. This seems hacky to me though, and I'm pretty sure it's causing some touch-event problems I'm having. There must be a better way.
What's the right way to deal with this?
thanks so much,
-Travis