Where to receive MCI PostMessageW notifications?
eric.pouech at orange.fr
Wed Nov 11 07:12:35 CST 2009
Joerg-Cyril.Hoehle at t-systems.com a écrit :
> the MCI relies on notification to implement auto-open correctly. When
> the command is done, it must send out a notification via PostMessageW.
> The receiver then ought to call mciClose.
> One possible implementation would be to have auto-open start a thread
> that does nothing else but wait for this message to arrive, then call
> mciClose. I wonder if there's something more lightweight than a
> thread (this is not Erlang) that could be used inside Wine.
> What could be used that reacts asynchronously to PostMessageW?
> Currently, the missing auto-open functionality causes
> - unclosed files (some seen as error messages when Wine exits)
> (here it is essential that the notification works 100%)
> - some application hangs, some of them in Bugzilla.
> Jörg Höhle
create a (hidden) window (in winmm) where you handle the mci
notification (which means you must force MCI_NOTIFY flag with this
window handle when sending a MCI command down to a driver)
I wonder how native does when no message loop exists in the application
(should be tested) (maybe peek for the notif message upon entrance of
some of the MCI funcs ?)
"The problem with designing something completely foolproof is to underestimate the ingenuity of a complete idiot." (Douglas Adams)
More information about the wine-devel