|
Re: [jface] TableViewer and ContentProvider... [message #48907 is a reply to message #48660] |
Wed, 12 March 2003 23:38 |
Eclipse User |
|
|
|
Originally posted by: notvalid.hotmail.com
I am a newbie with SWT, but since I have been working on the exact same
thing here is my explanation which may help.
The array of objects you give to viewer.setInput() will be sent as an array
to the contentprovider's getElements(). Each index of the array will
correspond to a row. The contenprovider in turn sends each object of the
array one at a time, to the labelprovider's method , getImage and getText.
These labelprovider methods iterate over the columns for that row, where the
row is the objecte passed from the contentprovider.
I hope that helps...
"Ozgur Kurt" <ozgurkurt@hotmail.com> wrote in message
news:b4kf5u$hif$1@rogue.oti.com...
> hi all,
>
> i have a table viewer, and i wrote a contentprovider and a labelprovider
for
> it, but things don't go as i expected. in the method "public Object[]
> getElements(Object inputElement)" i return an array of objects, but this
> function is not called for each member of the returned array later... this
> is confusing, what i'm doing wrong?
>
>
> thanx,
> ozgur
>
>
|
|
|
|
Re: [jface] TableViewer and ContentProvider... [message #591566 is a reply to message #48660] |
Wed, 12 March 2003 23:38 |
Eclipse User |
|
|
|
Originally posted by: notvalid.hotmail.com
I am a newbie with SWT, but since I have been working on the exact same
thing here is my explanation which may help.
The array of objects you give to viewer.setInput() will be sent as an array
to the contentprovider's getElements(). Each index of the array will
correspond to a row. The contenprovider in turn sends each object of the
array one at a time, to the labelprovider's method , getImage and getText.
These labelprovider methods iterate over the columns for that row, where the
row is the objecte passed from the contentprovider.
I hope that helps...
"Ozgur Kurt" <ozgurkurt@hotmail.com> wrote in message
news:b4kf5u$hif$1@rogue.oti.com...
> hi all,
>
> i have a table viewer, and i wrote a contentprovider and a labelprovider
for
> it, but things don't go as i expected. in the method "public Object[]
> getElements(Object inputElement)" i return an array of objects, but this
> function is not called for each member of the returned array later... this
> is confusing, what i'm doing wrong?
>
>
> thanx,
> ozgur
>
>
|
|
|
|
Powered by
FUDForum. Page generated in 0.03495 seconds