Apply tidy after updating to clang-format 5.0.0

The behavior of clang-format slightly changed in Clang 5.0.0:
http://releases.llvm.org/5.0.0/tools/clang/docs/ReleaseNotes.html#clang-format
This commit is contained in:
Martchus 2017-09-17 21:48:15 +02:00
parent 18ed981d29
commit 69ffaeb1f3
54 changed files with 84 additions and 79 deletions

View File

@ -1503,10 +1503,12 @@ void SyncthingConnection::readDownloadProgressEvent(DateTime eventTime, const QJ
= QStringLiteral("%1 / %2 - %3 %") = QStringLiteral("%1 / %2 - %3 %")
.arg(QString::fromLatin1(dataSizeToString(dirInfo.blocksAlreadyDownloaded > 0 .arg(QString::fromLatin1(dataSizeToString(dirInfo.blocksAlreadyDownloaded > 0
? static_cast<uint64>(dirInfo.blocksAlreadyDownloaded) * SyncthingItemDownloadProgress::syncthingBlockSize ? static_cast<uint64>(dirInfo.blocksAlreadyDownloaded) * SyncthingItemDownloadProgress::syncthingBlockSize
: 0).data()), : 0)
.data()),
QString::fromLatin1(dataSizeToString(dirInfo.blocksToBeDownloaded > 0 QString::fromLatin1(dataSizeToString(dirInfo.blocksToBeDownloaded > 0
? static_cast<uint64>(dirInfo.blocksToBeDownloaded) * SyncthingItemDownloadProgress::syncthingBlockSize ? static_cast<uint64>(dirInfo.blocksToBeDownloaded) * SyncthingItemDownloadProgress::syncthingBlockSize
: 0).data()), : 0)
.data()),
QString::number(dirInfo.downloadPercentage)); QString::number(dirInfo.downloadPercentage));
} }
emit downloadProgressChanged(); emit downloadProgressChanged();
@ -2091,4 +2093,4 @@ void SyncthingConnection::recalculateStatus()
* \fn SyncthingConnection::restartTriggered() * \fn SyncthingConnection::restartTriggered()
* \brief Indicates a restart has been successfully triggered via restart(). * \brief Indicates a restart has been successfully triggered via restart().
*/ */
} } // namespace Data

View File

@ -18,4 +18,4 @@ bool SyncthingConnectionSettings::loadHttpsCert()
} }
return true; return true;
} }
} } // namespace Data

View File

@ -24,6 +24,6 @@ struct LIB_SYNCTHING_CONNECTOR_EXPORT SyncthingConnectionSettings {
QList<QSslError> expectedSslErrors; QList<QSslError> expectedSslErrors;
bool loadHttpsCert(); bool loadHttpsCert();
}; };
} } // namespace Data
#endif // SYNCTHINGCONNECTIONSETTINGS_H #endif // SYNCTHINGCONNECTIONSETTINGS_H

View File

@ -127,4 +127,4 @@ bool setDevicesPaused(QJsonObject &syncthingConfig, const QStringList &devIds, b
} }
return altered; return altered;
} }
} } // namespace Data

View File

@ -45,6 +45,6 @@ template <class Objects> QStringList LIB_SYNCTHING_CONNECTOR_EXPORT ids(const Ob
} }
return ids; return ids;
} }
} } // namespace Data
#endif // DATA_UTILS_H #endif // DATA_UTILS_H

View File

@ -34,7 +34,7 @@ inline QColor orange(bool bright)
{ {
return bright ? QColor(0xFFC500) : QColor(0xA85900); return bright ? QColor(0xFFC500) : QColor(0xA85900);
} }
} } // namespace Colors
} // namespace Data } // namespace Data

View File

@ -89,11 +89,11 @@ QtGui::SettingsDialog *setupSettingsDialog(SyncthingApplet &applet)
#ifdef LIB_SYNCTHING_CONNECTOR_SUPPORT_SYSTEMD #ifdef LIB_SYNCTHING_CONNECTOR_SUPPORT_SYSTEMD
<< systemdPage << systemdPage
#endif #endif
); );
category->setIcon( category->setIcon(
QIcon::fromTheme(QStringLiteral("preferences-other"), QIcon(QStringLiteral(":/icons/hicolor/scalable/apps/preferences-other.svg")))); QIcon::fromTheme(QStringLiteral("preferences-other"), QIcon(QStringLiteral(":/icons/hicolor/scalable/apps/preferences-other.svg"))));
categories << category; categories << category;
return new ::QtGui::SettingsDialog(categories); return new ::QtGui::SettingsDialog(categories);
} }
} } // namespace Plasmoid

