Просмотр исходного кода

Fix PDF page view transparency

Signed-off-by: Henrik Storch <henrik.storch@nextcloud.com>
Henrik Storch 3 лет назад
Родитель
Сommit
bac5ecaae4
1 измененных файлов с 4 добавлено и 2 удалено
  1. 4 2
      iOSClient/Viewer/NCViewerPDF/NCViewerPDF.swift

+ 4 - 2
iOSClient/Viewer/NCViewerPDF/NCViewerPDF.swift

@@ -79,7 +79,9 @@ class NCViewerPDF: UIViewController, NCViewerPDFSearchDelegate {
 
         pageView.translatesAutoresizingMaskIntoConstraints = false
         pageView.layer.cornerRadius = 10
-        pageView.backgroundColor = UIColor.gray.withAlphaComponent(0.3)
+        pageView.backgroundColor = NCBrandColor.shared.systemBackground.withAlphaComponent(
+            UIAccessibility.isReduceTransparencyEnabled ? 1 : 0.5
+        )
 
         view.addSubview(pageView)
 
@@ -91,7 +93,7 @@ class NCViewerPDF: UIViewController, NCViewerPDFSearchDelegate {
 
         pageViewLabel.translatesAutoresizingMaskIntoConstraints = false
         pageViewLabel.textAlignment = .center
-        pageViewLabel.textColor = .gray
+        pageViewLabel.textColor = NCBrandColor.shared.label
 
         pageView.addSubview(pageViewLabel)