Пример #1
0
 private AccountItemViewModel CreateAccountItem(GitHubAccount githubAccount)
 {
     var viewModel = new AccountItemViewModel();
     viewModel.Account = githubAccount;
     viewModel.Selected = Equals(githubAccount, ActiveAccount);
     viewModel.DeleteCommand.Subscribe(_ => DeleteAccountCommand.ExecuteIfCan(githubAccount));
     viewModel.SelectCommand.Subscribe(_ => LoginCommand.ExecuteIfCan(githubAccount));
     return viewModel;
 }
Пример #2
0
        private AccountItemViewModel CreateAccountItem(GitHubAccount githubAccount)
        {
            var viewModel = new AccountItemViewModel(githubAccount);

            viewModel.Selected = Equals(githubAccount, ActiveAccount);
            viewModel.DeleteCommand.Subscribe(_ => DeleteAccount(githubAccount));
            viewModel.GoToCommand.Subscribe(_ => LoginAccount(githubAccount));
            return(viewModel);
        }
Пример #3
0
 private AccountItemViewModel CreateAccountItem(GitHubAccount githubAccount)
 {
     var viewModel = new AccountItemViewModel(githubAccount);
     viewModel.Selected = Equals(githubAccount, ActiveAccount);
     viewModel.DeleteCommand.Subscribe(_ => DeleteAccount(githubAccount));
     viewModel.GoToCommand.Subscribe(_ => LoginAccount(githubAccount));
     return viewModel;
 }