mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-25 22:25:00 +00:00
refactor: change the way to refresh repository's data.
* mark dirty instead of calling refresh method directly * force mark branches data dirty after remotes changed
This commit is contained in:
parent
3eb8a82005
commit
a89760c7a5
6 changed files with 33 additions and 17 deletions
|
@ -734,7 +734,7 @@ namespace SourceGit.Views {
|
|||
new Commands.Apply(ctx.RepositoryPath, tmpFile, true, "nowarn", "--cache --index").Exec();
|
||||
File.Delete(tmpFile);
|
||||
|
||||
repo.RefreshWorkingCopyChanges();
|
||||
repo.MarkWorkingCopyDirtyManually();
|
||||
repo.SetWatcherEnabled(true);
|
||||
e.Handled = true;
|
||||
};
|
||||
|
@ -760,7 +760,7 @@ namespace SourceGit.Views {
|
|||
new Commands.Apply(ctx.RepositoryPath, tmpFile, true, "nowarn", "--reverse").Exec();
|
||||
File.Delete(tmpFile);
|
||||
|
||||
repo.RefreshWorkingCopyChanges();
|
||||
repo.MarkWorkingCopyDirtyManually();
|
||||
repo.SetWatcherEnabled(true);
|
||||
e.Handled = true;
|
||||
};
|
||||
|
@ -788,7 +788,7 @@ namespace SourceGit.Views {
|
|||
new Commands.Apply(ctx.RepositoryPath, tmpFile, true, "nowarn", "--cache --index --reverse").Exec();
|
||||
File.Delete(tmpFile);
|
||||
|
||||
repo.RefreshWorkingCopyChanges();
|
||||
repo.MarkWorkingCopyDirtyManually();
|
||||
repo.SetWatcherEnabled(true);
|
||||
e.Handled = true;
|
||||
};
|
||||
|
@ -814,7 +814,7 @@ namespace SourceGit.Views {
|
|||
new Commands.Apply(ctx.RepositoryPath, tmpFile, true, "nowarn", "--index --reverse").Exec();
|
||||
File.Delete(tmpFile);
|
||||
|
||||
repo.RefreshWorkingCopyChanges();
|
||||
repo.MarkWorkingCopyDirtyManually();
|
||||
repo.SetWatcherEnabled(true);
|
||||
e.Handled = true;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue