Beispiel #1
0
        public SettingsViewModel(SettingsView view)
            : base(false)
        {
            window = view;
              CloseSettingsCommand = new Command(CloseSettings);

              Tabs = new SettingsTabViewModel[]
              {
            new ClientTabViewModel("Клиент"),
            new ServerTabViewModel("Сервер"),
            new AudioTabViewModel("Звук"),
            new PluginSettingTabViewModel("Плагины")
              };

              SelectedTab = Tabs[0];
        }
Beispiel #2
0
        public SettingsViewModel(SettingsView view)
            : base(null, false)
        {
            window = view;
              CloseSettingsCommand = new Command(CloseSettings);

              Tabs = new SettingsTabViewModel[]
              {
            new ClientTabViewModel(),
            new ServerTabViewModel(),
            new AudioTabViewModel(),
            new PluginSettingTabViewModel()
              };

              SelectedTab = Tabs[0];
        }
Beispiel #3
0
        private void OpenSettings(object obj)
        {
            SettingsViewModel viewModel;
              var settings = new SettingsView();
              settings.DataContext = viewModel = new SettingsViewModel(settings);
              settings.ShowDialog();

              viewModel.Dispose();
        }
Beispiel #4
0
 private void OpenSettings(object obj)
 {
   SettingsView settings = new SettingsView();
   settings.DataContext = new SettingsViewModel(settings);
   settings.ShowDialog();
 }