modify mouse gesture handler