Fix log trimming in Python 3, updating `mtreplay`

`mtedit` uses `MTReplay` to trim logs, so that function was broken in
Python 3 despite `mtedit` itself having been updated. To fix that, the
`mtreplay` code has been modernised somewhat, but I can't guarantee that
it actually works due to a lack xorg-conf entries for the devices I had
feedback reports to test with.

Due to the other methods of retrieving feedback (over SSH from a device,
or download from the feedback system) are broken currently, I couldn't
test those, and haven't applied fixes to their code paths (particularly
the log classes).

To test this, I had to comment out `#pragma GCC diagnostic ignored
"-Wsizeof-array-div"` in the Gestures library's
src/accel_filter_interpreter.c, then run `mtreplay` so that it could
compile the `replay` binary without errors.

TEST=Run `mtedit` with a local feedback ZIP file, with `-o log`. In the
     Web UI, adjust the slider and click "Shrink Range". Check that the
     `log` and `log.evdev` files in the current directory begin and end
     at the times selected in the UI.
BUG=none

Change-Id: I07004ee08c60cc5e775d1ac499f62b5d434a3c63
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/mttools/+/2036465
Reviewed-by: Sean O'Brien <seobrien@chromium.org>
Commit-Queue: Harry Cutts <hcutts@chromium.org>
Tested-by: Harry Cutts <hcutts@chromium.org>
9 files changed