Add additional activity kinds for iCloud.

This commit is contained in:
Brent Simmons committed 2026-05-29 15:28:30 -07:00
1 parent 035a401766
commit 681bdb84e7
3 files changed
+78

No files matched your search

@@ -499,9 +499,42 @@ private extension ActivityLogWindowController {
return "Downloading avatar \(avatarURL)"
case .downloadHTMLMetadata(let urlString):
return "Downloading metadata \(urlString)"
case .subscribeFeed:
return descriptionWithDetail("Subscribing to feed", activity: activity)
case .renameFeed:
return descriptionWithDetail("Renaming feed", activity: activity)
case .removeFeed:
return descriptionWithDetail("Removing feed", activity: activity)
case .moveFeed:
return descriptionWithDetail("Moving feed", activity: activity)
case .addFeed:
return descriptionWithDetail("Adding feed", activity: activity)
case .createFolder:
return descriptionWithDetail("Creating folder", activity: activity)
case .renameFolder:
return descriptionWithDetail("Renaming folder", activity: activity)
case .removeFolder:
return descriptionWithDetail("Removing folder", activity: activity)
case .restoreFolder:
return descriptionWithDetail("Restoring folder", activity: activity)
case .markArticles:
return descriptionWithDetail("Marking articles", activity: activity)
case .cleanUpCloudKitRecords:
return "Weekly record cleanup"
case .uploadNewArticles:
return descriptionWithDetail("Uploading new articles", activity: activity)
case .subscribeToCloudKitZone:
return descriptionWithDetail("Subscribing to zone changes", activity: activity)
}
}
private func descriptionWithDetail(_ prefix: String, activity: Activity) -> String {
if let detail = activity.detail {
return "\(prefix): \(detail)"
}
return prefix
}
func color(for owner: ActivityOwner) -> NSColor {
switch owner {
case .account(let accountID):
@@ -460,6 +460,32 @@ private extension ActivityWindowController {
return NSLocalizedString("Refreshing missing articles", comment: "Activity kind")
case .importOPML:
return NSLocalizedString("Importing OPML", comment: "Activity kind")
case .subscribeFeed:
return NSLocalizedString("Subscribing to feed", comment: "Activity kind")
case .renameFeed:
return NSLocalizedString("Renaming feed", comment: "Activity kind")
case .removeFeed:
return NSLocalizedString("Removing feed", comment: "Activity kind")
case .moveFeed:
return NSLocalizedString("Moving feed", comment: "Activity kind")
case .addFeed:
return NSLocalizedString("Adding feed", comment: "Activity kind")
case .createFolder:
return NSLocalizedString("Creating folder", comment: "Activity kind")
case .renameFolder:
return NSLocalizedString("Renaming folder", comment: "Activity kind")
case .removeFolder:
return NSLocalizedString("Removing folder", comment: "Activity kind")
case .restoreFolder:
return NSLocalizedString("Restoring folder", comment: "Activity kind")
case .markArticles:
return NSLocalizedString("Marking articles", comment: "Activity kind")
case .cleanUpCloudKitRecords:
return NSLocalizedString("Weekly record cleanup", comment: "Activity kind")
case .uploadNewArticles:
return NSLocalizedString("Uploading new articles", comment: "Activity kind")
case .subscribeToCloudKitZone:
return NSLocalizedString("Subscribing to zone changes", comment: "Activity kind")
case .refreshFeedContent, .findFeed, .downloadFeedImage, .downloadFavicon, .downloadAvatar, .downloadHTMLMetadata:
return ""
}
@@ -18,6 +18,25 @@ public enum ActivityKind: Sendable, Hashable {
case refreshMissingArticles
case importOPML
// CloudKit user-action edits
case subscribeFeed
case renameFeed
case removeFeed
case moveFeed
case addFeed
case createFolder
case renameFolder
case removeFolder
case restoreFolder
// CloudKit background work
case markArticles
case cleanUpCloudKitRecords
case uploadNewArticles
case subscribeToCloudKitZone
// App-level
case refreshAll