Hello,
I want to know if there is a way to expand RootLayer at the LayerList widget startup.
Thanks,
Naty
Naty,
Sure add this code block to the end of the _initOperations function in the LayerListView.js file:
this.own(on(this.operationsDropMenu ,
'onMenuClick',
lang.hitch(this, this._onOperationsMenuItemClick)));
setTimeout(lang.hitch(this, function(){
this.foldOrUnfoldAllRootLayers(false);
}), 300);
Thanks Robert!
And can I hide root node?
Naty
Not that I know of. Why would you want to? If the root was hidden how would you change it's visibility?
Its visibility must always be active and it's redundant to see it in LayerList.
Naty
Naty,
Maybe a screen shot would help explain better, because I do not understand.
I just have only one operational layer...and I want to remove the root Level
I had very much like to do same too
Me too!
Naty,
OK, so you have a Map Service that only has one layer and you have the MapService name the same as the one layer that that service contains. Hmm. I will have to think about this, as it is not common practice for a GIS data manager/publisher to have a scenario like that.