-
-
Notifications
You must be signed in to change notification settings - Fork 86
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
User never goes idle in cordova #47
Comments
I have never used it with Cordova, but I imagine there probably wouldn't be any |
Hi, Ok cool. Will have a look later and let you know what I find! Riaan On Thursday, December 18, 2014, Andrew Mao notifications@github.com wrote:
Riaan Jacobs |
Did you ever find anything on this? One way to test may be to fork the package and do some logging on the client side, just to see if the inactivity event is actually being sent to the server. |
So I've tested this. Currently user-status only detects online-offline activity (offline only happens with timeout). To implement idle user-status would just need to use document.addEventListener("pause", function() {
// is idle
});
document.addEventListener("resume", function() {
// is not idle
}); I've tested this in my app and it works great. When (for example) the home key is pressed, the "pause" event is fired. There is also an "offline" event, but I couldn't figure out when that is fired. I'm currently trying to PR this. |
tested and works. HOWEVER when user goes idle by "pause" then latestActivity gets "Invalid Date" because mizzao:timesync just isn't handling cordova somehow. Tracing this now. |
ah couldn't figure it out... for some reason HTTP.get() just doesn't get to the server (no error is returned either). Looks like an issue with the HTTP package, i'm out of ideas. |
Ok, got the timesync issue fixed, PR here Meteor-Community-Packages/meteor-timesync#26 |
This should be fixed, please try out v0.6.5 in your apps. |
Hi,
Im using this package with meteor (v1.0.1) Cordova on iOS. It works 100% on browser and on mobile browser - but when in Cordova the user never goes idle. Any ideas?
Thanks.
Regards,
Riaan
The text was updated successfully, but these errors were encountered: