surge-synthesizer / surge

Synthesizer plug-in (previously released as Vember Audio Surge)
https://surge-synthesizer.github.io/
GNU General Public License v3.0
3.17k stars 400 forks source link

"Reveal in Finder" #6488

Open baconpaul opened 2 years ago

baconpaul commented 2 years ago

A problem I have a lot is

I have a patch which shows a feature or a bug I want to post it to discord so then I do menu / open user data fodler then move that window and look at the category then go back to that window and look in the category and find the patch

macOS uses 'reveal in finder' as a gesture for this in most apps. Surge should do that too (and either leave it out or have appropriate equivalent on other oses)

baconpaul commented 2 years ago
open -R ~/Documents/Surge\ XT/Patches/Bacon\ Paul/Like\ a\ Turing.fxp 

does it

baconpaul commented 2 years ago

The windows equivalent is

explorer /select,c:\path\to\something

apparently

mkruselj commented 2 years ago

This makes sense for wavetables and FX/LFO presets as well.

baconpaul commented 2 years ago

So what I'll do is add a Surge::GUI::AddRevealInFinderMenu(juce::PopupMenu &, const std::string &what, const fs::path &) type API which is a no-op on lin, on mac adds a "Reveal " + what + " in finder" menu item which does the open and on win adds a "Reveal " + what + " in explorer" menu item which does the above. Then we can sprinkle it wherever we want!

mkruselj commented 2 years ago

IMHO the "what" is not needed. Entries could just be:

Reveal in Finder... Show in Explorer...

Ellipsis important.

I think the wording is usually different on Win (it's not reveal). But not at desktop until tomorrow so can't check.

baconpaul commented 2 years ago

Gotcha - fine with me!

baconpaul commented 2 years ago

Function is in place and its there for patches. Others are annoyingly annoying so I didn't do them tonight. but i was tired of not having it for patches. And it's great for patches! But will leave this issue open for the other file types.

baconpaul commented 2 years ago

LFO presets don't remember the loaded preset, so it is really hard to do those. FX presets do, but remember it in the wrong place, so it is really hard to do those also. May be possible. Wavetables I can do I think, if we want to. My gut is do patches in 1.1.1 and push the rest to 1.1.x if ever.

mkruselj commented 2 years ago

Sounds good!

luzpaz commented 1 year ago

What's left to do here ?