View File

@ -23,6 +23,6 @@ QKeySequenceEdit *m_globalShortcutEdit;
END_DECLARE_OPTION_PAGE END_DECLARE_OPTION_PAGE
QtGui::SettingsDialog *setupSettingsDialog(Plasmoid::SyncthingApplet &applet); QtGui::SettingsDialog *setupSettingsDialog(Plasmoid::SyncthingApplet &applet);
} } // namespace Plasmoid
#endif // SETTINGSDIALOG_H #endif // SETTINGSDIALOG_H

View File

@ -297,7 +297,7 @@ void SyncthingApplet::handleConnectionStatusChanged(SyncthingStatus status)
#ifdef LIB_SYNCTHING_CONNECTOR_SUPPORT_SYSTEMD #ifdef LIB_SYNCTHING_CONNECTOR_SUPPORT_SYSTEMD
&& !syncthingService().isManuallyStopped() && !syncthingService().isManuallyStopped()
#endif #endif
) { ) {
m_dbusNotifier.showDisconnect(); m_dbusNotifier.showDisconnect();
} }
break; break;
@ -371,7 +371,7 @@ void SyncthingApplet::handleSystemdServiceError(const QString &context, const QS
handleInternalError(tr("D-Bus error - unable to ") % context % QChar('\n') % name % QChar(':') % message, SyncthingErrorCategory::SpecificRequest, handleInternalError(tr("D-Bus error - unable to ") % context % QChar('\n') % name % QChar(':') % message, SyncthingErrorCategory::SpecificRequest,
QNetworkReply::NoError, QNetworkRequest(), QByteArray()); QNetworkReply::NoError, QNetworkRequest(), QByteArray());
} }
} } // namespace Plasmoid
K_EXPORT_PLASMA_APPLET_WITH_JSON(syncthing, Plasmoid::SyncthingApplet, "metadata.json") K_EXPORT_PLASMA_APPLET_WITH_JSON(syncthing, Plasmoid::SyncthingApplet, "metadata.json")

View File

@ -27,7 +27,7 @@ class SyncthingDeviceModel;
class SyncthingDownloadModel; class SyncthingDownloadModel;
class SyncthingService; class SyncthingService;
enum class SyncthingErrorCategory; enum class SyncthingErrorCategory;
} } // namespace Data
namespace QtGui { namespace QtGui {
class WebViewDialog; class WebViewDialog;
@ -191,6 +191,6 @@ inline Data::SyncthingConnectionSettings *SyncthingApplet::currentConnectionConf
{ {
return connectionConfig(m_currentConnectionConfig); return connectionConfig(m_currentConnectionConfig);
} }
} } // namespace Plasmoid
#endif // SYNCTHINGAPPLET_H #endif // SYNCTHINGAPPLET_H

View File

@ -8,4 +8,4 @@ namespace TestUtilities {
* The default factor is 1.0. * The default factor is 1.0.
*/ */
double timeoutFactor = 1.0; double timeoutFactor = 1.0;
} } // namespace TestUtilities

View File

@ -299,6 +299,6 @@ template <typename Action, typename... SignalInfos> void waitForSignals(Action a
" ms.", timeoutFactor != 1.0 ? argsToString(" (original timeout: ", timeout, " ms)") : std::string())); " ms.", timeoutFactor != 1.0 ? argsToString(" (original timeout: ", timeout, " ms)") : std::string()));
} }
} }
} } // namespace TestUtilities
#endif // SYNCTHINGTESTHELPER_H #endif // SYNCTHINGTESTHELPER_H

View File

@ -97,4 +97,4 @@ void SyncthingTestInstance::stop()
cerr << "\n - Syncthing stderr during the testrun:\n" << m_syncthingProcess.readAllStandardError().data(); cerr << "\n - Syncthing stderr during the testrun:\n" << m_syncthingProcess.readAllStandardError().data();
} }
} }
} } // namespace TestUtilities

