Hello,
I have a Scrollview with a bunch of widgets inside. Each widget actually is a button which start associated game level.
I want to add visual effect when button clicked. E.g. moving and scaling its image and shadowing all other staff.
......
|___ ShadowPanel (depth 1)
|___ ScrollView panel (depth 0)
|___ Grid
|_ Icon01
......
|_ IconNN
So, I have to move IconXX from ScrollView to ShadowPanel (otherwise it will be shadowed, and dont be tweened properly), and when tween it somehow.
First, I did it in this way:
IconTransform.SetParent(ShadowPanel.transform);
foreach (UIWidget widget in IconTransform.GetComponentsInChildren<UIWidget>())
{
ShadowPanel.AddWidget(widget);
}
This one works almost fine for my needs - actually i see one icon staying at place and "new" instance doing tween things.
But if icon transform moves outside ScrollView rect (via scaling or changing position) - it "jump" back to scroll panel: i.e. become shadowed and affected by clipping.
Of course, I tried ScrollViewPanel.RemoveWidget, but in this case NGUI stop updating widget on screen.
I tried to use panel.Refresh, panel.RebuildDrawCalls and so on, but all this things doesnt matter at all.
So my question is simple - what I do wrong?
