[Webkit-unassigned] [Bug 186676] New: visibilitychange event not fired when window moved to a separate workspace

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Jun 15 10:02:26 PDT 2018


https://bugs.webkit.org/show_bug.cgi?id=186676

            Bug ID: 186676
           Summary: visibilitychange event not fired when window moved to
                    a separate workspace
           Product: WebKit
           Version: WebKit Nightly Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: WebKit Gtk
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: code at daniel.priv.no
                CC: bugs-noreply at webkitgtk.org

Steps to reproduce:
0. Open GNOME Web (formerly “Epiphany”) under a GNOME desktop
1. Install the following event handler in on about:blank:

document.addEventListener('visibilitychange', function() {
  document.body.appendChild(document.createTextNode(document.visibilityState));
  console.log(document.visibilityState);
});

2. Switch to a separate desktop workspace so that the GNOME Web window is no longer on the active workspace., and then switch back.

Expected results:
Should have logged two messages: "hidden" and "visible".

Actual results:
No visibilitychange event is fired when the window is no longer visible.

Notes:
This works with macOS workspaces but not with GNOME workspaces. The GNOME Web bug tracker referred me here stating that it was a bug in WebKit GTK and not on their end.

Some times console.log(document.visibilityState) will report "undefined" but document.body.appendChild(document.createTextNode(document.visibilityState)) will report the correct state. Not sure if this is the expected behaviour or a separate bug.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20180615/1ff6b9be/attachment.html>


More information about the webkit-unassigned mailing list