Пример #1
0
        private void GisInterfaceMgr_Loaded(object sender, RoutedEventArgs e)
        {
            // Configure Gesture Toolkit
            GestureFramework.Initialize(touchProvider, LayoutRoot, Assembly.GetExecutingAssembly());
            //GestureFramework.ShowDebugPanel(GestureFramework.DebugPanels.GestureRecorder);
            GestureFramework.AddTouchFeedback(typeof(BubblesPath));
            //This feedback allows the user to see which area has been selected by the gesture
            //GestureFramework.AddGesturFeedback(Gestures.Lasso, typeof(TouchToolkit.GestureProcessor.Feedbacks.GestureFeedbacks.HighlightSelectedArea));
            GestureFramework.EventManager.BubbleUpUnhandledEvents = true;

            // Initialize the mapLayersManager
            MapLayersManager layersMgr = MapLayersManager.Instance;
            layersMgr.setDefaultLayerTypes(defaultLayerTypes);
            layersMgr.InitializeDefaultMapLayers();

            bookmarklist = BookmarkList.Instance;
            bookmarklist.initializeBookmarkList(bookmarks);

            mapframefact = MapFrameFactory.Instance;

            // Create the instance of the Background map layer
            backgroundLayer = BackgroundMapLayer.Instance;
            backgroundLayer.setLayoutProperties(LayoutRoot.Width, LayoutRoot.Height, MapOrientation);
            backgroundLayer.allowManipulationOfBgMap(allowBgManip);
            // Called last to put the properties in effect
            backgroundLayer.InitializeBackgroundMap(BackgroundMapExtent);

            cornermenusmgr = CornerMenusMgr.Instance;
            cornermenusmgr.setLayoutRoot(LayoutRoot);
            cornermenusmgr.MenuType = cornerMenuType;
            cornermenusmgr.CreateCornerMenus();
            cornermenusmgr.CreateExitDialogs();

            LayoutRoot.Children.Add(backgroundLayer);
        }
Пример #2
0
 static BackgroundMapLayer()
 {
     Instance = new BackgroundMapLayer();
 }