I'm using NSWorkSpace setIcon:forFile:options:
on a folder.
However, while the API returns success(true) every time the api is utilized, sometimes the Icon is not updated on the folder.
I've noticed creating a new file inside of the folder will trigger the icon to reappear, which leads me to believe that Finder needs to refresh the folder.
Is there a way to determine when the Icon has actually been set, and the folder needs to be refresh? And is there a way to refresh the folder without creating & deleting a file quickly?
Turns out there is a function to help notify Finder of the file change.
NSWorkSpace
noteFileSystemChanged
does this.However, it does not seem to work for folder icon changes.
Seems like the only option is to create/delete a file.