Search Unity

Hiding and showing group tracks via script? (Timeline workflow improvements)

Discussion in 'Timeline' started by ricmorales22, Jul 26, 2019.

  1. ricmorales22

    ricmorales22

    Joined:
    Nov 29, 2015
    Posts:
    7
    Hi there, I'm wondering if it's possible to hide and show group tracks via script. I've searched the Timeline documentation and can't find any exposed attributes or methods to handle this.

    I'm dealing with a large number of tracks and would like to show and hide all group tracks at once, as well as toggle tracks individually, so as to make the workflow within Timeline smoother and faster, without needing to manually close groups you're not working with.

    Ideally, I'd love to set the scroll position of the Timeline Editor window as well. For example, when I'm working with a large hierarchy, and a large number of tracks, I want to be able to select a game object, then quickly add any associated tracks to the selection, as well as automatically scroll the user to those tracks in the Timeline window.

    Any guidance appreciated! Or would love to see this functionality implemented.
     
  2. seant_unity

    seant_unity

    Unity Technologies

    Joined:
    Aug 25, 2015
    Posts:
    917
    No, unfortunately there are no APIs exposed to do that. The collapsed value of a group track isn't stored on the track itself, but it's in the view data. We definitely should expose that functionality as well as scrolling and other editor related APIs.
     
    ricmorales22 likes this.