• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

C# IShellViewModel类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了C#中IShellViewModel的典型用法代码示例。如果您正苦于以下问题:C# IShellViewModel类的具体用法?C# IShellViewModel怎么用?C# IShellViewModel使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



IShellViewModel类属于命名空间,在下文中一共展示了IShellViewModel类的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C#代码示例。

示例1: ShellView

 public ShellView(
     IShellViewModel viewModel)
 {
     InitializeComponent();
     DataContext = viewModel;
     viewModel.Dispatcher = Dispatcher;
 }
开发者ID:gan123,项目名称:Productivity-Tracker,代码行数:7,代码来源:ShellView.xaml.cs


示例2: CashFlowTypesViewModel

        public CashFlowTypesViewModel(IShellViewModel shell, IDatabase database, IConfigurationManager configuration, ICachedService cashedService, IEventAggregator eventAggregator)
            : base(shell, database, configuration, cashedService, eventAggregator)
        {
            SuppressEvent = false;
            _cashFlows = new BindableCollectionExt<CashFlow>();
            _cashFlows.PropertyChanged += (s, e) =>
            {
                OnPropertyChanged(s, e);
                CachedService.Clear(CachedServiceKeys.AllCashFlows);
            };

            _cashFlowGroups = new BindableCollectionExt<CashFlowGroup>();
            _cashFlowGroups.PropertyChanged += (s, e) =>
            {
                if (SuppressEvent == true)
                {
                    return;
                }
                OnPropertyChanged(s, e);

                CachedService.Clear(CachedServiceKeys.AllCashFlowGroups);
                CachedService.Clear(CachedServiceKeys.AllCashFlows);
                var cashFlowGroup = s as CashFlowGroup;
                _cashFlows.Where(x => x.CashFlowGroupId == cashFlowGroup.Id)
                    .ForEach(x => x.Group = cashFlowGroup);
                NewCashFlowGroup = null;
                NewCashFlowGroup = CashFlowGroups.First();
            };
        }
开发者ID:adalbertus,项目名称:BudgetPlanner,代码行数:29,代码来源:CashFlowTypesViewModel.cs


示例3: DownloadAndUpgradeViewModel

 public DownloadAndUpgradeViewModel(IShellViewModel shell, IDatabase database, IConfigurationManager configuration, ICachedService cashedService, IEventAggregator eventAggregator)
     : base(shell, database, configuration, cashedService, eventAggregator)
 {
     _webClient = new WebClient();
     _webClient.DownloadFileCompleted += OnDownloadFileCompleted;
     _webClient.DownloadProgressChanged += OnDownloadProgressChanged;
 }
开发者ID:adalbertus,项目名称:BudgetPlanner,代码行数:7,代码来源:DownloadAndUpgradeViewModel.cs


示例4: ShellView

        public ShellView(IShellViewModel vm)
        {
            vm.FileProgressStatusChanged += OnFileProgressStatusChanged;
            vm.FileProgressChanged += OnFileProgressChanged;

            DataContext = vm;
            InitializeComponent();
        }
开发者ID:LionFree,项目名称:Cush,代码行数:8,代码来源:ShellView.xaml.cs


示例5: ShellView

        public ShellView(IShellViewModel model, IMessageBus bus)
            : this()
        {
            _bus = bus;
            DataContext = model;

            Loaded += OnLoaded;
        }
开发者ID:ArildF,项目名称:Core,代码行数:8,代码来源:ShellView.xaml.cs


示例6: BudgetViewModel

 public BudgetViewModel(IShellViewModel shell, IDatabase database, IConfigurationManager configuration, ICachedService cashedService, IEventAggregator eventAggregator)
     : base(shell, database, configuration, cashedService, eventAggregator)
 {
     ExpensesViewModel   = IoC.Get<ExpensesViewModel>();
     RevenuesViewModel   = IoC.Get<RevenuesViewModel>();
     BudgetPlanViewModel = IoC.Get<BudgetPlanViewModel>();
     BudgetCalculatorViewModel = IoC.Get<BudgetCalculationsViewModel>();
 }
