Skip to content

Commit

Permalink
Refactor FXIOS-10927 [Bookmarks Evolution] Correct bookmarks disclosu…
Browse files Browse the repository at this point in the history
…re indicator (#23983)
  • Loading branch information
MattLichtenstein authored Jan 3, 2025
1 parent 2f8ba44 commit e12dbf3
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@ import struct MozillaAppServices.Guid
/// - Have the menu, unfiled and toolbar folders all under a desktop folder that doesn't exists in the backend
/// - Present the menu, unfiled and toolbar folders to the users without making a backend call.
/// Desktop folder content is fetched when folder is selected.
class LocalDesktopFolder: FxBookmarkNode {
class LocalDesktopFolder: FxBookmarkNode,
BookmarksRefactorFeatureFlagProvider {
// Guid used locally, but never synced to Firefox Sync accounts
static let localDesktopFolderGuid = "localDesktopFolder"

Expand Down Expand Up @@ -52,9 +53,12 @@ class LocalDesktopFolder: FxBookmarkNode {

extension LocalDesktopFolder: BookmarksFolderCell {
func getViewModel() -> OneLineTableViewCellViewModel {
let image = UIImage(named: StandardImageIdentifiers.Large.chevronRight)?.withRenderingMode(.alwaysTemplate)
let accessoryView = isBookmarkRefactorEnabled ? UIImageView(image: image) : nil

return OneLineTableViewCellViewModel(title: LegacyLocalizedRootBookmarkFolderStrings[guid],
leftImageView: leftImageView,
accessoryView: nil,
accessoryView: accessoryView,
accessoryType: .disclosureIndicator,
editingAccessoryView: nil)
}
Expand Down

0 comments on commit e12dbf3

Please sign in to comment.