src: switched to using only wstring for status message
This commit is contained in:
@@ -137,7 +137,7 @@ std::vector<FilePath> SourceGroupJava::doGetClassPath() const
|
||||
std::set<FilePath> SourceGroupJava::fetchRootDirectories() const
|
||||
{
|
||||
std::shared_ptr<DialogView> dialogView = Application::getInstance()->getDialogView();
|
||||
dialogView->showUnknownProgressDialog("Preparing Project", "Gathering Root\nDirectories");
|
||||
dialogView->showUnknownProgressDialog(L"Preparing Project", L"Gathering Root\nDirectories");
|
||||
|
||||
ScopedFunctor dialogHider([&dialogView](){
|
||||
dialogView->hideUnknownProgressDialog();
|
||||
|
||||
@@ -76,7 +76,7 @@ std::vector<FilePath> SourceGroupJavaGradle::getAllSourcePaths() const
|
||||
if (m_settings->getGradleProjectFilePathExpandedAndAbsolute().exists())
|
||||
{
|
||||
std::shared_ptr<DialogView> dialogView = Application::getInstance()->getDialogView();
|
||||
dialogView->showUnknownProgressDialog("Preparing Project", "Gradle\nFetching Source Directories");
|
||||
dialogView->showUnknownProgressDialog(L"Preparing Project", L"Gradle\nFetching Source Directories");
|
||||
|
||||
const FilePath projectRootPath = m_settings->getGradleProjectFilePathExpandedAndAbsolute().getParentDirectory();
|
||||
sourcePaths = utility::gradleGetAllSourceDirectories(projectRootPath, m_settings->getShouldIndexGradleTests());
|
||||
@@ -98,7 +98,7 @@ bool SourceGroupJavaGradle::prepareGradleData()
|
||||
dialogView->hideUnknownProgressDialog();
|
||||
});
|
||||
|
||||
dialogView->showUnknownProgressDialog("Preparing Project", "Gradle\nExporting Dependencies");
|
||||
dialogView->showUnknownProgressDialog(L"Preparing Project", L"Gradle\nExporting Dependencies");
|
||||
|
||||
bool success = utility::gradleCopyDependencies(
|
||||
projectRootPath,
|
||||
|
||||
@@ -76,7 +76,7 @@ std::vector<FilePath> SourceGroupJavaMaven::getAllSourcePaths() const
|
||||
if (m_settings && m_settings->getMavenProjectFilePathExpandedAndAbsolute().exists())
|
||||
{
|
||||
std::shared_ptr<DialogView> dialogView = Application::getInstance()->getDialogView();
|
||||
dialogView->showUnknownProgressDialog("Preparing Project", "Maven\nFetching Source Directories");
|
||||
dialogView->showUnknownProgressDialog(L"Preparing Project", L"Maven\nFetching Source Directories");
|
||||
|
||||
const FilePath mavenPath(ApplicationSettings::getInstance()->getMavenPath());
|
||||
const FilePath projectRootPath = m_settings->getMavenProjectFilePathExpandedAndAbsolute().getParentDirectory();
|
||||
@@ -95,7 +95,7 @@ bool SourceGroupJavaMaven::prepareMavenData()
|
||||
const FilePath projectRootPath = m_settings->getMavenProjectFilePathExpandedAndAbsolute().getParentDirectory();
|
||||
|
||||
std::shared_ptr<DialogView> dialogView = Application::getInstance()->getDialogView();
|
||||
dialogView->showUnknownProgressDialog("Preparing Project", "Maven\nGenerating Source Files");
|
||||
dialogView->showUnknownProgressDialog(L"Preparing Project", L"Maven\nGenerating Source Files");
|
||||
|
||||
ScopedFunctor dialogHider([&dialogView](){
|
||||
dialogView->hideUnknownProgressDialog();
|
||||
@@ -115,7 +115,7 @@ bool SourceGroupJavaMaven::prepareMavenData()
|
||||
|
||||
if (success)
|
||||
{
|
||||
dialogView->showUnknownProgressDialog("Preparing Project", "Maven\nExporting Dependencies");
|
||||
dialogView->showUnknownProgressDialog(L"Preparing Project", L"Maven\nExporting Dependencies");
|
||||
|
||||
success = utility::mavenCopyDependencies(
|
||||
mavenPath, projectRootPath, m_settings->getMavenDependenciesDirectoryExpandedAndAbsolute()
|
||||
|
||||
@@ -83,8 +83,9 @@ namespace utility
|
||||
if (utility::isPrefix("[ERROR]", utility::trim(output)))
|
||||
{
|
||||
// TODO: move error handling to caller of this function
|
||||
const std::string dialogMessage =
|
||||
"The following error occurred while executing a Gradle command:\n\n" + utility::replace(output, "\r\n", "\n");
|
||||
const std::wstring dialogMessage =
|
||||
L"The following error occurred while executing a Gradle command:\n\n" +
|
||||
utility::decodeFromUtf8(utility::replace(output, "\r\n", "\n"));
|
||||
MessageStatus(dialogMessage, true, false).dispatch();
|
||||
Application::getInstance()->handleDialog(dialogMessage);
|
||||
|
||||
@@ -111,8 +112,9 @@ namespace utility
|
||||
if (utility::isPrefix("[ERROR]", utility::trim(output)))
|
||||
{
|
||||
// TODO: move error handling to caller of this function
|
||||
const std::string dialogMessage =
|
||||
"The following error occurred while executing a Gradle command:\n\n" + utility::replace(output, "\r\n", "\n");
|
||||
const std::wstring dialogMessage =
|
||||
L"The following error occurred while executing a Gradle command:\n\n" +
|
||||
utility::decodeFromUtf8(utility::replace(output, "\r\n", "\n"));
|
||||
MessageStatus(dialogMessage, true, false).dispatch();
|
||||
Application::getInstance()->handleDialog(dialogMessage);
|
||||
|
||||
|
||||
@@ -90,8 +90,9 @@ namespace utility
|
||||
if (utility::isPrefix("[ERROR]", utility::trim(line)))
|
||||
{
|
||||
// TODO: move error handling to caller of this function
|
||||
const std::string dialogMessage =
|
||||
"The following error occurred while executing a Maven command:\n\n" + utility::replace(line, "\r\n", "\n");
|
||||
const std::wstring dialogMessage =
|
||||
L"The following error occurred while executing a Maven command:\n\n" +
|
||||
utility::decodeFromUtf8(utility::replace(line, "\r\n", "\n"));
|
||||
MessageStatus(dialogMessage, true, false).dispatch();
|
||||
Application::getInstance()->handleDialog(dialogMessage);
|
||||
return false;
|
||||
@@ -114,8 +115,9 @@ namespace utility
|
||||
if (outputAccess->getLineCount() > 0 && utility::isPrefix("Error", utility::trim(outputAccess->getLine(1))))
|
||||
{
|
||||
// TODO: move error handling to caller of this function
|
||||
const std::string dialogMessage =
|
||||
"The following error occurred while executing a Maven command:\n\n" + utility::replace(outputAccess->getText(), "\r\n", "\n");
|
||||
const std::wstring dialogMessage =
|
||||
L"The following error occurred while executing a Maven command:\n\n" +
|
||||
utility::decodeFromUtf8(utility::replace(outputAccess->getText(), "\r\n", "\n"));
|
||||
|
||||
MessageStatus(dialogMessage, true, false).dispatch();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user