Tableeditor [message #121299] |
Wed, 11 February 2009 22:54 |
Eclipse User |
|
|
|
Originally posted by: admin.kabe-farben.ch
Hi all
i just downloaded RAP 1.2 M5 and the problems i have with TableEditor in an
TableViewer Cell persist.
When scrolling TableViewer the TableEditor does not scroll (vertically),
When resizing columns the TableEditor does not scroll (horizontally),
I finally found a workaround i will describe here just in case other people
have the same problem:
The solution bases on the observation that a manual layout() on the
tableeditor does move the tableeditor to the correct cell.
Said that, i did the following:
1. added a MouseListener to the TableViewer
2. added a ControlListener for every TableViewer Column
3. added a SelectionListener for every TableViewer Column
now i just called layout() for every TableEditor in use (see example code
below)
public void tableEditorRefreshBug()
{
for (int i=0; i<artikelList.size(); i++)
{
Artikel bugArtikel = (Artikel) artikelList.get(i);
for (int ii=0; ii<bugArtikel.tableEditor.length; ii++)
{
if (bugArtikel.tableEditor[ii]!=null)
bugArtikel.tableEditor[ii].layout();
}
}
}
I used the MouseUp, controlResized und widgetSelected to call the code
above.
Question to the RAP-Team:
Is org.eclipse.swt.custom.TableEditor not (yet) supported?
Maybe only org.eclipse.jface.viewers.CellEditor is supported?
Thanks
Andrej
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.26397 seconds