[Users] GeoExt Legend Tree and base layers ?
Alexandre Dube
adube at mapgears.com
Fri Jan 7 19:33:32 CET 2011
Hi,
I'm not sure about the origin of your issue, but looking at the
following non-official ux might help you find it (since I managed to do
that) :
http://dev.geoext.org/sandbox/mapgears/geoext.ux/ux/LayerTreeBuilder/examples/tree-builder.html
I hope this helps,
Alexandre
On 11-01-07 12:21 PM, karsten vennemann wrote:
> Hi,
> really nobody has a hint how to do this ?
> Karsten
>
> ------------------------------------------------------------------------
> *From:* karsten vennemann [mailto:karsten at terragis.net]
> *Sent:* Wednesday, January 05, 2011 16:12
> *To:* 'users at geoext.org'
> *Subject:* GeoExt Legend Tree and base layers ?
>
> Hi all,
> have a GeoExt Legend Tree below and wanted to enable more base
> layers to be shown (no legend needed for those in) it too. The one
> below work already with OSM and shows up as a radio button. Now I
> would like to add back into my app google and yahoo base layers.
> However, if I just add them to Openlayer the tree does not show
> anything any more.
> What do I need to change in my tree legend below to enable base
> layers otehr than OSM to work. I tried adding a nodeType:
> "gx_baselayercontainer" but could not gte it to work. It will be
> something like in http://api.geoext.org/1.0/examples/tree.html but
> with legend icons ...
> I have this :
> var tree = new Ext.tree.TreePanel({
> title: "Ebenen",
> width: 250,
> autoScroll: true,
> enableDD: true,
> // apply the tree node component plugin to layer nodes
> plugins: [{
> ptype: "gx_treenodecomponent"
> }],
> loader: {
> applyLoader: false,
> uiProviders: {
> "custom_ui": LayerNodeUI
> }
> },
> root: {nodeType: "gx_layercontainer",
> loader: {
> baseAttrs: {
> uiProvider: "custom_ui"
> },
> createNode: function(attr) {
> // add a WMS legend to each node created
> attr.component = {
> xtype: "gx_wmslegend",
> layerRecord:
> mapPanel.layers.getByLayer(attr.layer),
> showTitle: false,
> // custom class for css positioning
> // see tree-legend.html
> cls: "legend"
> }
> return
> GeoExt.tree.LayerLoader.prototype.createNode.call(this, attr);
> }
> }
> },
> rootVisible: false,
> lines: false
> });
> Thanks
> Karsten
>
>
> _______________________________________________
> Users mailing list
> Users at geoext.org
> http://www.geoext.org/cgi-bin/mailman/listinfo/users
--
Alexandre Dubé
Mapgears
www.mapgears.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.geoext.org/pipermail/users/attachments/20110107/2193ec0b/attachment.htm
More information about the Users
mailing list