From bc14b00628b1cb3c05a75ee15d590dec5535281d Mon Sep 17 00:00:00 2001 From: Kyle Hickinson Date: Wed, 22 Nov 2023 16:17:19 -0500 Subject: [PATCH] Ref #8417: Disable tint adjustment on secure state buttons This turns off the grayscale effect that is given to the button while controllers are presented on top of the browser --- .../Browser/Toolbars/UrlBar/CollapsedURLBarView.swift | 5 ++++- .../Frontend/Browser/Toolbars/UrlBar/TabLocationView.swift | 1 + 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/Sources/Brave/Frontend/Browser/Toolbars/UrlBar/CollapsedURLBarView.swift b/Sources/Brave/Frontend/Browser/Toolbars/UrlBar/CollapsedURLBarView.swift index da26110c543..8042344f142 100644 --- a/Sources/Brave/Frontend/Browser/Toolbars/UrlBar/CollapsedURLBarView.swift +++ b/Sources/Brave/Frontend/Browser/Toolbars/UrlBar/CollapsedURLBarView.swift @@ -17,7 +17,10 @@ class CollapsedURLBarView: UIView { $0.alignment = .firstBaseline } - private let secureContentStateView = UIButton() + private let secureContentStateView = UIButton().then { + $0.tintAdjustmentMode = .normal + } + private let separatorLine = UILabel().then { $0.isUserInteractionEnabled = false $0.isAccessibilityElement = false diff --git a/Sources/Brave/Frontend/Browser/Toolbars/UrlBar/TabLocationView.swift b/Sources/Brave/Frontend/Browser/Toolbars/UrlBar/TabLocationView.swift index 49a3869737c..107778c6dfd 100644 --- a/Sources/Brave/Frontend/Browser/Toolbars/UrlBar/TabLocationView.swift +++ b/Sources/Brave/Frontend/Browser/Toolbars/UrlBar/TabLocationView.swift @@ -119,6 +119,7 @@ class TabLocationView: UIView { button.configurationUpdateHandler = { [unowned self] btn in btn.configuration = secureContentStateButtonConfiguration } + button.tintAdjustmentMode = .normal secureContentStateButton = button leadingView = button }