예제 #1
0
 public void Initalise()
 {
     viewModel = container.Resolve<SharesViewModel>();
     browser = container.Resolve<QueryViewModel>();
     viewModel.AddCommand = new DelegateCommand(AddCommand);
     viewModel.RefreshCommand = new DelegateCommand(RefreshCommand);
     viewModel.RemoveCommand = new DelegateCommand(RemoveCommand);
     viewModel.RenameCommand = new DelegateCommand(RenameCommand);
     viewModel.Shares = new SafeObservingCollection<Share>(model.Shares);
     RefreshClientStats();
 }
예제 #2
0
 public void Initaize()
 {
     if (null == viewModel)
     {
         browser = container.Resolve<QueryViewModel>();
         viewModel = container.Resolve<SettingsViewModel>();
         viewModel.Model = model;
         viewModel.EditDownloadDir = new DelegateCommand(SettingsEditDownloadDir);
         viewModel.ChangeAvatar = new DelegateCommand(ChangeAvatar);
         viewModel.ResetInterface = new DelegateCommand(ResetInterface);
         viewModel.DisplayQuickStart = new DelegateCommand(DisplayQuickStart);
     }
 }