Exemplo n.º 1
0
        private void SwitchToStations()
        {
            isStopSearch = true;

            StationsVisibility = Visibility.Visible;
            SearchVisibility   = Visibility.Collapsed;

            SelectedStationVisibility     = Visibility.Collapsed;
            SelectedCustomPointVisibility = Visibility.Collapsed;
            SelectedSearchItemVisibility  = Visibility.Collapsed;

            if (isPointA)
            {
                PointA.Hide();
            }
            else
            {
                PointB.Hide();
            }

            MapSearchResults.Clear();

            ClearSearchTextBox();

            ShowStopsList();
        }
Exemplo n.º 2
0
        private void PointBClick()
        {
            if (this.isPointA)
            {
                PointB.Select();

                this.isPointA = false;

                PointA.Deselect();

                if (PointB.HasValue())
                {
                    if (PointB.Station == null && PointB.CustomPoint == null)
                    {
                        SelectedSearchItemForView = PointB.SearchItem;

                        SelectedStationVisibility     = Visibility.Collapsed;
                        SelectedSearchItemVisibility  = Visibility.Visible;
                        SelectedCustomPointVisibility = Visibility.Collapsed;
                    }
                    else if (PointB.SearchItem == null && PointB.CustomPoint == null)
                    {
                        SelectedStationForView = PointB.Station;

                        SelectedSearchItemVisibility  = Visibility.Collapsed;
                        SelectedStationVisibility     = Visibility.Visible;
                        SelectedCustomPointVisibility = Visibility.Collapsed;
                    }
                    else
                    {
                        SelectedCustomPointForView = PointB.CustomPoint;

                        SelectedSearchItemVisibility  = Visibility.Collapsed;
                        SelectedStationVisibility     = Visibility.Collapsed;
                        SelectedCustomPointVisibility = Visibility.Visible;
                    }

                    PointB.Show();
                }
                else
                {
                    PointB.Hide();
                    SelectedStationVisibility     = Visibility.Collapsed;
                    SelectedSearchItemVisibility  = Visibility.Collapsed;
                    SelectedCustomPointVisibility = Visibility.Collapsed;
                }
            }
        }