[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[platform-swt-dev] SWT.Virtual Table allocates memory when it shouldn't

Hello world,

I am working on an eclipse project and have an issue with the SWT.VIRTUAL flag for tables.
Basically, it allocates memory for each table item, not just the view you have. (Using Ubuntu and GTK)
This means that if you make a table with 100 million entries, you get a bad heap exhaustion problem. Especially since it is allocating the memory with mallocs on the gtk side!

My solution is so far ugly as I am not yet 100% comfy with Java.

I am making a composite control that contains a table and a slider and I load the data dynamically using "SWT.SetData" handlers.

For our current architecture, this doesn't work... yet. I was wondering as the wrapping of everything in a table is complicated, if there are other solutions that could be suggested. Right now I am stuck trying to wrap cellDataProc so that I can have the setData event sent to the table and the master control that re-maps the indexes.

Any suggestions are welcome.