fix keycode handlers, when multi instances