command: add properties for playlist position

playlist-pos can set/get the current playlist index. playlist-count
returns the number of entries in the playlist.
command: make raw percent-pos property return fractions

percent-pos was an integer (0-100). Sometimes higher precision is
wanted, but the property is this way because fractional parts would
look silly with normal OSD usage. As a compromise, make percent-pos
double (i.e. includes fractional parts), but print it as integer.

So ${percent-pos} is like an integer, but not ${=percent-pos}.
input: handle mouse movement differently

Before this commit, mouse movement events emitted a special command
("set_mouse_pos"), which was specially handled in command.c. This was
once special-cased to the dvdnav and menu code, and did nothing after
libmenu and dvdnav were removed.

Change it so that mouse movement triggers a pseudo-key ("MOUSE_MOVE"),
which then can be bound to an arbitrary command. The mouse position is
now managed in input.c. A command which actually needs the mouse
position can use either mp_input_get_mouse_pos() or mp_get_osd_mouse_pos()
to query it. The former returns raw window-space coordinates, while the
latter returns coordinates transformed to OSD- space. (Both are the same
for most VOs, except vo_xv and vo_x11, which can't render OSD in
window-space. These require extra code for mapping mouse position.)

As of this commit, there is still nothing that uses mouse movement, so
MOUSE_MOVE is mapped to "ignore" to silence warnings when moving the
mouse (much like MOUSE_BTN0).

Extend the concept of input sections. Allow multiple sections to be
active at once, and organize them as stack. Bindings from the top of
the stack are preferred to lower ones.

Each section has a mouse input section associated, inside which mouse
events are associated with the bindings. If the mouse pointer is
outside of a section's mouse area, mouse events will be dispatched to
an input section lower on the stack of active sections. This is intended
for scripting, which is to be added later. Two scripts could occupy
different areas of the screen without conflicting with each other. (If
it turns out that this mechanism is useless, we'll just remove it
again.)
manpage: document input sections
command: add commands to enable/disable input sections

For now, it's mostly for testing. It also might allow to create key
binding state machines, but this sounds questionable.
input: trigger mouse_leave key bindings if mouse leaves mouse area

Also, implement mouse leave events for X11. But evne on other
platforms, these events will be generated if mouse crosses a section's
mouse area boundaries within the mpv window.
mplayer: don't hide mouse cursor if mouse is inside mouse area
w32_common: refactor mouse button code, handle mouse up events

Instead of sending a single event on click, send both down and up
events.
w32_common: prevent that window dragging and mouse input interfere
input: don't keep separate sections for builtin key bindings

Instead mark individual key bindings as builtin.

Not sure whether this is conceptually simpler or more complicated.
For one, it requires the annoying remove_binds() function to wipe
existing bindings instead of just killing the section, on the other
hand it gets rid of almost all special handling of builtin vs. normal
sections.
input: store number of keys, instead of using 0-termination
input: store number of binds, instead of using 0-termination
sub: update subtitle time offset even if paused

This was changed as part of commit b44202b as an intended
simplification, but it's actually nicer to have the subtitles
update immediately even if paused.
command: redraw subs if sub-delay is changed

Though in practice this probably happened anyway, because OSD was
redrawn.
dec_sub: introduce sub_control(), use it for sub_step

This means the direct libass usage can be removed from command.c, and no
weird hacks for retrieving the ASS_Track are needed.

Also fix a bug when using this feature with ordered chapters.
sd_ass: convert pts to integer for get_text()

Gives more consistent rounding, which makes sub_step behave better.
sd_lavc: respect forced subs only setting for DVD subs

Like the old spudec.c code did. Untested, I (probably) don't have a
sample with subtitles that have this flag set.