Eclipse Community Forums - RDF feed
https://www.eclipse.org/forums/
Eclipse Community ForumsCommon Navigator "navigatorContent" fails
https://www.eclipse.org/forums/index.php/mv/msg/157050/495167/#msg_495167
I have a working CNF in my RCP -- nice navigator appears, shows the
workspace, actions like "New -> Folder" work, all fine. I've added a
bunch of objectContribution's, all of which work.
I have a content-provider and a label-provider and a bunch of XML that
(to me) looks essentially identical to what is in the help docs ...
But all I get when I try to expand the resource-type to which I've tried
to attach the extra content is an error message: "Error: no label
provider for ..." (and then the path of the resource).
The fact that the CNF offers a child of the resource-type to which I've
tried to attach the extra content indicates that some part of the
plugging in worked.
Obviously almost anything could be wrong, but does that error provide
any sort of clue as to where to look? And what hints are there for
debugging this? (For example, since my content-provider and
label-provider are not being called, no point in setting breakpoints in
them ...)
-Paul]]>Paul E. Keyser2009-11-04T00:38:04-00:00Re: Common Navigator "navigatorContent" fails
https://www.eclipse.org/forums/index.php/mv/msg/157050/495927/#msg_495927
> R3.4.2 (no, we can't migrate to 3.5 yet), WinXP
>
> But all I get when I try to expand the resource-type to which I've tried
> to attach the extra content is an error message: "Error: no label
> provider for ..." (and then the path of the resource).
>
Found it -- the bug was (no surprise) in my code: I was returning a
value of type Foo from the ContentProvider and the LabelProvider would
return null for a value of type Foo. The example code does have a
label-provider returning null for unhandled types ... and evidently the
CNF handles a null from a LabelProvider by displaying that somewhat
cryptic error.
A clearer error-message might help:
"Available label-providers all returned null for ..."
-Paul]]>Paul E. Keyser2009-11-06T16:36:19-00:00Re: Common Navigator "navigatorContent" fails
https://www.eclipse.org/forums/index.php/mv/msg/157050/499485/#msg_499485
Paul E. Keyser wrote on Fri, 06 November 2009 11:36
Paul E. Keyser wrote:
A clearer error-message might help:
"Available label-providers all returned null for ..."