Eine aufbereitete Darstellung der Quelle

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

Benutzer

Quelle  helper_bug1989868.html

  Sprache: HTML
 

 products/Sources/formale Sprachen/C/Firefox/gfx/layers/apz/test/mochitest/helper_bug1989868.html


<!DOCTYPE html>
<html>
<meta name="viewport" content="width=device-width; initial-scale=1.0">
<title>Test that touch scrolling keeps working with a smooth scroll operation by JS</title>
<script src="/tests/SimpleTest/SimpleTest.js"></script>
<script src="/tests/SimpleTest/EventUtils.js"></script>
<script src="/tests/SimpleTest/paint_listener.js"></script>
<script src="apz_test_utils.js"></script>
<script src="apz_test_native_event_utils.js"></script>
<style>
body {
  margin: 0px;
  padding: 0px;
}
</style>
<div style="width: 100vw; height: 300vh;"></div>
<script>
async function test() {
  let scrollYInEventHandler;
  window.addEventListener("scroll", () => {
    scrollYInEventHandler = window.scrollY;
    // Trigger a smooth scroll.
    window.scrollTo({top: 0, behavior: "smooth"});
  }, { once: true });

  // Send touch events to scroll down the content.
  // Note that each touch event needs to be sent in each frame to
  // give a chance to receive a scroll event while sending the evets.
  for (let y = 200; y > 0; y -= 10) {
    await synthesizeNativeTouch(window, 100, y, SpecialPowers.DOMWindowUtils.TOUCH_CONTACT);
    await promiseFrame();
  }

  ok(scrollYInEventHandler * 2 <= window.scrollY,
    `The last scroll position ${window.scrollY} should be greater than the
     double of the position in scroll event handler ${scrollYInEventHandler}`);

  await synthesizeNativeTouch(window, 1000, SpecialPowers.DOMWindowUtils.TOUCH_REMOVE);
}

waitUntilApzStable()
.then(test)
.then(subtestDone, subtestFailed);
</script>
</html>

Messung V0.5 in Prozent
C=100 H=100 G=100

¤ Dauer der Verarbeitung: 0.3 Sekunden  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

PVS Prover

Isabelle Prover

NIST Cobol Testsuite

Cephes Mathematical Library

Vienna Development Method

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.






                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Open Source Software

     Quellcodebibliothek
     Eigene Quellcodes
     Fremde Quellcodes
     Suchen

Jenseits des Üblichen ....

Besucherstatistik

Besucherstatistik

Statistik
#Sources=277311
#Domains=752002