PageSourceSearch

https://biblewebapp.com/study-v2/js/docs/plugins.fullscreen.js

js biblewebapp.com collected 2026-09-24 19:09:34 UTC 1,410 bytes, 58 lines download raw bytes

1	
2/**
3 * Fullscreen button
4 *
5 * @author John Dyer (http://j.hn/)
6 */
7 
8docs.plugins.push({
9
10	init: function(docManager) {
11		
12		var body = document.body,
13			isFullscreen = false;
14	
15		if (typeof body.requestFullScreen != 'undefined' ||
16			typeof body.webkitRequestFullScreen != 'undefined' ||
17			typeof body.mozRequestFullScreen != 'undefined') {
18	
19			$('<input type="button" id="docs-fullscreen" />')
20				.appendTo(docManager.header.find('#header-nav'))
21				.on('click', function() {
22				
23					if (typeof body.requestFullscreen != 'undefined') {
24						if (isFullscreen) {
25							document.exitFullscreen();
26						} else {
27							body.requestFullscreen();
28						}
29						isFullscreen = !isFullscreen;
30						
31					} else if (typeof body.webkitRequestFullScreen != 'undefined') {
32						
33						if (isFullscreen) {
34							document.webkitCancelFullScreen();
35						} else {
36							body.webkitRequestFullScreen();
37						}
38						isFullscreen = !isFullscreen;						
39						
40					} else if (typeof body.mozRequestFullScreen != 'undefined') {
41						
42						if (isFullscreen) {
43							document.mozCancelFullScreen();
44						} else {
45							body.mozRequestFullScreen();
46						}
47						isFullscreen = !isFullscreen;						
48					}
49					
50					if (isFullscreen)
51						$(this).addClass('is-fullscreen');
52					else
53						$(this).removeClass('is-fullscreen');
54				});
55		}
56		
57	}
58});

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.