Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Messages - Russel

Pages: 1 [2]
NGUI 3 Support / Re: Long Popup List
« on: June 13, 2013, 12:29:56 PM »
Could this be a rounding error? Or is this a completely wrong approach?
I need quick help. Thank you!

NGUI 3 Support / Re: Long Popup List
« on: June 13, 2013, 09:13:44 AM »
Thank you!

I found this:

"You can read the actual screen size in Screen.height and compare that with the value UIRoot has calculated, to figure out your widget's actual pixel size on the screen." (

I have now tried it so:

int nItem = (int)((fDelta / (font.size * textScale + padding.y))*(transform.root.GetComponent<UIRoot>().manualHeight/Screen.height));

It seems to work with:


Pixel Size is 2

but not with:


Pixel Size is 1.3302...

Is this the right way? Maybe you have a solution?

NGUI 3 Support / Re: Long Popup List
« on: June 12, 2013, 03:32:58 AM »
Nobody can help me?

NGUI 3 Support / Re: Long Popup List
« on: June 11, 2013, 04:10:20 AM »
What do I need to change in GetSelectedItem(), so that it works with "FixedSizeOnMobiles"? It works correctly only with "Pixel Perfect" in the UIRoot. I am grateful for any tips.

    UILabel GetSelectedItem()
        //. determine which label will be selected
        Vector3 panelPos = UICamera.currentCamera.WorldToScreenPoint(mChildPanel.transform.position);
        float fDelta = panelPos.y - UICamera.currentTouch.pos.y;
        int nItem = (int)(fDelta / (font.size * textScale + padding.y));
        if (nItem < 0 || nItem >= mLabelList.Count)
            return null;

        return mLabelList[nItem];

Thank you! Works great. :)

How can I jump to a certain item directly? There is only the possibility over scrollBar.scrollValue()? I would like that my list will scroll to the required item.


Thank you! Of what exactly should I check the position? Do you have a small example?


How do I get an event when I have reached the end of the scroll bar? I need the event to reload new content.

Pages: 1 [2]