mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-22 20:54:59 +00:00
refactor(PopupManager): rewrite popup
This commit is contained in:
parent
28e3a1bb27
commit
7558bbd4f2
34 changed files with 183 additions and 221 deletions
|
@ -59,7 +59,7 @@ namespace SourceGit.UI {
|
|||
var current = repo.CurrentBranch();
|
||||
if (current == null) return;
|
||||
|
||||
App.GetPopupManager(repo)?.Show(new Reset(repo, current, commit));
|
||||
repo.GetPopupManager()?.Show(new Reset(repo, current, commit));
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
@ -71,7 +71,7 @@ namespace SourceGit.UI {
|
|||
var mode = combMode.SelectedItem as Mode;
|
||||
if (mode == null) return;
|
||||
|
||||
var popup = App.GetPopupManager(repo);
|
||||
var popup = repo.GetPopupManager();
|
||||
popup?.Lock();
|
||||
await Task.Run(() => repo.Reset(revision, mode.Arg));
|
||||
popup?.Close(true);
|
||||
|
@ -83,7 +83,7 @@ namespace SourceGit.UI {
|
|||
/// <param name="sender"></param>
|
||||
/// <param name="e"></param>
|
||||
private void Cancel(object sender, RoutedEventArgs e) {
|
||||
App.GetPopupManager(repo)?.Close();
|
||||
repo.GetPopupManager()?.Close();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue