browser_bug416661.js
Go to the documentation of this file.
3  tabElm.linkedBrowser.removeEventListener("load", start_test_prefNotSet, true);
4  tabElm.linkedBrowser.addEventListener("load", continue_test_prefNotSet, true);
5 
6  is(ZoomManager.zoom, 1, "initial zoom level should be 1");
7  FullZoom.enlarge();
8 
9  //capture the zoom level to test later
10  zoomLevel = ZoomManager.zoom;
11  isnot(zoomLevel, 1, "zoom level should have changed");
12 
13  content.location =
14  "http://localhost:8888/browser/browser/base/content/test/moz.png";
15 }
16 
18  tabElm.linkedBrowser.removeEventListener("load", continue_test_prefNotSet, true);
19  tabElm.linkedBrowser.addEventListener("load", end_test_prefNotSet, true);
20 
21  is(ZoomManager.zoom, 1, "zoom level pref should not apply to an image");
22  FullZoom.reset();
23 
24  content.location =
25  "http://localhost:8888/browser/browser/base/content/test/zoom_test.html";
26 }
27 
28 function end_test_prefNotSet() {
29  is(ZoomManager.zoom, zoomLevel, "the zoom level should have persisted");
30 
31  // Reset the zoom so that other tests have a fresh zoom level
32  FullZoom.reset();
33  gBrowser.removeCurrentTab();
34  finish();
35 }
36 
37 
38 function test() {
40 
41  tabElm = gBrowser.addTab();
42  gBrowser.selectedTab = tabElm;
43  tabElm.linkedBrowser.addEventListener("load", start_test_prefNotSet, true);
44 
45  content.location =
46  "http://localhost:8888/browser/browser/base/content/test/zoom_test.html";
47 
48 }
function start_test_prefNotSet()
var FullZoom
var tabElm
function continue_test_prefNotSet()
waitForExplicitFinish()
var zoomLevel
function end_test_prefNotSet()
function test()