mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-13 19:49:51 +01:00
commented out the unused logspage
This commit is contained in:
parent
05261ef67c
commit
89ca71aec4
|
@ -1,48 +1,49 @@
|
|||
#include "logspage.hpp"
|
||||
//#include "logspage.hpp"
|
||||
|
||||
#include "application.hpp"
|
||||
#include "singletons/pathmanager.hpp"
|
||||
//#include "application.hpp"
|
||||
//#include "singletons/pathmanager.hpp"
|
||||
|
||||
#include <QFormLayout>
|
||||
#include <QVBoxLayout>
|
||||
//#include <QFormLayout>
|
||||
//#include <QVBoxLayout>
|
||||
|
||||
#include "util/layoutcreator.hpp"
|
||||
//#include "util/layoutcreator.hpp"
|
||||
|
||||
namespace chatterino {
|
||||
namespace widgets {
|
||||
namespace settingspages {
|
||||
// namespace chatterino {
|
||||
// namespace widgets {
|
||||
// namespace settingspages {
|
||||
|
||||
inline QString CreateLink(const QString &url, bool file = false)
|
||||
{
|
||||
if (file) {
|
||||
return QString("<a href=\"file:///" + url + "\"><span style=\"color: white;\">" + url +
|
||||
"</span></a>");
|
||||
}
|
||||
// inline QString CreateLink(const QString &url, bool file = false)
|
||||
//{
|
||||
// if (file) {
|
||||
// return QString("<a href=\"file:///" + url + "\"><span style=\"color: white;\">" + url +
|
||||
// "</span></a>");
|
||||
// }
|
||||
|
||||
return QString("<a href=\"" + url + "\"><span style=\"color: white;\">" + url + "</span></a>");
|
||||
}
|
||||
// return QString("<a href=\"" + url + "\"><span style=\"color: white;\">" + url +
|
||||
// "</span></a>");
|
||||
//}
|
||||
|
||||
LogsPage::LogsPage()
|
||||
: SettingsPage("Logs", "")
|
||||
{
|
||||
auto app = getApp();
|
||||
// LogsPage::LogsPage()
|
||||
// : SettingsPage("Logs", "")
|
||||
//{
|
||||
// auto app = getApp();
|
||||
|
||||
util::LayoutCreator<LogsPage> layoutCreator(this);
|
||||
auto layout = layoutCreator.emplace<QVBoxLayout>().withoutMargin();
|
||||
// util::LayoutCreator<LogsPage> layoutCreator(this);
|
||||
// auto layout = layoutCreator.emplace<QVBoxLayout>().withoutMargin();
|
||||
|
||||
auto logPath = app->paths->logsFolderPath;
|
||||
// auto logPath = app->paths->logsFolderPath;
|
||||
|
||||
auto created = layout.emplace<QLabel>();
|
||||
created->setText("Logs are saved to " + CreateLink(logPath, true));
|
||||
created->setTextFormat(Qt::RichText);
|
||||
created->setTextInteractionFlags(Qt::TextBrowserInteraction | Qt::LinksAccessibleByKeyboard |
|
||||
Qt::LinksAccessibleByKeyboard);
|
||||
created->setOpenExternalLinks(true);
|
||||
layout.append(this->createCheckBox("Enable logging", app->settings->enableLogging));
|
||||
// auto created = layout.emplace<QLabel>();
|
||||
// created->setText("Logs are saved to " + CreateLink(logPath, true));
|
||||
// created->setTextFormat(Qt::RichText);
|
||||
// created->setTextInteractionFlags(Qt::TextBrowserInteraction | Qt::LinksAccessibleByKeyboard |
|
||||
// Qt::LinksAccessibleByKeyboard);
|
||||
// created->setOpenExternalLinks(true);
|
||||
// layout.append(this->createCheckBox("Enable logging", app->settings->enableLogging));
|
||||
|
||||
layout->addStretch(1);
|
||||
}
|
||||
// layout->addStretch(1);
|
||||
//}
|
||||
|
||||
} // namespace settingspages
|
||||
} // namespace widgets
|
||||
} // namespace chatterino
|
||||
//} // namespace settingspages
|
||||
//} // namespace widgets
|
||||
//} // namespace chatterino
|
||||
|
|
|
@ -1,17 +1,17 @@
|
|||
#pragma once
|
||||
//#pragma once
|
||||
|
||||
#include "widgets/settingspages/settingspage.hpp"
|
||||
//#include "widgets/settingspages/settingspage.hpp"
|
||||
|
||||
namespace chatterino {
|
||||
namespace widgets {
|
||||
namespace settingspages {
|
||||
// namespace chatterino {
|
||||
// namespace widgets {
|
||||
// namespace settingspages {
|
||||
|
||||
class LogsPage : public SettingsPage
|
||||
{
|
||||
public:
|
||||
LogsPage();
|
||||
};
|
||||
// class LogsPage : public SettingsPage
|
||||
//{
|
||||
// public:
|
||||
// LogsPage();
|
||||
//};
|
||||
|
||||
} // namespace settingspages
|
||||
} // namespace widgets
|
||||
} // namespace chatterino
|
||||
//} // namespace settingspages
|
||||
//} // namespace widgets
|
||||
//} // namespace chatterino
|
||||
|
|
Loading…
Reference in a new issue