[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[news.eclipse.tools] Re: having trouble using ViewerSorter

Thanks for the trick ...

but I still have my problem .... when I select a Column the content of the
table disappeared :-(
do I have to save (in an ArrayList, or something else) the content of the
table before appling the sorter and then restore the datas ??

John Arthorne wrote:

> A good example to look at for this is the task list. Under
> plugins/org.eclipse.ui/workbenchsrc.zip, you'll find the following classes:

> org.eclipse.ui.views.tasklist.TaskList
> org.eclipse.ui.views.tasklist.TaskSorter

> If you look through the code for these, you'll find how to add and configure
> sorters based on column selection in a TableViewer.  In particular see
> TaskList#createColumns.  Hope this helps!