[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Newsgroup Home]
|
[news.eclipse.platform.swt] Re: Tableviewer refresh scrolls to selection
|
Hi,
1. There is a bug in setSelection(ISelection,boolean)
https://bugs.eclipse.org/bugs/show_bug.cgi?id=164796
The patch if accepted would also introduce a method to control the
scrolling behaviour when calling refresh.
2. For 3.2 and before you need to make the whole thing yourself
https://bugs.eclipse.org/bugs/show_bug.cgi?id=164797
Tom
cse schrieb:
Apologies, yes I found the article you refer to:
http://www.eclipse.org/newsportal/article.php?id=32022&group=eclipse.platform.swt#32022
I tried your solution of removing the selection, refreshing, then
reselecting the old selection. Unfortunately when calling
tableviewer.setSelection() to put the old selection back, it again
causes the table to autoscroll to that item/row.
The other risk is if there are listeners on the tableviewer looking for
selection change events, they would receive 2 selection change events
which may cause unecessary updates. Of course there are workarounds for
this but ideally it would be nice to have the ability to turn off the
auto-scrolling feature if required.
Is there any other way to fix this? Also Im not sure how to log a
feature request etc that you mentioned in the other thread. Could you
please provide some details?