From 36c92e542f01607918b9f02691ad86adf99baa39 Mon Sep 17 00:00:00 2001 From: Mantas-2155X Date: Mon, 25 Jan 2021 18:22:01 +0200 Subject: [PATCH] * Fix clang formatting --- src/widgets/capture/capturewidget.cpp | 27 +++++++++++++++++---------- 1 file changed, 17 insertions(+), 10 deletions(-) diff --git a/src/widgets/capture/capturewidget.cpp b/src/widgets/capture/capturewidget.cpp index da8e5167..319b2936 100644 --- a/src/widgets/capture/capturewidget.cpp +++ b/src/widgets/capture/capturewidget.cpp @@ -322,8 +322,9 @@ void CaptureWidget::paintEvent(QPaintEvent*) painter.setClipRect(rect()); if (m_showInitialMsg) { -#if (QT_VERSION >= QT_VERSION_CHECK(5, 10, 0) && (defined(Q_OS_MAC) || defined(Q_OS_MAC64) || defined(Q_OS_MACOS) || \ - defined(Q_OS_MACX) || defined(Q_OS_LINUX))) +#if (QT_VERSION >= QT_VERSION_CHECK(5, 10, 0) && \ + (defined(Q_OS_MAC) || defined(Q_OS_MAC64) || defined(Q_OS_MACOS) || \ + defined(Q_OS_MACX) || defined(Q_OS_LINUX))) QRect helpRect; QScreen* currentScreen = QGuiApplication::screenAt(QCursor::pos()); if (currentScreen) { @@ -712,23 +713,29 @@ void CaptureWidget::initPanel() { QRect panelRect = rect(); if (m_context.fullscreen) { -#if (QT_VERSION >= QT_VERSION_CHECK(5, 10, 0) && (defined(Q_OS_MAC) || defined(Q_OS_MAC64) || defined(Q_OS_MACOS) || \ - defined(Q_OS_MACX) || defined(Q_OS_LINUX))) +#if (QT_VERSION >= QT_VERSION_CHECK(5, 10, 0) && \ + (defined(Q_OS_MAC) || defined(Q_OS_MAC64) || defined(Q_OS_MACOS) || \ + defined(Q_OS_MACX) || defined(Q_OS_LINUX))) QScreen* currentScreen = QGuiApplication::screenAt(QCursor::pos()); if (currentScreen) { panelRect = currentScreen->geometry(); auto devicePixelRatio = currentScreen->devicePixelRatio(); - panelRect.moveTo(panelRect.x() / devicePixelRatio, panelRect.y() / devicePixelRatio); - + panelRect.moveTo(panelRect.x() / devicePixelRatio, + panelRect.y() / devicePixelRatio); + } else { panelRect = QGuiApplication::primaryScreen()->geometry(); - auto devicePixelRatio = QGuiApplication::primaryScreen()->devicePixelRatio(); - panelRect.moveTo(panelRect.x() / devicePixelRatio, panelRect.y() / devicePixelRatio); + auto devicePixelRatio = + QGuiApplication::primaryScreen()->devicePixelRatio(); + panelRect.moveTo(panelRect.x() / devicePixelRatio, + panelRect.y() / devicePixelRatio); } #else panelRect = QGuiApplication::primaryScreen()->geometry(); - auto devicePixelRatio = QGuiApplication::primaryScreen()->devicePixelRatio(); - panelRect.moveTo(panelRect.x() / devicePixelRatio, panelRect.y() / devicePixelRatio); + auto devicePixelRatio = + QGuiApplication::primaryScreen()->devicePixelRatio(); + panelRect.moveTo(panelRect.x() / devicePixelRatio, + panelRect.y() / devicePixelRatio); #endif }