mirror of
https://github.com/Ranchero-Software/NetNewsWire
synced 2025-08-12 06:26:36 +00:00
Use a feed icon included with the app (instead of the app icon) as the icon for NetNewsWire feeds.
This commit is contained in:
@@ -48,6 +48,8 @@ struct AppAssets {
|
||||
return RSImage(named: "accountTheOldReader")
|
||||
}()
|
||||
|
||||
static let nnwFeedIcon = RSImage(named: "feedIcon")!
|
||||
|
||||
@available(macOS 11.0, *)
|
||||
static var addNewSidebarItemImage: RSImage = {
|
||||
return NSImage(systemSymbolName: "plus", accessibilityDescription: nil)!
|
||||
|
||||
23
Mac/Resources/Assets.xcassets/FeedIcon.imageset/Contents.json
vendored
Normal file
23
Mac/Resources/Assets.xcassets/FeedIcon.imageset/Contents.json
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"images" : [
|
||||
{
|
||||
"filename" : "FeedIcon 2.png",
|
||||
"idiom" : "universal",
|
||||
"scale" : "1x"
|
||||
},
|
||||
{
|
||||
"filename" : "FeedIcon.png",
|
||||
"idiom" : "universal",
|
||||
"scale" : "2x"
|
||||
},
|
||||
{
|
||||
"filename" : "FeedIcon 1.png",
|
||||
"idiom" : "universal",
|
||||
"scale" : "3x"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"author" : "xcode",
|
||||
"version" : 1
|
||||
}
|
||||
}
|
||||
BIN
Mac/Resources/Assets.xcassets/FeedIcon.imageset/FeedIcon 1.png
vendored
Normal file
BIN
Mac/Resources/Assets.xcassets/FeedIcon.imageset/FeedIcon 1.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 147 KiB |
BIN
Mac/Resources/Assets.xcassets/FeedIcon.imageset/FeedIcon 2.png
vendored
Normal file
BIN
Mac/Resources/Assets.xcassets/FeedIcon.imageset/FeedIcon 2.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 147 KiB |
BIN
Mac/Resources/Assets.xcassets/FeedIcon.imageset/FeedIcon.png
vendored
Normal file
BIN
Mac/Resources/Assets.xcassets/FeedIcon.imageset/FeedIcon.png
vendored
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 147 KiB |
@@ -33,4 +33,6 @@ extension IconImage {
|
||||
}
|
||||
return nil
|
||||
}()
|
||||
|
||||
static let nnwFeedIcon = IconImage(AppAssets.nnwFeedIcon)
|
||||
}
|
||||
|
||||
@@ -123,7 +123,7 @@ final class FaviconDownloader {
|
||||
|
||||
if let url = URL(string: homePageURL) {
|
||||
if url.host == "nnw.ranchero.com" || url.host == "netnewswire.blog" {
|
||||
return IconImage.appIcon
|
||||
return IconImage.nnwFeedIcon
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -52,7 +52,7 @@ public final class FeedIconDownloader {
|
||||
}
|
||||
|
||||
if let homePageURLString = feed.homePageURL, let homePageURL = URL(string: homePageURLString), (homePageURL.host == "nnw.ranchero.com" || homePageURL.host == "netnewswire.blog") {
|
||||
return IconImage.appIcon
|
||||
return IconImage.nnwFeedIcon
|
||||
}
|
||||
|
||||
func checkHomePageURL() {
|
||||
|
||||
Reference in New Issue
Block a user