开发者ID:adalbertus,项目名称:BudgetPlanner,代码行数:8,代码来源:BudgetViewModel.cs


示例7: Shell

    public Shell(IShellViewModel viewModel) {
      InitializeComponent();
      ViewModel = viewModel;
/*
      MenuCanvas.SetValue(Canvas.LeftProperty, MainGrid.ActualWidth);
      MenuCanvas.SetValue(Canvas.TopProperty, 15.0);
*/

    }
开发者ID:Rushman1,项目名称:PictureViewer,代码行数:9,代码来源:Shell.xaml.cs


示例8: ShellController

 public ShellController(
     IShellViewModel shellViewModel,
     IShellView shellView,
     IMainController mainController)
 {
     _shellViewModel = shellViewModel;
     _shellView = shellView;
     _mainController = mainController;
     _shellView.ViewModel = _shellViewModel;
 }
开发者ID:halcharger,项目名称:WpfAppTemplate,代码行数:10,代码来源:ShellController.cs


示例9: TestInitialize

 public void TestInitialize()
 {
     shell = Substitute.For<IShellViewModel>();
     serviceControl = Substitute.For<IServiceControl>();
     settingsProvider = Substitute.For<ISettingsProvider>();
     connection = Substitute.For<IServiceControlConnectionProvider>();
     container = RegisterContainer();
     storedSetting = GetReloadedSettings();
     settingsProvider.GetSettings<ProfilerSettings>().Returns(storedSetting);
     connectTo = new ServiceControlConnectionViewModel(settingsProvider, container) { Parent = shell }; //TODO: Do we need to pass the full container here?
 }
开发者ID:nanohex,项目名称:ServiceInsight,代码行数:11,代码来源:ServiceControlConnectionDialogTests.cs


示例10: ShellView

        public ShellView(IShellViewModel vm, IToolbarView toolbarView, ITaskBoardView taskBoardView)
            : this()
        {
            DataContext = vm;

            mainGrid.Children.Add(toolbarView.Element);
            Grid.SetRow(toolbarView.Element, 0);

            mainGrid.Children.Add(taskBoardView.Element);
            Grid.SetRow(taskBoardView.Element, 1);
        }
开发者ID:ArildF,项目名称:PTB,代码行数:11,代码来源:ShellView.xaml.cs


示例11: DefaultExceptionHandler

 public DefaultExceptionHandler(
     IWindowManagerEx windowManager, 
     IViewModelFactory screenFactory,
     IAppCommands appCommands, 
     IEventAggregator eventAggregator,
     IShellViewModel shell) 
     : base(windowManager, screenFactory)
 {
     _windowManager = windowManager;
     _appCommands = appCommands;
     _eventAggregator = eventAggregator;
     _shell = shell;
 }
开发者ID:roycornelissen,项目名称:ServiceInsight,代码行数:13,代码来源:QueueExceptionHandler.cs


示例12: ShellView

        public ShellView(IShellViewModel vm, IMessageBus bus, IModuleResolver resolver, ISettings settings)
            : this()
        {
            _bus = bus;
            _resolver = resolver;
            _settings = settings;
            DataContext = vm;

            _bus.Listen<ActivateMainModuleMessage>().Subscribe(msg => ActivateMainModule(msg.ModuleName));
            _bus.Listen<NavigateMainModuleMessage>().Subscribe(msg => NavigateMainModule(msg.ModuleName));
            _bus.Listen<NavigateBackMainModuleMessage>().Where(_ => _navigationStack.Count > 0).Subscribe(
                _ => NavigateBack());

            _bus.Listen<SettingsChangedMessage>().Subscribe(OnSettingsChanged);
        }
开发者ID:Doomblaster,项目名称:MetroFire,代码行数:15,代码来源:ShellView.xaml.cs


