This document is archived and information here might be outdated. Recommended version. |
ArcObjects namespaces > Controls > ESRI ArcGIS Controls > Interfaces > IT > ITOCBuddy2 Interface > ITOCBuddy2.LayerVisibilityChanged Method (ArcObjects .NET 10.4 SDK) |
The TOCControl calls this method to instruct the buddy that layer visibility has changed.
[Visual Basic .NET] Public Sub LayerVisibilityChanged ( _ ByVal pBasicMap As IBasicMap, _ ByVal pLayer As ILayer, _ ByVal visibility As Boolean _ )
[C#] public void LayerVisibilityChanged ( IBasicMap pBasicMap, ILayer pLayer, bool visibility );
[C++]
HRESULT LayerVisibilityChanged(
IBasicMap* pBasicMap,
ILayer* pLayer,
VARIANT_BOOL visibility
);
[C++]
Parameters pBasicMap [in]
pBasicMap is a parameter of type IBasicMap pLayer [in]
pLayer is a parameter of type ILayer visibility [in] visibility is a parameter of type VARIANT_BOOL
The LayerVisibilityChanged method is called when the visibility of a layer is changed interactively using the TOCControl.
If a layer (typically a raster layer) within a Globe is fully cached the original data source does not need to be present in order for the layer to display. To ensure that the TOCControl changes the visibility of a cached layer the LayerVisibilityChanged method ensures the Globe changes the GlobeLayerProperties.