Author Topic: [solved]NGUI way of hiding a widget  (Read 3160 times)

laurentl

  • Full Member
  • ***
  • Thank You
  • -Given: 0
  • -Receive: 0
  • Posts: 188
    • View Profile
    • McDROID
[solved]NGUI way of hiding a widget
« on: April 06, 2013, 04:29:10 AM »
I currently use .SetActive(bool) to hide/show buttons, progress bars and soon, draggable contents.

Is there a better way to do that in NGUI ?
« Last Edit: April 06, 2013, 06:28:49 PM by Nicki »

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: NGUI way of hiding a widget
« Reply #1 on: April 06, 2013, 11:36:59 AM »
That's just fine.

Nicki

  • Global Moderator
  • Hero Member
  • *****
  • Thank You
  • -Given: 33
  • -Receive: 141
  • Posts: 1,768
    • View Profile
Re: NGUI way of hiding a widget
« Reply #2 on: April 06, 2013, 12:56:18 PM »
SetActive is just fine, either Unity built in or NGUITools.

If you have other scripts on the widget that you for whatever reason want to keep active, you can disable the widget component instead - that will also hide it, but leave colliders and other scripts active.