- disabled mouse revert in win32 as it doesn't seem to work properly (screen freezes while dragging)
- changed the mouse cursor at startup so it always looks like the regular glest mouse (unless we get one of those new glest error message boxes)
This commit is contained in:
parent
2d3dad5a9b
commit
2ce421e06c
|
@ -253,8 +253,8 @@ int glestMain(int argc, char** argv){
|
|||
|
||||
NetworkInterface::setDisplayMessageFunction(ExceptionHandler::DisplayMessage);
|
||||
|
||||
showCursor(config.getBool("Windowed"));
|
||||
//showCursor(false);
|
||||
//showCursor(config.getBool("Windowed"));
|
||||
showCursor(false);
|
||||
|
||||
program= new Program();
|
||||
mainWindow= new MainWindow(program);
|
||||
|
|
|
@ -89,7 +89,7 @@ bool Window::handleEvent(){
|
|||
}
|
||||
|
||||
void Window::revertMousePos() {
|
||||
SetCursorPos(oldX, oldY);
|
||||
//SetCursorPos(oldX, oldY);
|
||||
}
|
||||
|
||||
string Window::getText(){
|
||||
|
@ -364,13 +364,18 @@ LRESULT CALLBACK Window::eventRouter(HWND hwnd, UINT msg, WPARAM wParam, LPARAM
|
|||
break; // not handled, send to DefWindowProc
|
||||
|
||||
case WM_MOUSEMOVE:
|
||||
|
||||
eventWindow->setMouseState(mbLeft, wParam & MK_LBUTTON);
|
||||
eventWindow->setMouseState(mbRight, wParam & MK_RBUTTON);
|
||||
eventWindow->setMouseState(mbCenter, wParam & MK_MBUTTON);
|
||||
eventWindow->setMouseState(mbButtonX1, wParam & MK_XBUTTON1);
|
||||
eventWindow->setMouseState(mbButtonX2, wParam & MK_XBUTTON2);
|
||||
eventWindow->eventMouseMove(mousePos.x, mousePos.y, &eventWindow->getMouseState());
|
||||
return 0;
|
||||
|
||||
const MouseState &ms = eventWindow->getMouseState();
|
||||
eventWindow->eventMouseMove(mousePos.x, mousePos.y, &ms);
|
||||
|
||||
//return 0;
|
||||
break;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue