[MPlayer-dev-eng] [PATCH] Mac OS X Finder support

Chris Roccati roccati at pobox.com
Mon Nov 8 23:03:59 CET 2004


On 8 Nov 2004, at 00:18, Nicolas Plourde wrote:
> I dont think both can live together, sdl override the main function by 
> sdl_main
> thats why your patch do not work with it. Best option is to disable 
> sdl if using the finder support IMHO.

Ok, I think this time everything is as it should:

the 'odoc' Apple Event handler is now called macosx_finder_args.c
instead of replacing main() or clobbering argc/argv, the patch now 
changes parser-mpcmp.c at function m_config_parse_mp_command_line(). if 
mplayer was started from the finder, the arguments of the apple event 
are used to directly populate the play_tree_t structure, otherwise the 
normal command line processing will be performed. as a side effect, the 
two error messages are now passed to mp_msg(), which at this time is 
initialized.

when started from the finder, the quiet switch is enabled, because the 
status line (printed to stdout) would heavyly clutter the 
/Library/Logs/<user>/Console/console.log (by the way I've also noticed 
that the cache filling status seems to ingnore the quiet switch)...

-- look, ma': no main() function!! they can't call me a wrapper 
anymore!! --

-------------- next part --------------
A non-text attachment was scrubbed...
Name: macosx_finder.patch
Type: application/text
Size: 6706 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20041108/7a537c3b/attachment.bin>


More information about the MPlayer-dev-eng mailing list