mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-05-22 12:45:00 +00:00
refactor: merge ViewModels.PopupHost
into ViewModels.LauncherPage
This commit is contained in:
parent
0e34a77add
commit
f06b1d5d51
14 changed files with 342 additions and 344 deletions
|
@ -70,14 +70,16 @@ namespace SourceGit.ViewModels
|
|||
|
||||
public void Edit()
|
||||
{
|
||||
if (PopupHost.CanCreatePopup())
|
||||
PopupHost.ShowPopup(new EditRepositoryNode(this));
|
||||
var activePage = App.GetLauncer().ActivePage;
|
||||
if (activePage != null && activePage.CanCreatePopup())
|
||||
activePage.Popup = new EditRepositoryNode(this);
|
||||
}
|
||||
|
||||
public void AddSubFolder()
|
||||
{
|
||||
if (PopupHost.CanCreatePopup())
|
||||
PopupHost.ShowPopup(new CreateGroup(this));
|
||||
var activePage = App.GetLauncer().ActivePage;
|
||||
if (activePage != null && activePage.CanCreatePopup())
|
||||
activePage.Popup = new CreateGroup(this);
|
||||
}
|
||||
|
||||
public void OpenInFileManager()
|
||||
|
@ -96,8 +98,9 @@ namespace SourceGit.ViewModels
|
|||
|
||||
public void Delete()
|
||||
{
|
||||
if (PopupHost.CanCreatePopup())
|
||||
PopupHost.ShowPopup(new DeleteRepositoryNode(this));
|
||||
var activePage = App.GetLauncer().ActivePage;
|
||||
if (activePage != null && activePage.CanCreatePopup())
|
||||
activePage.Popup = new DeleteRepositoryNode(this);
|
||||
}
|
||||
|
||||
private string _id = string.Empty;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue