more work on mouse events
scripted update of code from master at 2a52ff3 more work on mouse events