Ejemplo n.º 1
0
        private void ViewSearchItemOnMap(SearchItemMessage searchItem)
        {
            if (searchItem.Reason == SearchItemMessageReason.ViewOnMap)
            {
                if (SimpleIoc.Default.IsRegistered <SearchTypeModel>())
                {
                    SimpleIoc.Default.Unregister <SearchTypeModel>();
                }

                SimpleIoc.Default.Register <SearchTypeModel>(() =>
                {
                    return(new SearchTypeModel(searchType));
                });

                if (SimpleIoc.Default.IsRegistered <SearchItem>())
                {
                    SimpleIoc.Default.Unregister <SearchItem>();
                }

                SimpleIoc.Default.Register <SearchItem>(() =>
                {
                    return(searchItem.SearchItem);
                });

                NavigationService.NavigateTo("/Views/MapPointSelection.xaml");
            }
        }
Ejemplo n.º 2
0
        private void ViewSearchItemOnMap(SearchItemMessage searchItem)
        {
            if (searchItem.Reason == SearchItemMessageReason.ViewOnMap)
            {
                if (SimpleIoc.Default.IsRegistered<SearchTypeModel>())
                    SimpleIoc.Default.Unregister<SearchTypeModel>();

                SimpleIoc.Default.Register<SearchTypeModel>(() =>
                {
                    return new SearchTypeModel(searchType);
                });

                if (SimpleIoc.Default.IsRegistered<SearchItem>())
                    SimpleIoc.Default.Unregister<SearchItem>();

                SimpleIoc.Default.Register<SearchItem>(() =>
                {
                    return searchItem.SearchItem;
                });

                NavigationService.NavigateTo("/Views/MapPointSelection.xaml");
            }
        }
Ejemplo n.º 3
0
 private void MapSelect()
 {
     SearchItemMessage.Send(this, Messages.Enums.SearchItemMessageReason.ViewOnMap);
 }