Skip to content

Commit

Permalink
hex: color error and lightbox error (#304)
Browse files Browse the repository at this point in the history
* hex: color error and lightbox error
* Updated named colors
  • Loading branch information
anubhavpulkit authored Jul 2, 2020
1 parent 5de9127 commit c8d85e4
Show file tree
Hide file tree
Showing 29 changed files with 201 additions and 45 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0.090",
"green" : "0.082",
"red" : "0.075"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0.604",
"green" : "0.647",
"red" : "0.149"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0.624",
"green" : "0.243",
"red" : "0.188"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0.671",
"green" : "0.286",
"red" : "0.224"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0.267",
"green" : "0.267",
"red" : "0.267"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0.580",
"green" : "0.580",
"red" : "0.580"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0.000",
"green" : "0.675",
"red" : "1.000"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"colors" : [
{
"color" : {
"color-space" : "srgb",
"components" : {
"alpha" : "1.000",
"blue" : "0.137",
"green" : "0.125",
"red" : "0.118"
}
},
"idiom" : "universal"
}
],
"info" : {
"author" : "xcode",
"version" : 1
}
}
9 changes: 2 additions & 7 deletions AmahiAnywhere/AmahiAnywhere/Base/BaseUIViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -198,11 +198,10 @@ class BaseUIViewController: UIViewController, GCKSessionManagerListener, GCKRequ

