コード例 #1
0
        private void MapLayer_Initialized(object sender, EventArgs e)
        {
            bool mapIsLoaded = true;

            foreach (Layer layer in myMap.Layers)
            {
                if (!layer.IsInitialized)
                {
                    mapIsLoaded = false; break;
                }

                if (layer is FeatureLayer)
                {
                    FeatureLayer     fLayer  = layer as FeatureLayer;
                    FeatureLayerInfo lyrInfo = fLayer.LayerInfo;
                    if (lyrInfo != null)
                    {
                        fLayer.MapTip = new MapTipPopup(lyrInfo.Fields, fLayer.OutFields, lyrInfo.DisplayField, lyrInfo.Name)
                        {
                            ShowArrow = false, ShowCloseButton = false, Background = this.myTaskbarWidget.Background
                        };
                    }
                }
            }

            if (mapIsLoaded)
            {
                InitializeMapUnits();
                InitializeMapExtent();
                EventCenter.DispatchMapLoadCompleteEvent(this.myMap, new RoutedEventArgs());
            }
        }