Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CLOSED] Extend the folder drop on icon to any file type on mac. #235

Open
core-ai-bot opened this issue Aug 17, 2021 · 7 comments
Open

Comments

@core-ai-bot
Copy link
Member

Issue by RaymondLim
Friday Nov 01, 2013 at 16:48 GMT
Originally opened as adobe#367


Also allow user to use "Open With" for image file extensions. This fixes issue adobe/brackets#5759

@eugeneo Can you review this and comment if you see something not right?
@bchintx I think you should review this too.


RaymondLim included the following code: https://github.com/adobe/brackets-shell/pull/367/commits

@core-ai-bot
Copy link
Member Author

Comment by bchintx
Friday Nov 01, 2013 at 21:09 GMT


@RaymondLim Done with initial review. This info.plist change appears to work just fine, but I'll wait for you to respond to @eugeneo 's comment before deciding to merge this change.

@core-ai-bot
Copy link
Member Author

Comment by RaymondLim
Friday Nov 01, 2013 at 22:09 GMT


@eugeneo

in the case extensions add support to file types that are not currently supported.

Yes, my current change is exactly for file types that are not yet supported. So if an extension provides a pdf viewer or a video viewer, then the users should be able to view these file types with drag-and-drop on icon.

Thanks for pointing out "public.image" UTI. It's definitely better than listing individual image extensions, but I do have two concerns (or questions) for you.

  • What is the key if we switch to "public.image"? I think it has to be LSItemContentTypes instead of CFBundleTypeExtensions that I'm currently using.
  • "public.image" covers more extensions than we actually support in our preview image feature. Dropping an image file other than the extensions that I have will not show up in the image viewer in Brackets. So if we switch to "public.image", then users can use "Open With" in Finder for those image extensions that we don't yet supported. ( which I think is misleading)

@core-ai-bot
Copy link
Member Author

Comment by eugeneo
Saturday Nov 02, 2013 at 04:20 GMT


Sorry, I overlooked the wildcard. I tested the change and found no issues.

I am not sure if there is a need to separately declare image extensions if there is a wildcard - I did not see any difference in my testing.

@core-ai-bot
Copy link
Member Author

Comment by RaymondLim
Saturday Nov 02, 2013 at 04:40 GMT


How about the key? Do you replace the key CFBundleTypeExtensions with LSItemContentTypes when you tested with "public.image"?

@core-ai-bot
Copy link
Member Author

Comment by eugeneo
Saturday Nov 02, 2013 at 19:26 GMT


I did not try public.image - I tried your change as is and then tried your change after removing CFBundleTypeExtensions with the list of image extensions - saw no difference. In both cases I was able to drop to Dock icon and to use Open With... and then browse to the application.

@core-ai-bot
Copy link
Member Author

Comment by bchintx
Wednesday Nov 06, 2013 at 21:42 GMT


I just re-tested with @RaymondLim 's original changes and with removing individual and/or all of the CFBundleTypeExtensions. From what I can tell, you do need to enumerate specific extensions in order support Open With of those file types. Otherwise, Brackets does not appear in the Open With list.

One observation: the Finder appears to cache the file type associations, so you'll need to be sure to do the following before any changes are recognized by the system:

  • rebuild Brackets.app with your updated info.plist;
  • run that just built Brackets.app; and
  • force quit (and restart) the Finder.

@core-ai-bot
Copy link
Member Author

Comment by bchintx
Wednesday Nov 06, 2013 at 21:46 GMT


Approving and Merging...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant