public void Initialize()
        {
            logService      = RemoteServiceLocator.GetService <ILogService>();
            eventAggregator = RemoteServiceLocator.GetService <IEventAggregator>();
            logService.Message("Initialize", true);

            CultureInfo.DefaultThreadCurrentUICulture = new CultureInfo("de-DE");
            logService.Message("UICulture " + Thread.CurrentThread.CurrentUICulture, true);
        }
        public void Initialize()
        {
            RemoteServiceLocator.InitializeIpcChannel(RemoteServiceLocator.GetIpcPortName <IAddressBookService>());
            RemoteServiceLocator.RegisterInstance <IAddressBookService>(addressBookService.Value);
            RemoteServiceLocator.RegisterInstance <ILogService>(logService.Value);
            RemoteServiceLocator.RegisterInstance <IEventAggregator>((MarshalByRefObject)eventAggregator.Value);

            ShellViewModel.Plugins          = plugins;
            ShellViewModel.PluginViews      = pluginViews;
            ShellViewModel.LoadCommand      = loadCommand;
            ShellViewModel.UnloadCommand    = unloadCommand;
            ShellViewModel.LogView          = LogViewModel.View;
            ShellViewModel.TaskView         = TaskViewModel.View;
            TaskViewModel.UpdateTaskCommand = updateTaskCommand;
            ShellViewModel.PropertyChanged += ShellViewModelPropertyChanged;
        }
Example #3
0
        public void RunPluginDomain(string[] args)
        {
            var typedArgs = TypedArgs.FromArgs(args);

            parentProcess         = Process.GetProcessById(typedArgs.ParentProcessId);
            parentProcess.Exited += ParentProcessExited;
            parentProcess.EnableRaisingEvents = true;

            Dispatcher = Dispatcher.CurrentDispatcher;

            RemoteServiceLocator.InitializeIpcChannel(typedArgs.InstanceName);
            RemotingConfiguration.RegisterWellKnownServiceType(typeof(PluginLoader), "PluginLoader", WellKnownObjectMode.Singleton);

            // Signal ready
            var readyEvent = EventWaitHandle.OpenExisting(typedArgs.InstanceName + ".Ready");

            readyEvent.Set();

            Dispatcher.Run();
        }
Example #4
0
 public void Initialize()
 {
     logService         = RemoteServiceLocator.GetService <ILogService>();
     addressBookService = RemoteServiceLocator.GetService <IAddressBookService>();
     logService.Message("Initialize", true);
 }