Example #1
0
        public View()
        {
            InitializeComponent();

            if (WpfHelper.GetIsInDesignMode())
            {
                return;
            }

            this._shapeDataList = MapUtilities.LoadUserShapeData();
            SwitchToDisplayButton_Click(null, null);
        }
Example #2
0
        private void SaveButton_Click(object sender, RoutedEventArgs e)
        {
            var layout = this._mapContainer.Content as LayoutView;

            if (layout != null)
            {
                layout.SaveShapeDataList();

                //save to DB
                MapUtilities.SaveUserShapeData(layout.ShapeDataList);
                this._shapeDataList  = MapUtilities.LoadUserShapeData();
                layout.ShapeDataList = this._shapeDataList;
                layout.LoadMap();
            }
        }