Closed nueverest closed 9 years ago
Thank you for posting your modifications for anyone else who is interested. I guess my thought is that once your mouse leaves the box, you are no longer able to move the zoomed image or interact in any way. Because of that, it seems natural that you'd need to move the mouse back into the box to 'unzoom'. For that reason, I will leave it as it is unless others feel it should change as well.
Is it possible to just have the "larger" image click large (full screen) instead of having the full size image load within the box? I don't want the end user to click on it and then have to click on the diagonal arrow in the upper corner to view it full screen. Thanks in advance!
Solved in version 2.0.0!
Our users are requesting that they be able to click anywhere on the screen to zoom out if they are currently zoomed in on the product.
Image illustrating cursor click positions that would allow the image to zoom out.![smoothproducts_zoomout_onclick_anywhere](https://cloud.githubusercontent.com/assets/2917370/3000958/0a3288f8-dd2a-11e3-91a7-0e078e2beb8e.png)
Here is Javascript I added to smoothproducts.js that allowed me to implement what I'm requesting.
Summary of what I did: Added two variables sp_zoomed_in and click_count Set those variables under 'Zoom In' and 'Zoom Out' Added $(document).click(function (event) {...} that registers clicks anywhere on the page, and zooms out if the click_count >=2 and the user is currently zoomed in.
Whether this is the best way or not I do not know. I just know that it is working for me.