コード例 #1
0
        public BrowserProfileViewModel(IBrowserStateNotificationService browserStateNotificationService, IMediator mediator, BrowserProfile browserProfile)
        {
            _browserProfile = browserProfile;

            Browser = new BrowserViewModel(browserStateNotificationService, mediator, _browserProfile.Browser);
            Profile = new ProfileViewModel(browserStateNotificationService, mediator, _browserProfile.Profile);
        }
コード例 #2
0
ファイル: ProfileViewModel.cs プロジェクト: BEzGumpTion/Burls
        public ProfileViewModel(IBrowserStateNotificationService browserStateNotificationService, IMediator mediator, Profile profile)
        {
            _browserStateNotificationService = browserStateNotificationService;
            _mediator = mediator;
            _profile  = profile;

            SelectionRules = new ObservableCollection <SelectionRuleViewModel>(_profile.SelectionRules.Select(x => new SelectionRuleViewModel(mediator, x)));

            _browserStateNotificationService.SelectionRuleCreated += _browserStateNotificationService_SelectionRuleCreated;
            _browserStateNotificationService.SelectionRuleDeleted += _browserStateNotificationService_SelectionRuleDeleted;

            AddSelectionRuleCommand = new RelayCommand(async() => await AddNewSelectionRule());
        }
コード例 #3
0
 public ProfileSelectionRuleDeletedNotificationHandler(IBrowserStateNotificationService browserStateNotificationService)
 {
     _browserStateNotificationService = browserStateNotificationService;
 }
コード例 #4
0
        public BrowserViewModel(IBrowserStateNotificationService browserStateNotificationService, IMediator mediator, Browser browser)
        {
            _browser = browser;

            Profiles = new ObservableCollection <ProfileViewModel>(_browser.Profiles.Select(x => new ProfileViewModel(browserStateNotificationService, mediator, x)));
        }