Enjoy an ad free experience by logging in. Not a member yet? Register.
|
|
Results 1 to 4 of 4
-
03-20-2016, 06:18 PM #1New Coder
- Join Date
- Dec 2014
- Location
- Kaunas, Lithuania
- Posts
- 58
- Thanks
- 5
- Thanked 0 Times in 0 Posts
Events on entering or leaving screen
For example in Facebook, when the player goes out of screen, video stops. Or like in here: Daisoras when you scroll down a bit, some animations start. It doesn't look like a window.pageYOffset thing, because if I zoom out the screen to where I can view these elements when page loads, the animations do the same without any scrolling.
Any advice or a link on to how to do that?
-
03-23-2016, 08:23 AM #2New Coder
- Join Date
- Dec 2014
- Location
- Kaunas, Lithuania
- Posts
- 58
- Thanks
- 5
- Thanked 0 Times in 0 Posts
wow. anybody, anytime now?
-
03-24-2016, 05:35 AM #3New to the CF scene
- Join Date
- Mar 2016
- Posts
- 9
- Thanks
- 0
- Thanked 0 Times in 0 Posts
i think there is no one who can answer this question. Well LS500 i am quite new in this field and i really don't know about this otherwise i will answer your question.
Good Luck !
-
03-24-2016, 10:13 AM #4New Coder
- Join Date
- Feb 2016
- Posts
- 80
- Thanks
- 0
- Thanked 16 Times in 16 Posts
This code does it:
It uses jQuery, don't forget to include it.Code:$(window).on("mouseenter", function () { alert("enter") }); $(window).on("mouseleave", function () { alert("leave") });



Reply With Quote