View File

@ -59,6 +59,6 @@ inline QProcess &SyncthingTestInstance::syncthingProcess()
{ {
return m_syncthingProcess; return m_syncthingProcess;
} }
} } // namespace TestUtilities
#endif // SYNCTHINGTESTHELPER_SYNCTHINGTESTINSTANCE_H #endif // SYNCTHINGTESTHELPER_SYNCTHINGTESTINSTANCE_H

View File

@ -84,8 +84,9 @@ int initSyncthingTray(bool windowed, bool waitForTray, const char *connectionCon
} }
#else #else
QMessageBox::critical(nullptr, QApplication::applicationName(), QMessageBox::critical(nullptr, QApplication::applicationName(),
QApplication::translate("main", "The Qt libraries have not been built with tray icon support. You could open the tray menu as a regular " QApplication::translate("main",
"window using the -w flag, though.")); "The Qt libraries have not been built with tray icon support. You could open the tray menu as a regular "
"window using the -w flag, though."));
return -2; return -2;
#endif #endif
} }

View File

@ -93,4 +93,4 @@ void SingleInstance::readArgs()
emit newInstance(static_cast<int>(args.size() - 1), args.data()); emit newInstance(static_cast<int>(args.size() - 1), args.data());
} }
} } // namespace QtGui

View File

@ -26,6 +26,6 @@ private Q_SLOTS:
private: private:
QLocalServer *m_server; QLocalServer *m_server;
}; };
} } // namespace QtGui
#endif // SINGLEINSTANCE_H #endif // SINGLEINSTANCE_H

View File

@ -60,4 +60,4 @@ void DevButtonsItemDelegate::paint(QPainter *painter, const QStyleOptionViewItem
option.rect.right() - 16, buttonY, 16, 16, index.data(SyncthingDeviceModel::DevicePaused).toBool() ? m_resumeIcon : m_pauseIcon); option.rect.right() - 16, buttonY, 16, 16, index.data(SyncthingDeviceModel::DevicePaused).toBool() ? m_resumeIcon : m_pauseIcon);
} }
} }
} } // namespace QtGui

View File

@ -17,6 +17,6 @@ private:
const QPixmap m_pauseIcon; const QPixmap m_pauseIcon;
const QPixmap m_resumeIcon; const QPixmap m_resumeIcon;
}; };
} } // namespace QtGui
#endif // DEVBUTTONSITEMDELEGATE_H #endif // DEVBUTTONSITEMDELEGATE_H

View File

@ -98,4 +98,4 @@ void DevView::copySelectedItemId()
} }
} }
} }
} } // namespace QtGui

View File

@ -25,6 +25,6 @@ private Q_SLOTS:
void copySelectedItem(); void copySelectedItem();
void copySelectedItemId(); void copySelectedItemId();
}; };
} } // namespace QtGui
#endif // DEVVIEW_H #endif // DEVVIEW_H

View File

@ -67,4 +67,4 @@ void DirButtonsItemDelegate::paint(QPainter *painter, const QStyleOptionViewItem
painter->drawPixmap(option.rect.right() - 16, buttonY, 16, 16, m_folderIcon); painter->drawPixmap(option.rect.right() - 16, buttonY, 16, 16, m_folderIcon);
} }
} }
} } // namespace QtGui

View File

@ -19,6 +19,6 @@ private:
const QPixmap m_pauseIcon; const QPixmap m_pauseIcon;
const QPixmap m_resumeIcon; const QPixmap m_resumeIcon;
}; };
} } // namespace QtGui
#endif // DIRBUTTONSITEMDELEGATE_H #endif // DIRBUTTONSITEMDELEGATE_H

View File

@ -115,4 +115,4 @@ void DirView::copySelectedItemPath()
} }
} }
} }
} } // namespace QtGui

View File

@ -27,6 +27,6 @@ private Q_SLOTS:
void copySelectedItem(); void copySelectedItem();
void copySelectedItemPath(); void copySelectedItemPath();
}; };
} } // namespace QtGui
#endif // DIRVIEW_H #endif // DIRVIEW_H

