private void ExecuteProfileSettings(object o)
        {
            var interaction = new ProfileSettingsInteraction(_settingsProvider.Settings, _settingsProvider.GpoSettings);

            _interactionInvoker.Invoke(interaction);

            if (interaction.ApplySettings)
            {
                _settingsManager.ApplyAndSaveSettings(interaction.Settings);
            }
        }
        private ProfileSettingsViewModel CreateProfileSettingsViewModel(PdfCreatorSettings settings)
        {
            var interactionInvoker = Substitute.For <IInteractionInvoker>();
            var viewModelBundle    = BuildViewModelBundle(interactionInvoker);

            _profileChecker = Substitute.For <IProfileChecker>();
            _profileChecker.ProfileCheckDict(Arg.Any <IList <ConversionProfile> >(), Arg.Any <Accounts>()).Returns(new ActionResultDict());
            var viewModel = new ProfileSettingsViewModel(_interactionInvoker, new ProfileSettingsWindowTranslation(), _profileChecker, viewModelBundle);

            var interaction = new ProfileSettingsInteraction(settings, new GpoSettingsDefaults());

            _interactionHelper = new InteractionHelper <ProfileSettingsInteraction>(viewModel, interaction);

            return(viewModel);
        }
        private void ExecuteShowSettings(object obj)
        {
            _settingsProvider.Settings.ApplicationSettings.LastUsedProfileGuid = SelectedProfile.Guid;

            var interaction = new ProfileSettingsInteraction(_settingsProvider.Settings.Copy(), _settingsProvider.GpoSettings);

            _interactionInvoker.Invoke(interaction);

            if (!interaction.ApplySettings)
            {
                return;
            }

            ApplicationSettings = interaction.Settings.ApplicationSettings;
            Profiles            = interaction.Settings.ConversionProfiles;
            SelectProfileByGuid(ApplicationSettings.LastUsedProfileGuid);

            _settingsManager.ApplyAndSaveSettings(interaction.Settings);
        }