func showStatusAlert(title: String, _ extraSpace: Bool = false){
let statusView = UIView()
// statusView.backgroundColor = UIColor(hex: "1E2023")
if #available(iOS 13.0, *) {
statusView.backgroundColor = UIColor.secondarySystemBackground
} else {
statusView.backgroundColor = UIColor(hex: "1E2023")
statusView.backgroundColor = UIColor(named: "formal")
}
statusView.layer.cornerRadius = 8
statusView.alpha = 1
Expand Down Expand Up @@ -279,14 +278,10 @@ extension BaseUIViewController: UITextFieldDelegate {
extension BaseUITableViewController{
func showStatusAlert(title: String){
let statusView = UIView()
// statusView.backgroundColor = UIColor(hex: "1E2023")
if #available(iOS 13.0, *) {

statusView.backgroundColor = UIColor.secondarySystemBackground

} else {
statusView.backgroundColor = UIColor(hex: "1E2023")

statusView.backgroundColor = UIColor(named: "formal")
}
statusView.layer.cornerRadius = 8
statusView.alpha = 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class DownloadsBaseCollectionCell: SwipeCollectionViewCell{
backgroundView.backgroundColor = UIColor.secondarySystemBackground

} else {
backgroundView.backgroundColor = UIColor(hex: "1E2023")
backgroundView.backgroundColor = UIColor(named: "formal")
}
selectedBackgroundView = backgroundView
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ class FilesBaseCollectionCell: SwipeCollectionViewCell{
backgroundView.backgroundColor = UIColor.secondarySystemBackground

} else {
backgroundView.backgroundColor = UIColor(hex: "1E2023")
backgroundView.backgroundColor = UIColor(named: "formal")
}
selectedBackgroundView = backgroundView
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class ServerCollectionViewCell: UICollectionViewCell {
if #available(iOS 13.0, *) {
serverLabel.textColor = UIColor.tertiaryLabel
} else {
serverLabel.textColor = UIColor(hex: "949494")
serverLabel.textColor = UIColor(named: "949494")
}
}

Expand All @@ -48,7 +48,7 @@ class ServerCollectionViewCell: UICollectionViewCell {
view.backgroundColor = UIColor.secondarySystemBackground

} else {
view.backgroundColor = UIColor(hex: "1E2023")
view.backgroundColor = UIColor(named: "formal")
}
selectedBackgroundView = view
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ class SharesCollectionViewCell: UICollectionViewCell {

titleLabel.textColor = UIColor.label
} else {
view.backgroundColor = UIColor(hex: "1E2023")
view.backgroundColor = UIColor(named: "formal")
titleLabel.textColor = UIColor.white

}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class SortViewTableViewCell: UITableViewCell {
backgroundView.backgroundColor = UIColor.secondarySystemBackground

} else {
backgroundView.backgroundColor = UIColor(hex: "1E2023")
backgroundView.backgroundColor = UIColor(named: "formal")
}
selectedBackgroundView = backgroundView
addSubview(iconImageView)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ GCKSessionManagerListener, GCKRemoteMediaClientListener, GCKRequestDelegate, GCK
_tableView.backgroundColor = UIColor.secondarySystemBackground
_editButton.tintColor = UIColor.label
} else {
self.view.backgroundColor = UIColor(hex: "1E2023")
_tableView.backgroundColor = UIColor(hex: "1E2023")
self.view.backgroundColor = UIColor(named: "formal")
_tableView.backgroundColor = UIColor(named: "formal")
_editButton.tintColor = UIColor.white
}
super.viewDidLoad()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ class FilesPresenter: BasePresenter {
let results = files.getImageFiles(selectedFile: selectedFile)
let controller = LightboxController(images: results.images, startIndex: results.startIndex)
controller.dynamicBackground = true
controller.modalPresentationStyle = .fullScreen
self.view?.present(controller)

case .video, .flacMedia:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,8 @@ class FilesViewController: BaseUIViewController, GCKRemoteMediaClientListener {
sortButton.tintColor = UIColor.label
floaty.tintColor = UIColor.label
} else {
self.view.backgroundColor = UIColor(hex: "1E2023")
filesCollectionView.backgroundColor = UIColor(hex: "1E2023")
self.view.backgroundColor = UIColor(named: "formal")
filesCollectionView.backgroundColor = UIColor(named: "formal")
sortButton.titleLabel?.textColor = UIColor.white
sortButton.tintColor = UIColor.white
floaty.tintColor = UIColor.white
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ class LoginViewController: BaseUIViewController {
showHideButton.tintColor = UIColor.label

} else {
self.view.backgroundColor = UIColor(hex: "1E2023")
self.view.backgroundColor = UIColor(named: "formal")
usernameInputField.textColor = UIColor.white
usernameInputField.placeholderColor = UIColor.lightGray
usernameInputField.titleColor = UIColor.white
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ class OfflineFilesPresenter: BasePresenter {
let results = files.getImageFiles(selectedFile: selectedFile)
let controller = LightboxController(images: results.images, startIndex: results.startIndex)
controller.dynamicBackground = true
controller.modalPresentationStyle = .fullScreen
self.view?.present(controller)
case .video, .flacMedia:
self.view?.playMedia(at: url)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,10 @@ class OfflineFilesViewController: BaseUIViewController{
sortButton.titleLabel?.textColor = UIColor.label

} else {
self.view.backgroundColor = UIColor(hex: "1E2023")
filesCollectionView.backgroundColor = UIColor(hex: "1E2023")
self.view.backgroundColor = UIColor(named: "formal")
filesCollectionView.backgroundColor = UIColor(named: "formal")

sortButton.backgroundColor = UIColor(hex: "1E2023")
sortButton.backgroundColor = UIColor(named: "formal")
sortButton.tintColor = UIColor.white
sortButton.titleLabel?.textColor = UIColor.white
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -211,6 +211,7 @@ class RecentFilesViewController: BaseUIViewController {
let results = getImageFiles(selectedFile: recentFile)
let controller = LightboxController(images: results.images, startIndex: results.startIndex)
controller.dynamicBackground = true
controller.modalPresentationStyle = .fullScreen
present(controller, animated: true, completion: nil)
case "video", "flacMedia":
playMediaItem(recentFile: recentFile)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,8 @@ class ServerViewController: BaseUIViewController {
} else {
castButton.tintColor = UIColor.white
availableLabel.textColor = UIColor.white
serversCollectionView.backgroundColor = UIColor(hex: "1E2023")
self.view.backgroundColor = UIColor(hex: "1E2023")
serversCollectionView.backgroundColor = UIColor(named: "formal")
self.view.backgroundColor = UIColor(named: "formal")

}
navigationItem.rightBarButtonItem = UIBarButtonItem(customView: castButton)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ class ConnectionViewController: BaseUITableViewController {
if #available(iOS 13.0, *) {
self.view.backgroundColor = UIColor.secondarySystemBackground
} else {
self.view.backgroundColor = UIColor(hex: "1E2023")
self.view.backgroundColor = UIColor(named: "formal")
}
}

Expand Down Expand Up @@ -59,7 +59,7 @@ class ConnectionViewController: BaseUITableViewController {
if #available(iOS 13.0, *) {
selectedBackgroundView.backgroundColor = UIColor.secondarySystemBackground
} else {
selectedBackgroundView.backgroundColor = UIColor(hex: "1E2023")
selectedBackgroundView.backgroundColor = UIColor(named: "formal")
}

cell.selectedBackgroundView = selectedBackgroundView
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ extension SettingsViewController {
selectedBackgroundView.backgroundColor = UIColor.secondarySystemBackground

} else {
selectedBackgroundView.backgroundColor = UIColor(hex: "1E2023")
selectedBackgroundView.backgroundColor = UIColor(named: "formal")
}

cell.selectedBackgroundView = selectedBackgroundView
Expand All @@ -100,7 +100,7 @@ extension SettingsViewController {
view.backgroundColor = UIColor.systemBackground

} else {
view.backgroundColor = UIColor(hex: "131517")
view.backgroundColor = UIColor(named: "131517")


}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ class SettingsViewController: BaseUITableViewController {
if #available(iOS 13.0, *) {
self.view.backgroundColor = UIColor.secondarySystemBackground
} else {
self.view.backgroundColor = UIColor(hex: "1E2023")
self.view.backgroundColor = UIColor(named: "formal")
}
print(getFreeSize())
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,8 +45,8 @@ class SharesViewController: BaseUIViewController, UICollectionViewDelegate, UICo
sharesCollectionView.backgroundColor = UIColor.secondarySystemBackground
serverNameLabel.textColor = UIColor.label
} else {
self.view.backgroundColor = UIColor(hex: "1E2023")
sharesCollectionView.backgroundColor = UIColor(hex: "1E2023")
self.view.backgroundColor = UIColor(named: "formal")
sharesCollectionView.backgroundColor = UIColor(named: "formal")
serverNameLabel.textColor = UIColor.white
}

Expand Down
Loading

0 comments on commit c8d85e4

Please sign in to comment.