@@ -12,6 +12,12 @@ namespace SourceGit.ViewModels
1212{
1313 public class BranchCompare : ObservableObject
1414 {
15+ public bool IsLoading
16+ {
17+ get => _isLoading ;
18+ private set => SetProperty ( ref _isLoading , value ) ;
19+ }
20+
1521 public Models . Branch Base
1622 {
1723 get => _based ;
@@ -101,6 +107,8 @@ public void NavigateTo(string commitSHA)
101107 public void Swap ( )
102108 {
103109 ( Base , To ) = ( _to , _based ) ;
110+
111+ VisibleChanges = [ ] ;
104112 SelectedChanges = [ ] ;
105113
106114 if ( _baseHead != null )
@@ -166,6 +174,7 @@ public ContextMenu CreateChangeContextMenu()
166174 await App . CopyTextAsync ( change . Path ) ;
167175 ev . Handled = true ;
168176 } ;
177+ menu . Items . Add ( new MenuItem ( ) { Header = "-" } ) ;
169178 menu . Items . Add ( copyPath ) ;
170179
171180 var copyFullPath = new MenuItem ( ) ;
@@ -184,6 +193,8 @@ public ContextMenu CreateChangeContextMenu()
184193
185194 private void Refresh ( )
186195 {
196+ IsLoading = true ;
197+
187198 Task . Run ( async ( ) =>
188199 {
189200 if ( _baseHead == null )
@@ -221,6 +232,7 @@ private void Refresh()
221232 Dispatcher . UIThread . Post ( ( ) =>
222233 {
223234 VisibleChanges = visible ;
235+ IsLoading = false ;
224236
225237 if ( VisibleChanges . Count > 0 )
226238 SelectedChanges = [ VisibleChanges [ 0 ] ] ;
@@ -253,6 +265,7 @@ private void RefreshVisible()
253265 }
254266
255267 private string _repo ;
268+ private bool _isLoading = true ;
256269 private Models . Branch _based = null ;
257270 private Models . Branch _to = null ;
258271 private Models . Commit _baseHead = null ;
0 commit comments