Skip to content
Fork of TabWindowVisibilityManager v1.0 by Jonathan Marzullo (jonathanfever@gmail.com)
JavaScript
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
LICENSE improve file permissions Jul 11, 2016
Readme.md
TabWindowVisibilityManager.js
bower.json improve file permissions Jul 11, 2016

Readme.md

TabWindowVisibilityManager

This plugin will listen when switching between browser tabs using the HTML5 Visibility API. And will also listen for browser window focus and blur events. Add your code to pause and resume when leaving and returning to your webpage.

Orignal by Jonathan Marzullo, Source

Usage

// TabWindowVisibilityManager
$(window).TabWindowVisibilityManager({
    onFocusCallback: function(){
           // resume() code goes here
    },
    onBlurCallback: function(){
           // pause() code goes here
    }
});

Install

Download from the project page.

Install with Bower: bower install --save tatundkraft/TabWindowVisibilityManager

You can’t perform that action at this time.