|Re: [platform-ui-dev] AbstractTableViewer virtualSetSelectionToWidget()|
Boris,When I first looked at virtualSetSelectionToWidget(), I was hoping that it was supporting "virtual selection", but after looking at the code further, that appears to not be the case. I hacked the code a bit, and came up with a solution that seems to support virtual selection, but it needs more work and testing.
Basically, I need a way to call viewer.setSelection() and not have the underlying TableItems created.
Bryan On Oct 21, 2008, at 12:19 PM, Boris Bokowski wrote:
The method's signature is:AbstractTableViewer.virtualSetSelectionToWidget(List elements, boolean reveal)So we have a list of elements but need to set the selection in terms of items, or item indices. If there are elements in the list for which we cannot find an item using findItem(Object element), it means that we have to look for those items by materializing them through the content provider. Maybe I am missing something, but given the current structure I don't think we have any other choice. There is a comment in virtualSetSelectionToWidget() that recommends using getTable().setSelection(int, boolean) instead, have you tried that? Boris On Fri, Oct 17, 2008 at 3:46 PM, Bryan Hunt <bhunt@xxxxxxx> wrote:Why does AbstractTableViewer.virtualSetSelectionToWidget() call doGetItem()? This causes the table item to be loaded if it does not exist and seems todefeat the purpose of a virtual selection. I figure I'm missing someimportant technical detail here. We really need virtual selection to bevirtual. https://bugs.eclipse.org/bugs/show_bug.cgi?id=246417 Bryan _______________________________________________ platform-ui-dev mailing list platform-ui-dev@xxxxxxxxxxx https://dev.eclipse.org/mailman/listinfo/platform-ui-dev_______________________________________________ platform-ui-dev mailing list platform-ui-dev@xxxxxxxxxxx https://dev.eclipse.org/mailman/listinfo/platform-ui-dev
Back to the top