Jdlrobson has uploaded a new change for review. (
https://gerrit.wikimedia.org/r/338286 )
Change subject: Do not merge as is(Squash if needed)
......................................................................
Do not merge as is(Squash if needed)
If we don't care about time hidden before the page has been
rendered to the user, then there is no reason to do this. If a
user opens a link in a new tab and then tabs to it, first paint
will correspond to the time the tab was switched to.
The downside of this approach is that if first paint is not
available, in this same scenario, the time visible will be 0.
(see follow up)
Change-Id: I7aee7999e7331b9dd62c38b14e01987555c93973
---
M modules/ext.wikimediaEvents.readingDepth.js
1 file changed, 0 insertions(+), 5 deletions(-)
git pull
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/WikimediaEvents
refs/changes/86/338286/1
diff --git a/modules/ext.wikimediaEvents.readingDepth.js
b/modules/ext.wikimediaEvents.readingDepth.js
index 3ee1f45..6783c02 100644
--- a/modules/ext.wikimediaEvents.readingDepth.js
+++ b/modules/ext.wikimediaEvents.readingDepth.js
@@ -144,11 +144,6 @@
}
if ( isEnabled() ) {
- if ( document.hidden ) {
- // If a new tab is open it may have started off as
hidden
- // so we record as hidden from the very start.
- pausedAt = navStart;
- }
$( window ).on( 'beforeunload', function () {
logEvent( 'pageUnloaded' );
} ).on( 'visibilitychange', function () {
--
To view, visit https://gerrit.wikimedia.org/r/338286
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I7aee7999e7331b9dd62c38b14e01987555c93973
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/WikimediaEvents
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits