ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

Scriptied GUI listbox scrolling bug

COW Forums : Adobe After Effects

<< PREVIOUS   •   FAQ   •   VIEW ALL   •   PRINT   •   NEXT >>
Gabriel Valkama
Scriptied GUI listbox scrolling bug
on Sep 10, 2014 at 1:56:26 pm

Hi!

I need to use a listbox with hundreds of rows. The thing is, it seems that I loose the listbox scrolling ability if I try to confine the listbox to a reasonable size. Here is a sample:


var FSWindow = new Window("palette","Listbox Scroll Bug", undefined);

var FSList = FSWindow.add("listbox", [0,0,500,205], "FS List", {multiselect:true, numberOfColumns: 2, showHeaders: true, columnTitles: ["First","Second"]});

for (i=0;i<50;i++)
{
var curItem = FSList.add ('item', "Row"+String(i)); // Column 1
curItem.subItems[0].text = "Row"+String(i); // Column 2
}

FSWindow.center();
FSWindow.show();


There are 50 rows in the listbox but you can only access the first eleven of them.

I have tried searching google and Javascript Tools Guide CS6.

Thanks in advance!


Return to posts index

Gabriel Valkama
Re: Scriptied GUI listbox scrolling bug
on Sep 11, 2014 at 5:10:42 am
Last Edited By Gabriel Valkama on Sep 11, 2014 at 5:30:08 am

Scrolling seems to work when using 'ExtendScript Toolkit CS6' as the target application. When changing to 'Adobe After Effects CS6 (11.0)' scrolling breaks.


Return to posts index


Gabriel Valkama
Simple solution
on Sep 11, 2014 at 5:40:21 am

Just had to create the window before populating the listbox:


var FSWindow = new Window("palette","Listbox Scroll Bug", undefined);

var FSList = FSWindow.add("listbox", [0,0,200,205], "FS List", {multiselect:true, numberOfColumns: 2, showHeaders: true, columnTitles: ["First","Second"]});

FSWindow.center();
FSWindow.show();

for (i=0;i<50;i++)
{
var curItem = FSList.add ('item', "Row"+String(i)); // Column 1
curItem.subItems[0].text = "Row"+String(i); // Column 2
}


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2017 CreativeCOW.net All Rights Reserved
[TOP]