Author Topic: Nothing can go ontop of a ScrollView  (Read 3393 times)

hhappak

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 3
    • View Profile
Nothing can go ontop of a ScrollView
« on: December 16, 2013, 04:46:53 AM »
Hi all,

I am using NGUI 3.0.8f and I am having a problem. I am trying to have a list using ScrollView in my app. This part worked fine except for one tiny problem. Above the scrollView, there is a popup list that is when clicked, the list itself appears behind the scrollview's items. When I tried to play with the depth, I found out that the scrollview only responds to above 0 or below 0 values. Above 0 it goes ontop of everything, below 0 it is behind everything. Is there a way I can have it so that the popup list can be used normally and be layered ontop of the content list?

I am using the popup list as content filtering and the design is quite rigid for now, so any help here is appreciated.

PaulGregory

  • Guest
Re: Nothing can go ontop of a ScrollView
« Reply #1 on: December 16, 2013, 07:22:54 AM »
In an earlier version, I found that only panels can go on top of panels. Try making the popup list into a panel.
It's probably a bug though.

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: Nothing can go ontop of a ScrollView
« Reply #2 on: December 16, 2013, 08:10:56 AM »
There is no 3.0.8f. Scroll view goes on a panel, and the panel's depth is what determines the draw order. It should be unique.

A popup list is drawn by the same panel it's in, which is why it appears the way it does. Paul's suggestion will work. You can also change the popup list to appear in a fixed direction as well (always upwards, for example).

hhappak

  • Newbie
  • *
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 3
    • View Profile
Re: Nothing can go ontop of a ScrollView
« Reply #3 on: December 16, 2013, 09:52:46 AM »
Thanks. This worked for me. My mistake about the version.