Skip to content

Commit adbc3c5

Browse files
committed
Cosmetics
1 parent 741b524 commit adbc3c5

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

ED-Router.UI.Desktop/ViewModel/MainViewModel.cs

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,8 @@ public MainViewModel()
4646
MyRoute = new ObservableCollection<SystemJump>();
4747
From = new ObservableCollection<string>();
4848
To = new ObservableCollection<string>();
49+
_fromSearch = Router.Start;
50+
_toSearch = Router.Destination;
4951
}
5052

5153
public ICommand CalculateCommand { get; private set; }
@@ -84,6 +86,12 @@ public string FromSearch
8486
if (suggestionSystems.Contains(sys) == false)
8587
From.Remove(sys);
8688
}
89+
90+
// pass the Name to the underlying router
91+
if (suggestionSystems.Contains(value))
92+
{
93+
Router.Destination = value;
94+
}
8795
}
8896
}
8997
}
@@ -113,6 +121,12 @@ public string ToSearch
113121
if (suggestionSystems.Contains(sys) == false)
114122
To.Remove(sys);
115123
}
124+
125+
// pass the Name to the underlying router
126+
if (suggestionSystems.Contains(value))
127+
{
128+
Router.Destination = value;
129+
}
116130
}
117131
}
118132
}

0 commit comments

Comments
 (0)