No internet connection
  1. Home
  2. How to

Pro Tools 2024 and Track Height

By Joseph Faison @Joseph_Faison
    2024-03-19 20:48:24.961Z

    So everything is updated (Soundflow and all packages), except I am now having an issue with setting track heights. I've been using the following script but it is telling me "Popup window not found"

    sf.ui.proTools.appActivate();
    
    var size = 'mini';
    
    var f = sf.ui.proTools.selectedTrack.frame;
    var popupMenu = sf.ui.proTools.selectedTrack.popupMenuOpenFromElement({
        relativePosition: { x: f.w - 10, y: 5 },    
        isOption: true,
        isShift: true,
    }).popupMenu;
    popupMenu.menuClickPopupMenu({
        menuPath: [size]
    });
    
    Solved in post #2, click to view
    • 5 replies
    1. Starting with SF V 5.7.4, elements are clicked in the center of it's frame because Avid have tweaked the clickable area of some elements.
      So now you need to adjust the relative position from the frame's center.
      As a result the y offset should be zero and you need to add just 1/2 of the frame's width to x to get the right side of the frame:

      sf.ui.proTools.appActivate();
      sf.ui.proTools.mainWindow.invalidate();
      
      var size = 'mini';
      
      var f = sf.ui.proTools.selectedTrack.frame;
      
      var popupMenu = sf.ui.proTools.selectedTrack.popupMenuOpenFromElement({
        relativePosition: { x: f.w / 2 - 5, y: 0 },
        isOption: true,
        isShift: true,
      }).popupMenu;
      
      popupMenu.menuClickPopupMenu({
        menuPath: [size]
      });
      
      ReplySolution
      1. Keep in mind, you'll only have to do this when you're changing track heights - the height popup has to be clicked this way because there's no dedicated element for it. Most other popups should work normally

        1. JJoseph Faison @Joseph_Faison
            2024-03-19 22:14:55.229Z

            Works great now, thank you!

            1. Thanks both of you, this stopped working yesterday and I was supper annoyed and confused, and now I know!

        2. In reply toJoseph_Faison:

          D'Oh!
          Alternatively you can force SF to click relative to the top left (the old behavior) by using the anchor property (which is the simplest solution):

          sf.ui.proTools.appActivate();
          
          var size = 'mini';
          
          var f = sf.ui.proTools.selectedTrack.frame;
          var popupMenu = sf.ui.proTools.selectedTrack.popupMenuOpenFromElement({
              anchor:"TopLeft", // <<-----****
              relativePosition: { x: f.w - 10, y: 5 },    
              isOption: true,
              isShift: true,
          }).popupMenu;
          popupMenu.menuClickPopupMenu({
              menuPath: [size]
          });