Drag and drop after update
Audio converter and CD ripper for various formats
Brought to you by:
enzo
When finished updating to a new version using the update-tool, the program will automatically start. In that state, it's not possible to drag and drop a file from Windows Explorer into Fre:ac. You will have to close the program and restart it to re-enable this.
Anonymous
Thank you for reporting this!
This happens because the updater is running as an elevated process and then passes this process elevation on to fre:ac when restarting it. As Windows does not allow drag & drop between elevated an non-elevated processes, you will need to restart fre:ac for drag & drop to work again.
There is no really good fix for this as there is no Windows API to start a non-elevated process from an elevated one. The method suggested by Microsoft and others is more of a curious hack than a clean solution. It involves getting a handle to the shell's root window, querying the Explorer's process ID from it, opening that process to get a token describing its elevation level, copying the token and finally using it to start an app using the shell's elevation level.
I'll think about it, but I'm not sure I really want to implement something that hacky...
Ok, thanks for explaining that.
My compliments for this super application!
Ramon.
Just for the record,I found a more official method to accomplish this. It is part of the Windows 7 SDK Samples and uses COM APIs and interfaces to execute a process in the context of the Explorer process:
https://docs.microsoft.com/windows/win32/shell/samples-execinexplorer
https://github.com/pauldotknopf/WindowsSDK7-Samples/tree/master/winui/shell/appplatform/ExecInExplorer
This will be implemented for fre:ac 1.2 which will drop support for Windows XP (this new approach works on Windows Vista or later only).