macosx_application: handle URL events as fileopen events

This allows to open URLs directly with mpv. This is useful for streaming and
libquvi supported sites.
macosx_application: handle mpv:// links

Pretty useful for people writing userscripts for web browsers. Links starting
with 'mpv://' are forwarded to the mpv OSX bundle. The leading 'mpv://' is
stripped from the recived url and the rest of the string is inserted as is in
the playlist.
command: remove some unneeded code

chapter_display_name() always returns something.

The "chapter < -1" check is not needed, because this is done at the
start of the function.
command: make options writeable in idle mode

Until now, options could be accessed as properties via "options/name",
but the access was read-only. Change it so that write access is possible
in --idle mode. (All options have to support setting options at that
time, simply because of the way MPlayer designed per-file options.
During playback, normal properties take care of changing things,
including things backed by options.)

This is work in progress. There are some issues: at least setting the
"vf" and "af" options won't work for strange reasons.
mplayer: remove unused mp_add_subtitles() parameter
mp_core: fix a comment

track.demuxer is never NULL (anymore).
find_subfiles: don't try to open URLs as directories

Did things like opendir("http://..."). Makes no sense, and just
generates noise.
find_subfiles: use stat() instead of opening the file to check existence

Use mp_path_exists() to check for existence of a file (which in turn
uses stat()), instead of opening and closing it. The difference is that
if we don't have sufficient permissions to read the subtitle files, we
will loudly complain. Personally, I prefer this behavior.
find_subfiles: some cleanups

Remove a crap assert() (what... either it can't happen, or it should
error or at least abort() if it can't be handled).

Remove some dead definitions.
find_subfiles: don't auto-load .sub file if .idx file exists

External vobsubs usually come as .idx/.sub pairs. Loading the .idx file
implicitly loads the .sub file, whereas loading the .sub file will kind
of work, but miss important information such as subtitle resolution. Or
in other words, if the .idx file exists, adding the .sub file as track
is useless and confusing.

Explicitly remove .sub file from the auto-load suntitle list in these
cases. Standalone .sub files are still loaded.

We also drop that weird logic that excluded .utf8 files from being
loaded if -subcp was in use. I hope the associated use case didn't make
much sense to begin with. If not, we could still implement it properly,
instead of this weird hack.
mplayer: don't auto-load explicitly loaded subtitle files

Even if a subtitle was explicitly loaded with -sub, it was still auto-
loaded (if auto-loading applied to that file). Fix this by explicitly
checking whether a file is already loaded.

The check is maximal naive and just compares the filenames as strings.
The change in find_subfiles.c is so that "-sub something.ass" happens to
work (auto-loading prepended a "./" to it, so the naive filename
comparison check didn't work).
example.conf: some modifications

Remove options which are too obscure and most likely not very useful in
general, or update them to something more modern. Add some comments
about how configuration files work in general.
input: remove separation between key and control queue

This is actually quite useless. It also allows the control queue to
starve the key queue, because the control queue is always checked first.
input: redo what input events can be dropped

Until now, any command was dropped as soon as the input queue was full,
and the command was not an abort command (i.e. a command that exits the
player or goes to the next file).

This could cause issues with key down events (especially mouse buttons)
not being released.

Change it so that key up events can never be dropped. This is a bit
involved, because we know whether a key maps to an abort command only
after interpreting it, and interpreting it changes global state, which
in turn requires undoing the event if the input is dropped. Refactor
the code a bit to move more functionality into interpret_key() to make
this easier.
input: split queue_add() function

Split it into queue_add_head() and queue_add_tail(). Gets rid of the
weird, rarely used boolean parameter.
input: merge consecutive mouse move events

Might give better behavior on load.
input: don't deliver mouse events if mouse area is not set

This caused the OSC to be always visible at startup on X11:
- EnterNotify event send a mouse event to input.c
- OSC has not completely initialized yet, and no mouse area is set
- mouse event is dispatched to "showhide" OSC section
- OSC becomes visible, regardless of mouse position

Fix this by treating the mouse area as empty if it's not set, instead of
infinite as it was before this commit. This means an input section must
set a mouse area to receive mouse events at all. We also have to change
the default section to receive mouse events with the new behavior.

Also, if MOUSE_MOVE is unmapped (or mapped to something that doesn't
parse), and produces no command, the mouse position wouldn't be updated
(because the mouse position is bound to input commands), so we have to
generate a dummy command in this case.

(This matters only for the OSC, On Screen Controller, which isn't merged
yet, so these changes shouldn't have much effect right now.)
input: rearrange code

Let all key events go through mp_input_feed_key() internally, and also
do double click and MP_INPUT_RELEASE_ALL handling there. Move
check_autorepeat() to where it's actually used.
options: cosmetics: move cursor_autohide_delay definition

No functional changes.
options: remove --(no-)mouseinput option

I have no idea why it exists, as it's redundant to --(no-)mouse-movements.