XUL Extension in TB60: tree.columns not working

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

XUL Extension in TB60: tree.columns not working

theodore.tegos
Hello,

I have an extension for Thunderbird, still using XUL, but the preferences dialog has stopped working in TB60.

The error is that the columns attribute of a tree is now null. I do something like the following:

var tree = document.getElementById("tree-id");
var tree_column = tree.columns.getNamedColumn("tree-column-id");

The last statement above fails with the following error: "TypeError: tree.columns is null".

I have not been able to solve this with anything in https://wiki.mozilla.org/Thunderbird/Add-ons_Guide_57

I thought XUL is still supported in TB60?

Any help would be greatly appreciated.

Thanks,

-Theodore
_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird
Reply | Threaded
Open this post in threaded view
|

Re: XUL Extension in TB60: tree.columns not working

Jörg Knobloch
On 12/08/2018 01:20, [hidden email] wrote:
> var tree = document.getElementById("tree-id");
> var tree_column = tree.columns.getNamedColumn("tree-column-id");
>
> The last statement above fails with the following error: "TypeError: tree.columns is null".
>
> I have not been able to solve this with anything inhttps://wiki.mozilla.org/Thunderbird/Add-ons_Guide_57
>
> I thought XUL is still supported in TB60?

Hi,

your code looks correct, even Mozilla-central still do it like this:

https://searchfox.org/mozilla-central/source/browser/base/content/pageinfo/pageInfo.js#92

Yes, XUL and overlays are supported at TB 60.

Where is your add-on in case someone wants to take a look?

Jörg.

_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird
Reply | Threaded
Open this post in threaded view
|

Re: XUL Extension in TB60: tree.columns not working

theodore.tegos
On Monday, August 13, 2018 at 12:17:46 AM UTC+2, Jörg Knobloch wrote:

> On 12/08/2018 01:20, [hidden email] wrote:
> > var tree = document.getElementById("tree-id");
> > var tree_column = tree.columns.getNamedColumn("tree-column-id");
> >
> > The last statement above fails with the following error: "TypeError: tree.columns is null".
> >
> > I have not been able to solve this with anything inhttps://wiki.mozilla.org/Thunderbird/Add-ons_Guide_57
> >
> > I thought XUL is still supported in TB60?
>
> Hi,
>
> your code looks correct, even Mozilla-central still do it like this:
>
> https://searchfox.org/mozilla-central/source/browser/base/content/pageinfo/pageInfo.js#92
>
> Yes, XUL and overlays are supported at TB 60.
>
> Where is your add-on in case someone wants to take a look?
>
> Jörg.


Thanks for the reply Jörg.

I am the author of Xpunge, and I was hasty in posting the question. The problem was not in the statements I quoted but in the fact my tree was generated with rdf and templates.

I posted another topic with the right question, and you guys are already of great help there.

-Theodore
_______________________________________________
dev-apps-thunderbird mailing list
[hidden email]
https://lists.mozilla.org/listinfo/dev-apps-thunderbird