felixerdy / touchbar

Atom package to use MacBook Touchbar
https://atom.io/packages/touchbar
MIT License
50 stars 10 forks source link

Use nativeImage.createFromPath if the icon name includes a / #30

Closed jaevans closed 6 years ago

jaevans commented 6 years ago

Addresses #29, it's just a brain-dead attempt to see if the idea works. I'm completely open to better ideas for how to implement this.

felixerdy commented 6 years ago

I think this would work, I will check that later. Do you know what happens when the file doesn't exist @jaevans ? We should maybe catch that case.

Thanks for your contribution!

jaevans commented 6 years ago

Sorry I didn't get back to you, I was out of town. A quick test to use a non-existent file name simply led to the image disappearing. I didn't check the console to see if there were any errors logged, I'll check that after I get to work today.

jaevans commented 6 years ago

I checked again today and setting an invalid path just causes the icon to not appear. There is no log of an error on the console. I don't think there needs to be any checking around the existence of the image.

felixerdy commented 6 years ago

Alright, thank you! 👍