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

Drag & Drop support (for images) #761

Open
2 tasks done
nevara opened this issue Apr 10, 2024 · 6 comments
Open
2 tasks done

Drag & Drop support (for images) #761

nevara opened this issue Apr 10, 2024 · 6 comments
Labels
enhancement New feature or request help wanted Extra attention is needed nsmenu Limitation of NSMenu

Comments

@nevara
Copy link

nevara commented Apr 10, 2024

Before Submitting Your Feature Request

  • Check that there isn't already a similar feature request to avoid creating a duplicate.
  • I have seen the FAQ.

Problem

It would be great to have drag & drop support for images to pull them into websites or other apps for example.

Solution

No response

@nevara nevara added the enhancement New feature or request label Apr 10, 2024
@p0deje p0deje added the nsmenu Limitation of NSMenu label Apr 10, 2024
@p0deje
Copy link
Owner

p0deje commented Apr 10, 2024

It's not currently possible to implement it due to the limitations of NSMenu. I'll keep that in mind whenever I start working on re-writing Maccy from NSMenu.

@p0deje p0deje added the help wanted Extra attention is needed label Apr 10, 2024
@gibfahn
Copy link

gibfahn commented Aug 23, 2024

@p0deje is this something that would be more doable in the 2.0 version? Not sure whether that still uses NSMenu.

@p0deje
Copy link
Owner

p0deje commented Aug 23, 2024

@gibfahn Yes, it would be possible in 2.0 since it doesn't use NSMenu.

@dtonda8
Copy link

dtonda8 commented Sep 29, 2024

It doesn't seem to work on 2.0 (at least on my end). Can anyone confirm that it is working on? If so, I will look into my installation.

@p0deje
Copy link
Owner

p0deje commented Sep 30, 2024

It's not implemented yet.

@gibfahn
Copy link

gibfahn commented Oct 6, 2024

May or may not be useful for anyone else, but my workaround for this is this zsh function:

# Save the current clipboard to a png file, copy the path to the clipboard, and show the file
# in Finder. This allows you to easily drag the file, or paste it with a ⇧⌘g in a file
# picker window.
clipboard_image_save() {
  local screenshot_path
  screenshot_path=$HOME/tmp/screen_shot_recording/screenshot_$(date "+%Y-%m-%d_%H-%M-%S").png
  osascript -e "set png_data to the clipboard as «class PNGf»
	set the_file to open for access POSIX path of (POSIX file \"$screenshot_path\") with write permission
	write png_data to the_file
	close access the_file"

  echo "Created $screenshot_path"
  pbcopy <<<$screenshot_path
  # Reveal in Finder.
  open -R $screenshot_path
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed nsmenu Limitation of NSMenu
Projects
None yet
Development

No branches or pull requests

4 participants