View File

@ -95,4 +95,4 @@ QSize DownloadItemDelegate::sizeHint(const QStyleOptionViewItem &option, const Q
} }
return defaultSize; return defaultSize;
} }
} } // namespace QtGui

View File

@ -17,6 +17,6 @@ public:
private: private:
const QPixmap m_folderIcon; const QPixmap m_folderIcon;
}; };
} } // namespace QtGui
#endif // DOWNLOADITEMDELEGATE_H #endif // DOWNLOADITEMDELEGATE_H

View File

@ -83,4 +83,4 @@ void DownloadView::copySelectedItem()
} }
} }
} }
} } // namespace QtGui

View File

@ -6,7 +6,7 @@
namespace Data { namespace Data {
struct SyncthingItemDownloadProgress; struct SyncthingItemDownloadProgress;
struct SyncthingDir; struct SyncthingDir;
} } // namespace Data
namespace QtGui { namespace QtGui {
@ -26,6 +26,6 @@ private Q_SLOTS:
void showContextMenu(); void showContextMenu();
void copySelectedItem(); void copySelectedItem();
}; };
} } // namespace QtGui
#endif // DOWNLOADVIEW_H #endif // DOWNLOADVIEW_H

View File

@ -219,7 +219,7 @@ void TrayIcon::showStatusNotification(SyncthingStatus status)
#ifdef LIB_SYNCTHING_CONNECTOR_SUPPORT_SYSTEMD #ifdef LIB_SYNCTHING_CONNECTOR_SUPPORT_SYSTEMD
&& !syncthingService().isManuallyStopped() && !syncthingService().isManuallyStopped()
#endif #endif
) { ) {
#ifdef QT_UTILITIES_SUPPORT_DBUS_NOTIFICATIONS #ifdef QT_UTILITIES_SUPPORT_DBUS_NOTIFICATIONS
if (settings.dbusNotifications) { if (settings.dbusNotifications) {
m_dbusNotifier.showDisconnect(); m_dbusNotifier.showDisconnect();
@ -277,4 +277,4 @@ void TrayIcon::showInternalErrorsDialog()
centerWidget(errorViewDlg); centerWidget(errorViewDlg);
errorViewDlg->show(); errorViewDlg->show();
} }
} } // namespace QtGui

View File

@ -16,7 +16,7 @@ QT_FORWARD_DECLARE_CLASS(QNetworkRequest)
namespace Data { namespace Data {
enum class SyncthingStatus; enum class SyncthingStatus;
enum class SyncthingErrorCategory; enum class SyncthingErrorCategory;
} } // namespace Data
namespace QtGui { namespace QtGui {
@ -59,6 +59,6 @@ inline TrayMenu &TrayIcon::trayMenu()
{ {
return m_trayMenu; return m_trayMenu;
} }
} } // namespace QtGui
#endif // TRAY_ICON_H #endif // TRAY_ICON_H

View File

@ -58,4 +58,4 @@ void TrayMenu::showAtCursor()
moveInside(pos, size(), QApplication::desktop()->availableGeometry(pos)); moveInside(pos, size(), QApplication::desktop()->availableGeometry(pos));
popup(pos); popup(pos);
} }
} } // namespace QtGui

View File

@ -36,6 +36,6 @@ inline TrayIcon *TrayMenu::icon()
{ {
return m_trayIcon; return m_trayIcon;
} }
} } // namespace QtGui
#endif // TRAY_MENU_H #endif // TRAY_MENU_H

View File

@ -591,4 +591,4 @@ void TrayWidget::showDialog(QWidget *dlg)
dlg->show(); dlg->show();
dlg->activateWindow(); dlg->activateWindow();
} }
} } // namespace QtGui

View File

@ -116,6 +116,6 @@ inline const std::vector<TrayWidget *> &TrayWidget::instances()
{ {
return m_instances; return m_instances;
} }
} } // namespace QtGui
#endif // TRAY_WIDGET_H #endif // TRAY_WIDGET_H

View File

@ -35,6 +35,6 @@ void DBusStatusNotifier::handleSyncthingNotificationAction(const QString &action
emit showNotificationsRequested(); emit showNotificationsRequested();
} }
} }
} } // namespace QtGui
#endif #endif

View File

@ -69,6 +69,6 @@ inline void DBusStatusNotifier::showSyncComplete(const QString &message)
{ {
m_syncCompleteNotification.update(message); m_syncCompleteNotification.update(message);
} }
} } // namespace QtGui
#endif // !defined(SYNCTHINGWIDGETS_DBUSSTATUSNOTIFIER_H) && defined(QT_UTILITIES_SUPPORT_DBUS_NOTIFICATIONS) #endif // !defined(SYNCTHINGWIDGETS_DBUSSTATUSNOTIFIER_H) && defined(QT_UTILITIES_SUPPORT_DBUS_NOTIFICATIONS)

View File

@ -110,4 +110,4 @@ void ErrorViewDialog::clearErrors()
s_instance->browser()->clear(); s_instance->browser()->clear();
} }
} }
} } // namespace QtGui

View File

@ -47,6 +47,6 @@ inline void ErrorViewDialog::showInstance()
{ {
instance()->show(); instance()->show();
} }
} } // namespace QtGui
#endif // SYNCTHINGWIDGETS_ERRORVIEWDIALOG_H #endif // SYNCTHINGWIDGETS_ERRORVIEWDIALOG_H

View File

@ -29,4 +29,4 @@ bool InternalError::isRelevant(const SyncthingConnection &connection, SyncthingE
#endif #endif
; ;
} }
} } // namespace QtGui

View File

@ -12,7 +12,7 @@
namespace Data { namespace Data {
class SyncthingConnection; class SyncthingConnection;
enum class SyncthingErrorCategory; enum class SyncthingErrorCategory;
} } // namespace Data
namespace QtGui { namespace QtGui {
@ -34,6 +34,6 @@ inline InternalError::InternalError(const QString &message, const QUrl &url, con
, when(ChronoUtilities::DateTime::now()) , when(ChronoUtilities::DateTime::now())
{ {
} }
} } // namespace QtGui
#endif // SYNCTHINGWIDGETS_INTERNALERROR_H #endif // SYNCTHINGWIDGETS_INTERNALERROR_H

View File

@ -46,13 +46,14 @@ QDialog *ownDeviceIdDialog(Data::SyncthingConnection &connection)
QObject::connect( QObject::connect(
copyPushButton, &QPushButton::clicked, bind(&QClipboard::setText, QGuiApplication::clipboard(), connection.myId(), QClipboard::Clipboard)); copyPushButton, &QPushButton::clicked, bind(&QClipboard::setText, QGuiApplication::clipboard(), connection.myId(), QClipboard::Clipboard));
layout->addWidget(copyPushButton); layout->addWidget(copyPushButton);
QObject::connect(dlg, &QWidget::destroyed, bind(static_cast<bool (*)(const QMetaObject::Connection &)>(&QObject::disconnect), QObject::connect(dlg, &QWidget::destroyed,
connection.requestQrCode(connection.myId(), [pixmapLabel](const QByteArray &data) { bind(static_cast<bool (*)(const QMetaObject::Connection &)>(&QObject::disconnect),
QPixmap pixmap; connection.requestQrCode(connection.myId(), [pixmapLabel](const QByteArray &data) {
pixmap.loadFromData(data); QPixmap pixmap;
pixmapLabel->setPixmap(pixmap); pixmap.loadFromData(data);
}))); pixmapLabel->setPixmap(pixmap);
})));
dlg->setLayout(layout); dlg->setLayout(layout);
return dlg; return dlg;
} }
} } // namespace QtGui

View File

@ -94,4 +94,4 @@ void StatusInfo::update(const SyncthingConnection &connection)
m_additionalStatusText.clear(); m_additionalStatusText.clear();
} }
} }
} } // namespace QtGui

View File

@ -48,6 +48,6 @@ inline const QIcon &StatusInfo::statusIcon() const
{ {
return *m_statusIcon; return *m_statusIcon;
} }
} } // namespace QtGui
#endif // SYNCTHINGWIDGETS_STATUSINFO_H #endif // SYNCTHINGWIDGETS_STATUSINFO_H

View File

