ui: changes for discontinue of Sourcetrail (#1229)
* remove patreon button from start screen * change text on github button on start screen * remove outdated info from "about" dialog * replace references to website by links to github repo
This commit is contained in:
Binary file not shown.
|
Before Width: | Height: | Size: 2.3 KiB |
@@ -21,7 +21,7 @@ function(AddLicense softwareName softwareVersion softwareURL licenseFile)
|
||||
endfunction(AddLicense)
|
||||
|
||||
ReadLicense(${CMAKE_SOURCE_DIR}/LICENSE.txt Sourcetrail_license)
|
||||
set(LICENSE_APP "LicenseInfo(\"Sourcetrail\", \"${VERSION_STRING}\", \"https://www.sourcetrail.com\", Sourcetrail_license)")
|
||||
set(LICENSE_APP "LicenseInfo(\"Sourcetrail\", \"${VERSION_STRING}\", \"https://github.com/CoatiSoftware/Sourcetrail\", Sourcetrail_license)")
|
||||
|
||||
AddLicense("Boost" "1.68" "http://www.boost.org" "${LICENSEFOLDER}/license_boost.txt")
|
||||
AddLicense("catch" "2.5.0" "https://github.com/catchorg/Catch2" "${LICENSEFOLDER}/license_catch.txt")
|
||||
|
||||
@@ -510,8 +510,7 @@ bool Application::checkSharedMemory()
|
||||
L"There was an error accessing shared memory on your computer: " + error +
|
||||
L"\n\n"
|
||||
"Project indexing is not possible. Please restart your computer or try running "
|
||||
"Sourcetrail as admin. If the "
|
||||
"issue persists contact mail@sourcetrail.com");
|
||||
"Sourcetrail as admin.");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -374,7 +374,9 @@ void QtProjectWizardContentPreferences::populate(QGridLayout* layout, int& row)
|
||||
"<p>Provide the location of the jvm library inside the installation of your " +
|
||||
javaVersionString +
|
||||
" runtime environment (for information on how to set this take a look at "
|
||||
"<a href=\"https://sourcetrail.com/documentation/#FindingJavaRuntimeLibraryLocation\">"
|
||||
"<a href=\"" +
|
||||
utility::getDocumentationLink() +
|
||||
"/#FindingJavaRuntimeLibraryLocation\">"
|
||||
"Finding Java Runtime Library Location</a> or use the auto detection below)</p>")
|
||||
.c_str(),
|
||||
layout,
|
||||
|
||||
@@ -100,13 +100,15 @@ void QtProjectWizardContentSelect::populate(QGridLayout* layout, int& row)
|
||||
"Create a Source Group from an existing Compilation Database file (compile_commands.json). "
|
||||
"It can be exported from CMake<br />(-DCMAKE_EXPORT_COMPILE_COMMANDS=ON) and Make projects "
|
||||
"or from the Qt Creator since version 4.8. Have a look at the "
|
||||
"<a href=\"https://sourcetrail.com/documentation/#CreateAProjectFromCompilationDatabase\">"
|
||||
"documentation</a>.";
|
||||
"<a href=\"" +
|
||||
utility::getDocumentationLink() +
|
||||
"/#CreateAProjectFromCompilationDatabase\">documentation</a>.";
|
||||
m_sourceGroupTypeDescriptions[SOURCE_GROUP_CXX_VS] =
|
||||
"<p>Create a new Source Group from an existing Visual Studio Solution file.</p>"
|
||||
"<p><b>Note</b>: Requires a running Visual Studio instance with the "
|
||||
"<a href=\"https://sourcetrail.com/documentation/index.html#VisualStudio\">Sourcetrail "
|
||||
"Visual Studio Extension</a> installed.</p>";
|
||||
"<a href=\"" +
|
||||
utility::getDocumentationLink() +
|
||||
"/#VisualStudio\">Sourcetrail Visual Studio Extension</a> installed.</p>";
|
||||
m_sourceGroupTypeDescriptions[SOURCE_GROUP_CXX_CODEBLOCKS] =
|
||||
"<p>Create a new Source Group from an existing Code::Blocks project file.</p>"
|
||||
"<p><b>Note</b>: A \".cbp\" file will also get generated by the <b>Qt Creator</b> if a "
|
||||
@@ -157,7 +159,8 @@ void QtProjectWizardContentSelect::populate(QGridLayout* layout, int& row)
|
||||
connect(
|
||||
m_languages,
|
||||
static_cast<void (QButtonGroup::*)(QAbstractButton*)>(&QButtonGroup::buttonClicked),
|
||||
[this](QAbstractButton* button) {
|
||||
[this](QAbstractButton* button)
|
||||
{
|
||||
LanguageType selectedLanguage = LANGUAGE_UNKNOWN;
|
||||
bool ok = false;
|
||||
int languageTypeInt = button->property("language_type").toInt(&ok);
|
||||
@@ -230,7 +233,8 @@ void QtProjectWizardContentSelect::populate(QGridLayout* layout, int& row)
|
||||
connect(
|
||||
it.second,
|
||||
static_cast<void (QButtonGroup::*)(QAbstractButton*)>(&QButtonGroup::buttonClicked),
|
||||
[this](QAbstractButton* button) {
|
||||
[this](QAbstractButton* button)
|
||||
{
|
||||
SourceGroupType selectedType = SOURCE_GROUP_UNKNOWN;
|
||||
bool ok = false;
|
||||
int selectedTypeInt = button->property("source_group_type").toInt(&ok);
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#include "QtProjectWizardContentVS.h"
|
||||
|
||||
#include "MessageIDECreateCDB.h"
|
||||
#include "utilityApp.h"
|
||||
|
||||
QtProjectWizardContentVS::QtProjectWizardContentVS(QtProjectWizardWindow* window)
|
||||
: QtProjectWizardContent(window)
|
||||
@@ -26,12 +27,12 @@ void QtProjectWizardContentVS::populate(QGridLayout* layout, int& row)
|
||||
layout,
|
||||
row);
|
||||
|
||||
QLabel* descriptionLabel = createFormSubLabel(QStringLiteral(
|
||||
QLabel* descriptionLabel = createFormSubLabel(QString::fromStdString(
|
||||
"Call Visual Studio to create a Compilation Database from the loaded Solution (requires "
|
||||
"installed "
|
||||
"<a href=\"https://sourcetrail.com/documentation/index.html#VisualStudio\">Sourcetrail "
|
||||
"Visual Studio "
|
||||
"Extension</a>)."));
|
||||
"<a href=\"" +
|
||||
utility::getDocumentationLink() +
|
||||
"/#VisualStudio\">Sourcetrail Visual Studio Extension</a>)."));
|
||||
descriptionLabel->setObjectName(QStringLiteral("description"));
|
||||
descriptionLabel->setOpenExternalLinks(true);
|
||||
descriptionLabel->setAlignment(Qt::AlignmentFlag::AlignLeft);
|
||||
|
||||
+6
-3
@@ -1,6 +1,7 @@
|
||||
#include "QtProjectWizardContentPathsFrameworkSearchGlobal.h"
|
||||
|
||||
#include "ApplicationSettings.h"
|
||||
#include "utilityApp.h"
|
||||
#include "utilityPathDetection.h"
|
||||
|
||||
QtProjectWizardContentPathsFrameworkSearchGlobal::QtProjectWizardContentPathsFrameworkSearchGlobal(
|
||||
@@ -12,14 +13,16 @@ QtProjectWizardContentPathsFrameworkSearchGlobal::QtProjectWizardContentPathsFra
|
||||
true)
|
||||
{
|
||||
setTitleString(QStringLiteral("Global Framework Search Paths"));
|
||||
setHelpString(
|
||||
setHelpString(QString::fromStdString(
|
||||
"The Global Framework Search Paths will be used in all your projects - in addition to the "
|
||||
"project specific "
|
||||
"Framework Search Paths.<br />"
|
||||
"<br />"
|
||||
"They define where MacOS framework containers (.framework) are found "
|
||||
"(See <a href=\"https://sourcetrail.com/documentation/#FindingSystemHeaderLocations\">"
|
||||
"Finding System Header Locations</a> or use the auto detection below).");
|
||||
"(See <a href=\"" +
|
||||
utility::getDocumentationLink() +
|
||||
"/#FindingSystemHeaderLocations\">"
|
||||
"Finding System Header Locations</a> or use the auto detection below)."));
|
||||
|
||||
m_pathDetector = utility::getCxxFrameworkPathDetector();
|
||||
m_makePathsRelativeToProjectFileLocation = false;
|
||||
|
||||
+7
-4
@@ -16,14 +16,16 @@ QtProjectWizardContentPathsHeaderSearchGlobal::QtProjectWizardContentPathsHeader
|
||||
true)
|
||||
{
|
||||
setTitleString(QStringLiteral("Global Include Paths"));
|
||||
setHelpString(
|
||||
setHelpString(QString::fromStdString(
|
||||
"The Global Include Paths will be used in all your projects in addition to the project "
|
||||
"specific Include Paths. "
|
||||
"These paths are usually passed to the compiler with the '-isystem' flag.<br />"
|
||||
"<br />"
|
||||
"Use them to add system header paths (See <a "
|
||||
"href=\"https://sourcetrail.com/documentation/#FindingSystemHeaderLocations\">"
|
||||
"Finding System Header Locations</a> or use the auto detection below).");
|
||||
"href=\"" +
|
||||
utility::getDocumentationLink() +
|
||||
"/#FindingSystemHeaderLocations\">"
|
||||
"Finding System Header Locations</a> or use the auto detection below)."));
|
||||
|
||||
m_pathDetector = utility::getCxxHeaderPathDetector();
|
||||
m_makePathsRelativeToProjectFileLocation = false;
|
||||
@@ -79,7 +81,8 @@ bool QtProjectWizardContentPathsHeaderSearchGlobal::check()
|
||||
"Your Global Include Paths contain other paths that hold C/C++ compiler headers, "
|
||||
"probably those of your local C/C++ compiler. They are possibly in conflict with the "
|
||||
"compiler headers of "
|
||||
"Sourcetrail's C/C++ indexer. This can lead to compatibility errors during indexing. Do "
|
||||
"Sourcetrail's C/C++ indexer. This can lead to compatibility errors during indexing. "
|
||||
"Do "
|
||||
"you want to remove "
|
||||
"these paths?");
|
||||
msgBox.setDetailedText(compilerHeaderPaths);
|
||||
|
||||
@@ -22,7 +22,8 @@ QSize QtAbout::sizeHint() const
|
||||
void QtAbout::setupAbout()
|
||||
{
|
||||
setStyleSheet(
|
||||
utility::getStyleSheet(ResourcePaths::getGuiDirectoryPath().concatenate(L"about/about.css")).c_str());
|
||||
utility::getStyleSheet(ResourcePaths::getGuiDirectoryPath().concatenate(L"about/about.css"))
|
||||
.c_str());
|
||||
|
||||
QVBoxLayout* windowLayout = new QVBoxLayout();
|
||||
windowLayout->setContentsMargins(10, 10, 10, 0);
|
||||
@@ -68,18 +69,7 @@ void QtAbout::setupAbout()
|
||||
QHBoxLayout* layoutHorz1 = new QHBoxLayout();
|
||||
windowLayout->addLayout(layoutHorz1);
|
||||
|
||||
QLabel* companyLabel = new QLabel(
|
||||
QString::fromStdString("<b>Coati Software KG</b><br />"
|
||||
"Jakob-Haringer-Straße 1/127<br />"
|
||||
"5020 Salzburg<br />"
|
||||
"Austria<br />"
|
||||
"<b>support@sourcetrail.com</b><br />"
|
||||
"<b><a href=\"https://sourcetrail.com\" style=\"color: "
|
||||
"white;\">sourcetrail.com</a></b>"));
|
||||
companyLabel->setOpenExternalLinks(true);
|
||||
layoutHorz1->addWidget(companyLabel);
|
||||
|
||||
layoutHorz1->addSpacing(120);
|
||||
layoutHorz1->addStretch();
|
||||
|
||||
QLabel* developerLabel = new QLabel(
|
||||
QString::fromStdString("<br /><br />"
|
||||
@@ -91,23 +81,41 @@ void QtAbout::setupAbout()
|
||||
"Andreas Stallinger<br />"));
|
||||
developerLabel->setObjectName(QStringLiteral("small"));
|
||||
layoutHorz1->addWidget(developerLabel);
|
||||
|
||||
layoutHorz1->addStretch();
|
||||
}
|
||||
|
||||
windowLayout->addStretch();
|
||||
|
||||
QLabel* acknowledgementsLabel = new QLabel(QString::fromStdString(
|
||||
"<b>Acknowledgements:</b><br />"
|
||||
"Sourcetrail (aka Coati) 0.1 was created in the context of education at "
|
||||
"<a href=\"http://www.fh-salzburg.ac.at/en/\" style=\"color: white;\">Salzburg University "
|
||||
"of Applied Sciences</a>.<br />"
|
||||
"Coati Software KG is member of <a href=\"http://www.startup-salzburg.at/\" style=\"color: "
|
||||
"white;\">Startup Salzburg</a>.<br />"
|
||||
"The development of Sourcetrail was funded by <a href=\"http://awsg.at\" style=\"color: "
|
||||
"white;\">aws</a>."));
|
||||
acknowledgementsLabel->setObjectName(QStringLiteral("small"));
|
||||
acknowledgementsLabel->setWordWrap(true);
|
||||
acknowledgementsLabel->setOpenExternalLinks(true);
|
||||
windowLayout->addWidget(acknowledgementsLabel);
|
||||
{
|
||||
QLabel* acknowledgementsLabel = new QLabel(QString::fromStdString(
|
||||
"<b>Acknowledgements:</b><br />"
|
||||
"Sourcetrail (aka Coati) 0.1 was created in the context of education at "
|
||||
"<a href=\"http://www.fh-salzburg.ac.at/en/\" style=\"color: white;\">Salzburg "
|
||||
"University "
|
||||
"of Applied Sciences</a>.<br />"
|
||||
"Coati Software KG is member of <a href=\"http://www.startup-salzburg.at/\" "
|
||||
"style=\"color: "
|
||||
"white;\">Startup Salzburg</a>.<br />"
|
||||
"The development of Sourcetrail was funded by <a href=\"http://awsg.at\" "
|
||||
"style=\"color: "
|
||||
"white;\">aws</a>."));
|
||||
acknowledgementsLabel->setObjectName(QStringLiteral("small"));
|
||||
acknowledgementsLabel->setWordWrap(true);
|
||||
acknowledgementsLabel->setOpenExternalLinks(true);
|
||||
windowLayout->addWidget(acknowledgementsLabel);
|
||||
windowLayout->addSpacing(10);
|
||||
}
|
||||
|
||||
windowLayout->addSpacing(10);
|
||||
{
|
||||
QLabel* webLabel = new QLabel(
|
||||
"<b>Repository: <a href=\"https://github.com/CoatiSoftware/Sourcetrail\" "
|
||||
"style=\"color: "
|
||||
"white;\">github.com/CoatiSoftware/Sourcetrail</a></b>",
|
||||
this);
|
||||
webLabel->setObjectName(QStringLiteral("small"));
|
||||
webLabel->setOpenExternalLinks(true);
|
||||
windowLayout->addWidget(webLabel);
|
||||
windowLayout->addSpacing(10);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -133,9 +133,9 @@ QtMainWindow::QtMainWindow()
|
||||
if (utility::getOsType() != OS_MAC)
|
||||
{
|
||||
// can only be done once, because resetting the style on the QCoreApplication causes crash
|
||||
app->setStyleSheet(
|
||||
utility::getStyleSheet(ResourcePaths::getGuiDirectoryPath().concatenate(L"main/scrollbar.css"))
|
||||
.c_str());
|
||||
app->setStyleSheet(utility::getStyleSheet(ResourcePaths::getGuiDirectoryPath().concatenate(
|
||||
L"main/scrollbar.css"))
|
||||
.c_str());
|
||||
}
|
||||
|
||||
setupProjectMenu();
|
||||
@@ -406,7 +406,8 @@ void QtMainWindow::setContentEnabled(bool enabled)
|
||||
void QtMainWindow::refreshStyle()
|
||||
{
|
||||
setStyleSheet(
|
||||
utility::getStyleSheet(ResourcePaths::getGuiDirectoryPath().concatenate(L"main/main.css")).c_str());
|
||||
utility::getStyleSheet(ResourcePaths::getGuiDirectoryPath().concatenate(L"main/main.css"))
|
||||
.c_str());
|
||||
|
||||
QFont tooltipFont = QToolTip::font();
|
||||
tooltipFont.setPixelSize(ApplicationSettings::getInstance()->getFontSize());
|
||||
@@ -508,7 +509,7 @@ void QtMainWindow::openSettings()
|
||||
|
||||
void QtMainWindow::showDocumentation()
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl(QStringLiteral("https://sourcetrail.com/documentation/")));
|
||||
QDesktopServices::openUrl(QUrl(QString::fromStdString(utility::getDocumentationLink())));
|
||||
}
|
||||
|
||||
void QtMainWindow::showKeyboardShortcuts()
|
||||
@@ -543,7 +544,8 @@ void QtMainWindow::showLicenses()
|
||||
void QtMainWindow::showDataFolder()
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl(
|
||||
QString::fromStdWString(L"file:///" + UserPaths::getUserDataDirectoryPath().makeCanonical().wstr()),
|
||||
QString::fromStdWString(
|
||||
L"file:///" + UserPaths::getUserDataDirectoryPath().makeCanonical().wstr()),
|
||||
QUrl::TolerantMode));
|
||||
}
|
||||
|
||||
|
||||
@@ -91,8 +91,6 @@ QtStartScreen::QtStartScreen(QWidget* parent)
|
||||
ResourcePaths::getGuiDirectoryPath().concatenate(L"icon/empty_icon.png").wstr()))
|
||||
, m_githubIcon(QString::fromStdWString(
|
||||
ResourcePaths::getGuiDirectoryPath().concatenate(L"startscreen/github_icon.png").wstr()))
|
||||
, m_patreonIcon(QString::fromStdWString(
|
||||
ResourcePaths::getGuiDirectoryPath().concatenate(L"startscreen/patreon_icon.png").wstr()))
|
||||
{
|
||||
}
|
||||
|
||||
@@ -188,9 +186,9 @@ void QtStartScreen::setupStartScreen()
|
||||
versionLabel->setObjectName(QStringLiteral("boldLabel"));
|
||||
col->addWidget(versionLabel);
|
||||
|
||||
col->addSpacing(15);
|
||||
col->addSpacing(20);
|
||||
|
||||
QPushButton* githubButton = new QPushButton(QStringLiteral("Contribute on GitHub"), this);
|
||||
QPushButton* githubButton = new QPushButton(QStringLiteral("View on GitHub"), this);
|
||||
githubButton->setAttribute(Qt::WA_LayoutUsesWidgetRect); // fixes layouting on Mac
|
||||
githubButton->setObjectName(QStringLiteral("infoButton"));
|
||||
githubButton->setIcon(m_githubIcon);
|
||||
@@ -206,24 +204,6 @@ void QtStartScreen::setupStartScreen()
|
||||
});
|
||||
col->addWidget(githubButton);
|
||||
|
||||
col->addSpacing(8);
|
||||
|
||||
// QPushButton* patreonButton = new QPushButton("Support on Patreon", this);
|
||||
QPushButton* patreonButton = new QPushButton(QStringLiteral("Become a Patron"), this);
|
||||
patreonButton->setAttribute(Qt::WA_LayoutUsesWidgetRect); // fixes layouting on Mac
|
||||
patreonButton->setObjectName(QStringLiteral("infoButton"));
|
||||
patreonButton->setIcon(m_patreonIcon);
|
||||
patreonButton->setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);
|
||||
connect(
|
||||
patreonButton,
|
||||
&QPushButton::clicked,
|
||||
[]()
|
||||
{
|
||||
QDesktopServices::openUrl(QUrl(
|
||||
QStringLiteral("https://www.patreon.com/sourcetrail"), QUrl::TolerantMode));
|
||||
});
|
||||
col->addWidget(patreonButton);
|
||||
|
||||
col->addSpacing(35);
|
||||
col->addStretch();
|
||||
|
||||
|
||||
@@ -53,7 +53,6 @@ private:
|
||||
const QIcon m_javaIcon;
|
||||
const QIcon m_projectIcon;
|
||||
const QIcon m_githubIcon;
|
||||
const QIcon m_patreonIcon;
|
||||
};
|
||||
|
||||
#endif // QT_START_SCREEN_H
|
||||
|
||||
@@ -26,6 +26,11 @@ std::mutex s_runningProcessesMutex;
|
||||
std::set<std::shared_ptr<boost::process::child>> s_runningProcesses;
|
||||
} // namespace utility
|
||||
|
||||
std::string utility::getDocumentationLink()
|
||||
{
|
||||
return "https://sourcetrail.com/documentation";
|
||||
}
|
||||
|
||||
std::wstring utility::searchPath(const std::wstring& bin, bool& ok)
|
||||
{
|
||||
ok = false;
|
||||
@@ -44,19 +49,23 @@ std::wstring utility::searchPath(const std::wstring& bin)
|
||||
return searchPath(bin, ok);
|
||||
}
|
||||
|
||||
namespace {
|
||||
template<typename Rep, typename Period>
|
||||
bool safely_wait_for(boost::process::child& process, const std::chrono::duration< Rep, Period > & rel_time)
|
||||
namespace
|
||||
{
|
||||
template <typename Rep, typename Period>
|
||||
bool safely_wait_for(boost::process::child& process, const std::chrono::duration<Rep, Period>& rel_time)
|
||||
{
|
||||
// This wrapper around boost::process::wait_for handles the following edge case:
|
||||
// Calling wait_for on an already exitted process will wait for the entire timeout.
|
||||
if (process.running()) {
|
||||
if (process.running())
|
||||
{
|
||||
return process.wait_for(rel_time);
|
||||
} else {
|
||||
return true; // The process exitted
|
||||
}
|
||||
else
|
||||
{
|
||||
return true; // The process exitted
|
||||
}
|
||||
}
|
||||
}
|
||||
} // namespace
|
||||
|
||||
utility::ProcessOutput utility::executeProcess(
|
||||
const std::wstring& command,
|
||||
@@ -108,10 +117,12 @@ utility::ProcessOutput utility::executeProcess(
|
||||
s_runningProcesses.insert(process);
|
||||
}
|
||||
|
||||
ScopedFunctor remover([process]() {
|
||||
std::lock_guard<std::mutex> lock(s_runningProcessesMutex);
|
||||
s_runningProcesses.erase(process);
|
||||
});
|
||||
ScopedFunctor remover(
|
||||
[process]()
|
||||
{
|
||||
std::lock_guard<std::mutex> lock(s_runningProcessesMutex);
|
||||
s_runningProcesses.erase(process);
|
||||
});
|
||||
|
||||
bool outputReceived = false;
|
||||
std::vector<char> buf(128);
|
||||
@@ -120,40 +131,41 @@ utility::ProcessOutput utility::executeProcess(
|
||||
|
||||
std::function<void(const boost::system::error_code& ec, std::size_t n)> onStdOut =
|
||||
[&output, &buf, &stdOutBuffer, &ap, &onStdOut, &outputReceived, &logBuffer, logProcessOutput](
|
||||
const boost::system::error_code& ec, std::size_t size) {
|
||||
std::string text;
|
||||
text.reserve(size);
|
||||
text.insert(text.end(), buf.begin(), buf.begin() + size);
|
||||
const boost::system::error_code& ec, std::size_t size)
|
||||
{
|
||||
std::string text;
|
||||
text.reserve(size);
|
||||
text.insert(text.end(), buf.begin(), buf.begin() + size);
|
||||
|
||||
if (!text.empty())
|
||||
{
|
||||
outputReceived = true;
|
||||
}
|
||||
if (!text.empty())
|
||||
{
|
||||
outputReceived = true;
|
||||
}
|
||||
|
||||
output += text;
|
||||
if (logProcessOutput)
|
||||
output += text;
|
||||
if (logProcessOutput)
|
||||
{
|
||||
logBuffer += text;
|
||||
const bool isEndOfLine = (logBuffer.back() == '\n');
|
||||
const std::vector<std::string> lines = utility::splitToVector(logBuffer, "\n");
|
||||
for (size_t i = 0; i < lines.size() - (isEndOfLine ? 0 : 1); i++)
|
||||
{
|
||||
logBuffer += text;
|
||||
const bool isEndOfLine = (logBuffer.back() == '\n');
|
||||
const std::vector<std::string> lines = utility::splitToVector(logBuffer, "\n");
|
||||
for (size_t i = 0; i < lines.size() - (isEndOfLine ? 0 : 1); i++)
|
||||
{
|
||||
LOG_INFO_BARE("Process output: " + lines[i]);
|
||||
}
|
||||
if (isEndOfLine)
|
||||
{
|
||||
logBuffer.clear();
|
||||
}
|
||||
else
|
||||
{
|
||||
logBuffer = lines.back();
|
||||
}
|
||||
LOG_INFO_BARE("Process output: " + lines[i]);
|
||||
}
|
||||
if (!ec)
|
||||
if (isEndOfLine)
|
||||
{
|
||||
boost::asio::async_read(ap, stdOutBuffer, onStdOut);
|
||||
logBuffer.clear();
|
||||
}
|
||||
};
|
||||
else
|
||||
{
|
||||
logBuffer = lines.back();
|
||||
}
|
||||
}
|
||||
if (!ec)
|
||||
{
|
||||
boost::asio::async_read(ap, stdOutBuffer, onStdOut);
|
||||
}
|
||||
};
|
||||
|
||||
boost::asio::async_read(ap, stdOutBuffer, onStdOut);
|
||||
ios.run();
|
||||
|
||||
@@ -16,6 +16,8 @@ struct ProcessOutput
|
||||
int exitCode;
|
||||
};
|
||||
|
||||
std::string getDocumentationLink();
|
||||
|
||||
std::wstring searchPath(const std::wstring& bin, bool& ok);
|
||||
|
||||
std::wstring searchPath(const std::wstring& bin);
|
||||
|
||||
Reference in New Issue
Block a user