private void StartEngine()
        {
            this.ModelManager = new ModelManager();

            //The WCF selfhost implementation
            var service = new Service();

            this.serviceHost = service.StartService(this.ModelManager);

            //OWIN selfhost implementation
            var owin = new OwinMtService(this.ModelManager);

            this.UiTabs = new ObservableCollection <ActionTabItem>();
            var localModels = new LocalModelListView(this.ModelManager);
            var settings    = new OpusCatSettingsView();

            this.UiTabs.Add(
                new ActionTabItem {
                Content = localModels, Header = OpusCatMTEngine.Properties.Resources.Main_ModelsTabTitle, Closable = false
            });
            this.UiTabs.Add(
                new ActionTabItem {
                Content = settings, Header = OpusCatMTEngine.Properties.Resources.Main_SettingsTabTitle, Closable = false
            });

            this.DataContext = this;
        }
Exemple #2
0
        private void StartEngine()
        {
            var service = new Service();

            this.ModelManager = new ModelManager();

            this.UiTabs = new ObservableCollection <ActionTabItem>();
            var localModels = new LocalModelListView(this.ModelManager);
            var settings    = new OpusCatSettingsView();

            this.UiTabs.Add(
                new ActionTabItem {
                Content = localModels, Header = "Models", Closable = false
            });
            this.UiTabs.Add(
                new ActionTabItem {
                Content = settings, Header = "Settings", Closable = false
            });

            this.DataContext = this;
            this.serviceHost = service.StartService(this.ModelManager);
        }