http://bugs.winehq.org/show_bug.cgi?id=5224
--- Comment #20 from Austin English austinenglish@gmail.com 2008-02-16 19:44:06 --- (In reply to comment #18)
Vincent Povirk recently submitted a patch "tools: add a wrapper script for starting files from file managers and make wine.desktop use it" http://article.gmane.org/gmane.comp.emulators.wine.patches/47072 which is titled "Start a file as if it were double-clicked in windows explorer."
I'm writing this here after I pointed out to Vincent that this patch doesn't exactly live up its name, but I agree with the direction it's going in, but this patch shouldn't be committed. I think that a patch of this nature could directly address and solve this bug, but it's not possible to give windows explorer behaviour in a shell script alone.
Such a patch will need to always quote the application name always quoted as returned by GetCommandLineA, because windows explorer _always_ quotes this. Quoting is a requirement to allow it to be parsed correctly if there are spaces because the string returned by GetCommandLineA is delimited by spaces outside of quotes ".
This behaviour can be tested using the example program provided in comment #15. Running it as GetCommandLineA.exe should print out "GetCommandLineA.exe" if the behaviour is correct. If it is incorrect then GetCommandLineA.exe will be printed.
Please send this info to wine-devel and/or wine-patches, not bugzilla.