Пример #1
0
        bool ConfigureNewBlog(string featureName)
        {
            var extra = string.Format(
                "The '{0}' feature requires a blog to be configured. A window will be displayed which will allow you to configure a blog.",
                featureName);
            var setupBlog = dialogService.ShowConfirmation(
                "No blogs are configured",
                "Do you want to configure a blog?",
                extra,
                new ButtonExtras(ButtonType.Yes, "Yes", "Configure a blog"),
                new ButtonExtras(ButtonType.No, "No", "Don't configure a blog"));

            if (!setupBlog)
            {
                return(false);
            }
            if (!Settings.AddBlog())
            {
                return(false);
            }

            Settings.Accept();

            return(true);
        }