示例13: setup

		private void setup()
		{
			var ns = new NavigationService(this, Resource.Id.content_frame);
			navService = ns;

			ns.RegisterFragment<ISettingsViewModel, SettingsFragment>();
			ns.RegisterFragment<ILoginViewModel, LoginFragment>();
			ns.RegisterFragment<IHomeViewModel, HomeFragment>();

			ViewModelLocator.Container.RegisterInstance<INavigationService>(navService);
			var container = ViewModelLocator.Container;

			ISharedPreferences prefs =  PreferenceManager.GetDefaultSharedPreferences(this);
			var settings = new AppSettings(prefs);
			settings.ServerUrl = null;

			container.RegisterInstance<ISettings>(settings);

			vm = container.Resolve<IShellViewModel>();
			vm.PropertyChanged += vmPropertyChanged;
		}
开发者ID:holtsoftware,项目名称:House,代码行数:21,代码来源:MainActivity.cs


示例14: OptionsViewModel

        /// <summary>
        /// Initializes a new instance of the <see cref="OptionsViewModel"/> class.
        /// </summary>
        /// <param name="userSettingService">
        /// The user Setting Service.
        /// </param>
        /// <param name="shellViewModel">
        /// The shell View Model.
        /// </param>
        /// <param name="updateService">
        /// The update Service.
        /// </param>
        public OptionsViewModel(IUserSettingService userSettingService, IShellViewModel shellViewModel, IUpdateService updateService)
        {
            this.Title = "Options";
            this.userSettingService = userSettingService;
            this.shellViewModel = shellViewModel;
            this.updateService = updateService;
            this.OnLoad();

            this.SelectedTab = OptionsTab.General;
            this.UpdateMessage = "Click 'Check for Updates' to check for new versions";
        }
开发者ID:kevleyski,项目名称:HandBrake,代码行数:23,代码来源:OptionsViewModel.cs


示例15: MainViewModel

        /// <summary>
        /// Initializes a new instance of the <see cref="MainViewModel"/> class.
        /// The viewmodel for HandBrakes main window.
        /// </summary>
        /// <param name="userSettingService">
        /// The User Setting Service
        /// </param>
        /// <param name="scanService">
        /// The scan Service.
        /// </param>
        /// <param name="encodeService">
        /// The encode Service.
        /// </param>
        /// <param name="presetService">
        /// The preset Service.
        /// </param>
        /// <param name="errorService">
        /// The Error Service
        /// </param>
        /// <param name="shellViewModel">
        /// The shell View Model.
        /// </param>
        /// <param name="updateService">
        /// The update Service.
        /// </param>
        /// <param name="notificationService">
        /// The notification Service.
        /// *** Leave in Constructor. *** 
        /// </param>
        /// <param name="whenDoneService">
        /// The when Done Service.
        /// *** Leave in Constructor. *** 
        /// </param>
        public MainViewModel(IUserSettingService userSettingService, IScanServiceWrapper scanService, IEncodeServiceWrapper encodeService, IPresetService presetService,
            IErrorService errorService, IShellViewModel shellViewModel, IUpdateService updateService, INotificationService notificationService,
            IPrePostActionService whenDoneService)
        {
            this.scanService = scanService;
            this.encodeService = encodeService;
            this.presetService = presetService;
            this.errorService = errorService;
            this.shellViewModel = shellViewModel;
            this.updateService = updateService;
            this.userSettingService = userSettingService;
            this.queueProcessor = IoC.Get<IQueueProcessor>();

            // Setup Properties
            this.WindowTitle = "HandBrake";
            this.CurrentTask = new EncodeTask();
            this.CurrentTask.PropertyChanged += this.CurrentTask_PropertyChanged;
            this.ScannedSource = new Source();

            // Setup Events
            this.scanService.ScanStared += this.ScanStared;
            this.scanService.ScanCompleted += this.ScanCompleted;
            this.scanService.ScanStatusChanged += this.ScanStatusChanged;
            this.queueProcessor.JobProcessingStarted += this.QueueProcessorJobProcessingStarted;
            this.queueProcessor.QueueCompleted += this.QueueCompleted;
            this.queueProcessor.QueueChanged += this.QueueChanged;
            this.queueProcessor.EncodeService.EncodeStatusChanged += this.EncodeStatusChanged;
            this.userSettingService.SettingChanged += this.UserSettingServiceSettingChanged;

            this.Presets = this.presetService.Presets;
            this.CancelScanCommand = new CancelScanCommand(this.scanService);
        }