@ -132,8 +132,9 @@ TextViewDialog *TextViewDialog::forLogEntries(SyncthingConnection &connection)
{ {
auto *const dlg = new TextViewDialog(tr("Log")); auto *const dlg = new TextViewDialog(tr("Log"));
const auto loadLog = [dlg, &connection] { const auto loadLog = [dlg, &connection] {
connect(dlg, &QWidget::destroyed, bind(static_cast<bool (*)(const QMetaObject::Connection &)>(&QObject::disconnect), connect(dlg, &QWidget::destroyed,
connection.requestLog(bind(&TextViewDialog::showLogEntries, dlg, _1)))); bind(static_cast<bool (*)(const QMetaObject::Connection &)>(&QObject::disconnect),
connection.requestLog(bind(&TextViewDialog::showLogEntries, dlg, _1))));
}; };
connect(dlg, &TextViewDialog::reload, loadLog); connect(dlg, &TextViewDialog::reload, loadLog);
loadLog(); loadLog();
@ -167,4 +168,4 @@ void TextViewDialog::showLogEntries(const std::vector<SyncthingLogEntry> &logEnt
browser()->append(entry.when % QChar(':') % QChar(' ') % QChar('\n') % entry.message % QChar('\n')); browser()->append(entry.when % QChar(':') % QChar(' ') % QChar('\n') % entry.message % QChar('\n'));
} }
} }
} } // namespace QtGui

View File

@ -12,7 +12,7 @@ namespace Data {
class SyncthingConnection; class SyncthingConnection;
struct SyncthingDir; struct SyncthingDir;
struct SyncthingLogEntry; struct SyncthingLogEntry;
} } // namespace Data
namespace QtGui { namespace QtGui {
@ -43,6 +43,6 @@ inline QTextBrowser *TextViewDialog::browser()
{ {
return m_browser; return m_browser;
} }
} } // namespace QtGui
#endif // SYNCTHINGWIDGETS_TEXTVIEWDIALOG_H #endif // SYNCTHINGWIDGETS_TEXTVIEWDIALOG_H

View File

@ -33,7 +33,7 @@ template <> struct hash<QString> {
return qHash(str); return qHash(str);
} }
}; };
} } // namespace std
namespace Settings { namespace Settings {
@ -288,4 +288,4 @@ void save()
v.qt.save(settings); v.qt.save(settings);
} }
} } // namespace Settings

View File

@ -109,6 +109,6 @@ struct SYNCTHINGWIDGETS_EXPORT Settings {
Settings SYNCTHINGWIDGETS_EXPORT &values(); Settings SYNCTHINGWIDGETS_EXPORT &values();
void SYNCTHINGWIDGETS_EXPORT restore(); void SYNCTHINGWIDGETS_EXPORT restore();
void SYNCTHINGWIDGETS_EXPORT save(); void SYNCTHINGWIDGETS_EXPORT save();
} } // namespace Settings
#endif // SETTINGS_H #endif // SETTINGS_H

View File

