From 275f1f21095447357bc3033c8681a215a4e384cf Mon Sep 17 00:00:00 2001 From: Maze Date: Sun, 29 Aug 2021 19:07:46 +0200 Subject: [PATCH] Make error popup opaque Sending screenshots of error popups is an easy way to leak information. But if the popup is transparent, that makes it so much easier. For the sake of privacy, error popups should be opaque. --- src/gui/Popups/UnexpectedErrorPopup.qml | 5 +++++ src/themes/Glass.qpl | 6 ++++++ src/themes/Midnight.qpl | 6 ++++++ 3 files changed, 17 insertions(+) diff --git a/src/gui/Popups/UnexpectedErrorPopup.qml b/src/gui/Popups/UnexpectedErrorPopup.qml index 158e5d2e..159fbb22 100644 --- a/src/gui/Popups/UnexpectedErrorPopup.qml +++ b/src/gui/Popups/UnexpectedErrorPopup.qml @@ -13,6 +13,11 @@ HColumnPopup { property var errors: [] // [{type, message, traceback}] + background: Rectangle { + color: theme.controls.popup.opaqueBackground + ? theme.controls.popup.opaqueBackground + : theme.controls.popup.background // fallback + } contentWidthLimit: Math.min(window.width / 1.5, 864 * theme.uiScale) diff --git a/src/themes/Glass.qpl b/src/themes/Glass.qpl index f6ee1ae3..fe6ac2d0 100644 --- a/src/themes/Glass.qpl +++ b/src/themes/Glass.qpl @@ -116,6 +116,12 @@ controls: popup: int defaultWidth: minimumSupportedWidth * 1.75 color background: colors.mediumBackground + color opaqueBackground: hsluv( + colors.hue, + colors.bgSaturation, + colors.intensity * 7, + 1 + ) color windowOverlay: hsluv(0, 0, 0, 0.7) header: diff --git a/src/themes/Midnight.qpl b/src/themes/Midnight.qpl index 24f62116..4327dc1b 100644 --- a/src/themes/Midnight.qpl +++ b/src/themes/Midnight.qpl @@ -119,6 +119,12 @@ controls: popup: int defaultWidth: minimumSupportedWidth * 1.75 color background: colors.mediumBackground + color opaqueBackground: hsluv( + colors.hue, + colors.bgSaturation, + colors.intensity * 7, + 1 + ) color windowOverlay: hsluv(0, 0, 0, 0.7) header: