Move charset conversion for MIDI import to separate files
Automatic charset detection for MIDI import (mozilla code)