开发者ID:Rodeo314,项目名称:hb-vt-h264,代码行数:65,代码来源:MainViewModel.cs


示例16: OptionsViewModel

 /// <summary>
 /// Initializes a new instance of the <see cref="OptionsViewModel"/> class.
 /// </summary>
 /// <param name="windowManager">
 /// The window manager.
 /// </param>
 /// <param name="userSettingService">
 /// The user Setting Service.
 /// </param>
 /// <param name="shellViewModel">
 /// The shell View Model.
 /// </param>
 public OptionsViewModel(IWindowManager windowManager, IUserSettingService userSettingService, IShellViewModel shellViewModel)
 {
     this.Title = "Options";
     this.userSettingService = userSettingService;
     this.shellViewModel = shellViewModel;
     this.OnLoad();
 }
开发者ID:E32vb051LS4f9,项目名称:HandBrake,代码行数:19,代码来源:OptionsViewModel.cs


示例17: ShellView

 public ShellView(IShellViewModel viewModel)
     : this()
 {
     DataContext = viewModel;
 }
开发者ID:925coder,项目名称:ReactiveTrader,代码行数:5,代码来源:ShellView.xaml.cs


示例18: MainViewModel

        public MainViewModel(IWindowManager windowManager, IUserSettingService userSettingService, IScan scanService, IEncode encodeService, IPresetService presetService,
            IErrorService errorService, IShellViewModel shellViewModel, IUpdateService updateService)
        {
            this.scanService = scanService;
            this.encodeService = encodeService;
            this.presetService = presetService;
            this.errorService = errorService;
            this.shellViewModel = shellViewModel;
            this.updateService = updateService;
            this.userSettingService = userSettingService;
            this.queueProcessor = IoC.Get<IQueueProcessor>(); // TODO Instance ID!

            // Setup Properties
            this.WindowTitle = "HandBrake";
            this.CurrentTask = new EncodeTask();
            this.ScannedSource = new Source();

            // Setup Events
            this.scanService.ScanStared += this.ScanStared;
            this.scanService.ScanCompleted += this.ScanCompleted;
            this.scanService.ScanStatusChanged += this.ScanStatusChanged;
            this.queueProcessor.JobProcessingStarted += this.QueueProcessorJobProcessingStarted;
            this.queueProcessor.QueueCompleted += this.QueueCompleted;
            this.queueProcessor.EncodeService.EncodeStatusChanged += this.EncodeStatusChanged;

            this.Presets = this.presetService.Presets;
        }
开发者ID:eneko,项目名称:HandBrake,代码行数:27,代码来源:MainViewModel.cs


示例19: NormalLoadViewModel

 public NormalLoadViewModel()
 {
     _startViewModel = ShellViewModel.Current;
     /*timer = new Timer();
     timer.Interval = 100;
     timer.Elapsed += TimerElapsed;
     timer.Start();
     ProgressValue = 0;*/
 }
开发者ID:DelLitt,项目名称:opmscoral,代码行数:9,代码来源:NormalLoadViewModel.cs


示例20: TestInitialize

 public void TestInitialize()
 {
     IoC.GetInstance = (type, s) => null;
     _mockSubsonicService = new MockSubsonicService();
     _mockNavigationService = new MockNavigationService();
     _mockToastNotificationService = new MockToastNotificationService();
     _mockDialogNotificationService = new MockDialogNotificationService();
     _mockStorageService = new MockStorageService();
     _mockWinRTWrappersService = new MockWinRTWrappersService();
     _mockPlayerControls = new MockPlayerControls();
     Subject = new ShellViewModel(_eventAggregator, _mockSubsonicService, _mockNavigationService,
         _mockToastNotificationService, _mockDialogNotificationService, _mockStorageService, _mockWinRTWrappersService)
         {
             PlayerControls = _mockPlayerControls
         };
 }
开发者ID:hyptechdev,项目名称:SubSonic8,代码行数:16,代码来源:ShellViewModelTests.cs



注:本文中的IShellViewModel类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
C# IShipment类代码示例发布时间:2022-05-24
下一篇:
C# IShellLinkW类代码示例发布时间:2022-05-24
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap