CryptomatorDockTilePlugin.swift 485 B

12345678910111213141516171819
  1. //
  2. // CryptomatorDockTilePlugin.swift
  3. // Integrations
  4. //
  5. // Created by Tobias Hagemann on 22.09.25.
  6. // Copyright © 2025 Cryptomator. All rights reserved.
  7. //
  8. import AppKit
  9. class CryptomatorDockTilePlugin: NSObject, NSDockTilePlugIn {
  10. func setDockTile(_ dockTile: NSDockTile?) {
  11. guard let dockTile = dockTile, let image = Bundle(for: Self.self).image(forResource: "Cryptomator") else {
  12. return
  13. }
  14. dockTile.contentView = NSImageView(image: image)
  15. dockTile.display()
  16. }
  17. }