mirror of
https://github.com/Ranchero-Software/NetNewsWire
synced 2025-08-12 06:26:36 +00:00
Continue moving from AppAssets to AppAsset.
This commit is contained in:
@@ -37,20 +37,12 @@ struct AppAssets {
|
||||
|
||||
static let editImage = UIImage(systemName: "square.and.pencil")!
|
||||
|
||||
static let faviconTemplateImage = RSImage(named: "faviconTemplateImage")!
|
||||
|
||||
static let filterInactiveImage = UIImage(systemName: "line.horizontal.3.decrease.circle")!
|
||||
|
||||
static let filterActiveImage = UIImage(systemName: "line.horizontal.3.decrease.circle.fill")!
|
||||
|
||||
static let folderOutlinePlus = UIImage(systemName: "folder.badge.plus")!
|
||||
|
||||
static let fullScreenBackgroundColor = UIColor(named: "fullScreenBackgroundColor")!
|
||||
|
||||
static let infoImage = UIImage(systemName: "info.circle")!
|
||||
|
||||
static let markAllAsReadImage = UIImage(named: "markAllAsRead")!
|
||||
|
||||
static let markBelowAsReadImage = UIImage(systemName: "arrowtriangle.down.circle")!
|
||||
|
||||
static let markAboveAsReadImage = UIImage(systemName: "arrowtriangle.up.circle")!
|
||||
|
||||
@@ -705,12 +705,12 @@ private extension SidebarViewController {
|
||||
}
|
||||
|
||||
func setFilterButtonToActive() {
|
||||
filterButton?.image = AppAssets.filterActiveImage
|
||||
filterButton?.image = AppAsset.filterActive
|
||||
filterButton?.accLabelText = NSLocalizedString("Selected - Filter Read Feeds", comment: "Selected - Filter Read Feeds")
|
||||
}
|
||||
|
||||
func setFilterButtonToInactive() {
|
||||
filterButton?.image = AppAssets.filterInactiveImage
|
||||
filterButton?.image = AppAsset.filterInactive
|
||||
filterButton?.accLabelText = NSLocalizedString("Filter Read Feeds", comment: "Filter Read Feeds")
|
||||
}
|
||||
|
||||
@@ -1101,7 +1101,7 @@ private extension SidebarViewController {
|
||||
|
||||
let localizedMenuText = NSLocalizedString("Mark All as Read in “%@”", comment: "Command")
|
||||
let title = NSString.localizedStringWithFormat(localizedMenuText as NSString, feed.nameForDisplay) as String
|
||||
let action = UIAction(title: title, image: AppAssets.markAllAsReadImage) { [weak self] action in
|
||||
let action = UIAction(title: title, image: AppAsset.markAllAsRead) { [weak self] action in
|
||||
MarkAsReadAlertController.confirm(self, coordinator: self?.coordinator, confirmTitle: title, sourceType: contentView) { [weak self] in
|
||||
|
||||
Task { @MainActor in
|
||||
@@ -1122,7 +1122,7 @@ private extension SidebarViewController {
|
||||
|
||||
let localizedMenuText = NSLocalizedString("Mark All as Read in “%@”", comment: "Command")
|
||||
let title = NSString.localizedStringWithFormat(localizedMenuText as NSString, account.nameForDisplay) as String
|
||||
let action = UIAction(title: title, image: AppAssets.markAllAsReadImage) { [weak self] action in
|
||||
let action = UIAction(title: title, image: AppAsset.markAllAsRead) { [weak self] action in
|
||||
MarkAsReadAlertController.confirm(self, coordinator: self?.coordinator, confirmTitle: title, sourceType: contentView) { [weak self] in
|
||||
// If you don't have this delay the screen flashes when it executes this code
|
||||
DispatchQueue.main.asyncAfter(deadline: .now() + 0.5) {
|
||||
|
||||
@@ -63,7 +63,7 @@ class TimelineViewController: UITableViewController, UndoableCommandRunner {
|
||||
NotificationCenter.default.addObserver(self, selector: #selector(willEnterForeground(_:)), name: UIApplication.willEnterForegroundNotification, object: nil)
|
||||
|
||||
// Initialize Programmatic Buttons
|
||||
filterButton = UIBarButtonItem(image: AppAssets.filterInactiveImage, style: .plain, target: self, action: #selector(toggleFilter(_:)))
|
||||
filterButton = UIBarButtonItem(image: AppAsset.filterInactive, style: .plain, target: self, action: #selector(toggleFilter(_:)))
|
||||
firstUnreadButton = UIBarButtonItem(image: AppAssets.nextUnreadArticleImage, style: .plain, target: self, action: #selector(firstUnread(_:)))
|
||||
|
||||
// Setup the Search Controller
|
||||
@@ -656,10 +656,10 @@ private extension TimelineViewController {
|
||||
}
|
||||
|
||||
if coordinator.isReadArticlesFiltered {
|
||||
filterButton?.image = AppAssets.filterActiveImage
|
||||
filterButton?.image = AppAsset.filterActive
|
||||
filterButton?.accLabelText = NSLocalizedString("Selected - Filter Read Articles", comment: "Selected - Filter Read Articles")
|
||||
} else {
|
||||
filterButton?.image = AppAssets.filterInactiveImage
|
||||
filterButton?.image = AppAsset.filterInactive
|
||||
filterButton?.accLabelText = NSLocalizedString("Filter Read Articles", comment: "Filter Read Articles")
|
||||
}
|
||||
|
||||
@@ -886,7 +886,7 @@ private extension TimelineViewController {
|
||||
let localizedMenuText = NSLocalizedString("Mark All as Read in “%@”", comment: "Command")
|
||||
let title = NSString.localizedStringWithFormat(localizedMenuText as NSString, feed.nameForDisplay) as String
|
||||
|
||||
let action = UIAction(title: title, image: AppAssets.markAllAsReadImage) { [weak self] action in
|
||||
let action = UIAction(title: title, image: AppAsset.markAllAsRead) { [weak self] action in
|
||||
MarkAsReadAlertController.confirm(self, coordinator: self?.coordinator, confirmTitle: title, sourceType: contentView) { [weak self] in
|
||||
|
||||
Task { @MainActor in
|
||||
|
||||
Reference in New Issue
Block a user