File tree Expand file tree Collapse file tree 1 file changed +1
-2
lines changed
src/resources/assets/js/annotations/components Expand file tree Collapse file tree 1 file changed +1
-2
lines changed Original file line number Diff line number Diff line change @@ -132,7 +132,6 @@ export default {
132
132
return function (event ) {
133
133
// dismiss every wheel event with deltaY less than 4
134
134
if (Math .abs (event .deltaY ) < 4 ) return
135
-
136
135
if ((time + wait - Date .now ()) < 0 ) {
137
136
fn (event );
138
137
time = Date .now ();
@@ -142,7 +141,6 @@ export default {
142
141
// triggered when mouse scroll is performed on "ol-viewport"
143
142
handleScale (event ) {
144
143
if (this .isEditing ) {
145
- // TODO: Get and save the default scale values, from these, compute the scale with each new scale value
146
144
this .scale += event .deltaY * - 0.001 ;
147
145
// Restrict scale
148
146
let val = Math .min (Math .max (0.5 , this .scale ), 2 );
@@ -342,6 +340,7 @@ export default {
342
340
});
343
341
},
344
342
mounted () {
343
+ // create Eventlistener for mouswheel interaction (used for scaling the context-layer, see handleScale() method)
345
344
let el = document .getElementsByClassName (" ol-viewport" )[1 ];
346
345
el .addEventListener (" wheel" , this .throttle (this .handleScale , 500 ));
347
346
}
You can’t perform that action at this time.
0 commit comments