MCPcopy Create free account
hub / github.com/Geant4/geant4 / SetZoom

Method SetZoom

source/visualization/OpenGL/src/G4OpenGLWin32Viewer.cc:478–488  ·  view source on GitHub ↗

/////////////////////////////////////////////////////////////////////////

Source from the content-addressed store, hash-verified

476
477//////////////////////////////////////////////////////////////////////////////
478void G4OpenGLWin32Viewer::SetZoom(G4int delta)
479//////////////////////////////////////////////////////////////////////////////
480//!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!//
481{
482 POINT mousePos;
483 GetCursorPos(&mousePos);
484 ScreenToClient(fWindow, &mousePos);
485
486 ZoomFromMouseWheel(delta, GetKeyState(VK_SHIFT) & 0x8000, mousePos.x, mousePos.y);
487
488}
489
490G4bool G4OpenGLWin32Viewer::GetWindowSize(unsigned int& a_w, unsigned int& a_h)
491{

Callers 1

WindowProcMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected