summaryrefslogtreecommitdiffstats
path: root/src/svgpan_js.h
diff options
context:
space:
mode:
authorDimitri van Heesch <dimitri@stack.nl>2011-11-17 21:22:48 (GMT)
committerDimitri van Heesch <dimitri@stack.nl>2011-11-17 21:22:48 (GMT)
commit720d85edd0316e1cedec3402e204ce418174305d (patch)
tree0c7c3ab3d6f38e212b2cd4a4628e3c9d32d49db3 /src/svgpan_js.h
parent8491e9fbd06ef8a8f1cc542a524c673d7781d4b6 (diff)
downloadDoxygen-720d85edd0316e1cedec3402e204ce418174305d.zip
Doxygen-720d85edd0316e1cedec3402e204ce418174305d.tar.gz
Doxygen-720d85edd0316e1cedec3402e204ce418174305d.tar.bz2
Release-1.7.5.1-20111117
Diffstat (limited to 'src/svgpan_js.h')
-rw-r--r--src/svgpan_js.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/svgpan_js.h b/src/svgpan_js.h
index 7cbbdfc..260d4f7 100644
--- a/src/svgpan_js.h
+++ b/src/svgpan_js.h
@@ -66,7 +66,7 @@
" windowWidth = 800;\n"
" windowHeight = 600;\n"
" }\n"
-" minZoom = Math.min(windowHeight/viewHeight,windowWidth/viewWidth);\n"
+" minZoom = Math.min(Math.min(viewHeight,windowHeight)/viewHeight,Math.min(viewWidth,windowWidth)/viewWidth);\n"
" maxZoom = minZoom+1.5;\n"
" zoomInFactor = Math.pow(maxZoom/minZoom,1.0/zoomSteps);\n"
" zoomOutFactor = 1.0/zoomInFactor;\n"
@@ -168,6 +168,7 @@
"function handleMouseWheel(evt) \n"
"{\n"
" if (!evt) evt = window.evt;\n"
+" if (!evt.shiftKey) return; // only zoom when shift is pressed\n"
" if (evt.preventDefault) evt.preventDefault();\n"
" evt.returnValue = false;\n"
"\n"