added support for mouse wheel on X.

This commit is contained in:
crs
2002-05-23 15:50:38 +00:00
parent 4542bb9e40
commit 24f5b66cf3
2 changed files with 23 additions and 2 deletions

View File

@@ -124,6 +124,14 @@ void CXWindowsPrimaryScreen::run()
if (button != kButtonNone) {
m_server->onMouseUp(button);
}
else if (xevent.xbutton.button == 4) {
// wheel forward (away from user)
m_server->onMouseWheel(120);
}
else if (xevent.xbutton.button == 5) {
// wheel backward (toward user)
m_server->onMouseWheel(-120);
}
break;
}