@ -897,9 +897,9 @@ QWidget *WebViewOptionPage::setupWidget()
auto *label = new QLabel; auto *label = new QLabel;
label->setWindowTitle(QCoreApplication::translate("QtGui::WebViewOptionPage", "General")); label->setWindowTitle(QCoreApplication::translate("QtGui::WebViewOptionPage", "General"));
label->setAlignment(Qt::AlignCenter); label->setAlignment(Qt::AlignCenter);
label->setText( label->setText(QCoreApplication::translate("QtGui::WebViewOptionPage",
QCoreApplication::translate("QtGui::WebViewOptionPage", "Syncthing Tray has not been built with vieb view support utilizing either Qt WebKit " "Syncthing Tray has not been built with vieb view support utilizing either Qt WebKit "
"or Qt WebEngine.\nThe Web UI will be opened in the default web browser instead.")); "or Qt WebEngine.\nThe Web UI will be opened in the default web browser instead."));
return label; return label;
} }
#endif #endif
@ -964,7 +964,7 @@ SettingsDialog::SettingsDialog(Data::SyncthingConnection *connection, QWidget *p
#ifdef LIB_SYNCTHING_CONNECTOR_SUPPORT_SYSTEMD #ifdef LIB_SYNCTHING_CONNECTOR_SUPPORT_SYSTEMD
<< new SystemdOptionPage << new SystemdOptionPage
#endif #endif
); );
category->setIcon(QIcon::fromTheme(QStringLiteral("system-run"), QIcon(QStringLiteral(":/icons/hicolor/scalable/apps/system-run.svg")))); category->setIcon(QIcon::fromTheme(QStringLiteral("system-run"), QIcon(QStringLiteral(":/icons/hicolor/scalable/apps/system-run.svg"))));
categories << category; categories << category;
@ -987,7 +987,7 @@ void SettingsDialog::init()
// some settings could be applied without restarting the application, good idea? // some settings could be applied without restarting the application, good idea?
//connect(this, &Dialogs::SettingsDialog::applied, bind(&Dialogs::QtSettings::apply, &Settings::qtSettings())); //connect(this, &Dialogs::SettingsDialog::applied, bind(&Dialogs::QtSettings::apply, &Settings::qtSettings()));
} }
} } // namespace QtGui
INSTANTIATE_UI_FILE_BASED_OPTION_PAGE_NS(QtGui, ConnectionOptionPage) INSTANTIATE_UI_FILE_BASED_OPTION_PAGE_NS(QtGui, ConnectionOptionPage)
INSTANTIATE_UI_FILE_BASED_OPTION_PAGE_NS(QtGui, NotificationsOptionPage) INSTANTIATE_UI_FILE_BASED_OPTION_PAGE_NS(QtGui, NotificationsOptionPage)

View File

@ -18,7 +18,7 @@ namespace Data {
class SyncthingConnection; class SyncthingConnection;
class SyncthingService; class SyncthingService;
class SyncthingProcess; class SyncthingProcess;
} } // namespace Data
namespace QtGui { namespace QtGui {
@ -120,7 +120,7 @@ public:
private: private:
void init(); void init();
}; };
} } // namespace QtGui
DECLARE_EXTERN_UI_FILE_BASED_OPTION_PAGE_NS(QtGui, ConnectionOptionPage) DECLARE_EXTERN_UI_FILE_BASED_OPTION_PAGE_NS(QtGui, ConnectionOptionPage)
DECLARE_EXTERN_UI_FILE_BASED_OPTION_PAGE_NS(QtGui, NotificationsOptionPage) DECLARE_EXTERN_UI_FILE_BASED_OPTION_PAGE_NS(QtGui, NotificationsOptionPage)

View File

@ -166,6 +166,6 @@ void WebPage::handleSslErrors(QNetworkReply *reply, const QList<QSslError> &erro
} }
} }
#endif #endif
} } // namespace QtGui
#endif // SYNCTHINGWIDGETS_NO_WEBVIEW #endif // SYNCTHINGWIDGETS_NO_WEBVIEW

View File

@ -47,7 +47,7 @@ private:
WebViewDialog *m_dlg; WebViewDialog *m_dlg;
SYNCTHINGWIDGETS_WEB_VIEW *m_view; SYNCTHINGWIDGETS_WEB_VIEW *m_view;
}; };
} } // namespace QtGui
#endif // SYNCTHINGWIDGETS_NO_WEBVIEW #endif // SYNCTHINGWIDGETS_NO_WEBVIEW
#endif // WEBPAGE_H #endif // WEBPAGE_H

View File

@ -122,6 +122,6 @@ bool WebViewDialog::eventFilter(QObject *watched, QEvent *event)
return QMainWindow::eventFilter(watched, event); return QMainWindow::eventFilter(watched, event);
} }
#endif #endif
} } // namespace QtGui
#endif // SYNCTHINGWIDGETS_NO_WEBVIEW #endif // SYNCTHINGWIDGETS_NO_WEBVIEW

View File

@ -46,7 +46,7 @@ inline const Data::SyncthingConnectionSettings &WebViewDialog::settings() const
{ {
return m_settings; return m_settings;
} }
} } // namespace QtGui
#endif // SYNCTHINGWIDGETS_NO_WEBVIEW #endif // SYNCTHINGWIDGETS_NO_WEBVIEW
#endif // WEBVIEW_DIALOG_H #endif // WEBVIEW_DIALOG_H