Eine aufbereitete Darstellung der Quelle

 
     
 
 
Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 

Benutzer

Impressum browser_onbeforeunload_parent.js  Sprache: unbekannt

 
"use strict";

// We need to test a lot of permutations here, and there isn't any sensible way
// to split them up or run them faster.
requestLongerTimeout(6);

Services.scriptloader.loadSubScript(
  getRootDirectory(gTestPath) + "head_browser_onbeforeunload.js",
  this
);

add_task(async function () {
  await SpecialPowers.pushPrefEnv({
    set: [["dom.require_user_interaction_for_beforeunload", false]],
  });

  for (let actions of PERMUTATIONS) {
    info(
      `Testing frame actions: [${actions.map(action =>
        ACTION_NAMES.get(action)
      )}]`
    );

    info(`Testing tab close from parent process`);
    await doTest(actions, -1, tab => {
      let eventLoopSpun = false;
      Services.tm.dispatchToMainThread(() => {
        eventLoopSpun = true;
      });

      BrowserTestUtils.removeTab(tab);

      let result = { eventLoopSpun };

      // Make an extra couple of trips through the event loop to give us time
      // to process SpecialPowers.spawn responses before resolving.
      return new Promise(resolve => {
        executeSoon(() => {
          executeSoon(() => resolve(result));
        });
      });
    });
  }
});

add_task(async function cleanup() {
  await TabPool.cleanup();
});

Messung V0.5 in Prozent
C=92 H=77 G=84

[Seitenstruktur0.18Druckenetwas mehr zur Ethik2026-09-29]

                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Open Source Software

     Quellcodebibliothek
     Eigene Quellcodes
     Fremde Quellcodes
     Suchen

Jenseits des Üblichen ....
    

Besucherstatistik

Besucherstatistik

Statistik
#Sources=1126438
#Domains=1897691