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


Quelle  helper_bug1756814.html   Sprache: HTML

 
 products/sources/formale Sprachen/C/Firefox/gfx/layers/apz/test/mochitest/helper_bug1756814.html


<!DOCTYPE HTML>
<html>
<head>
  <script type="application/javascript" src="apz_test_utils.js"></script>
  <script type="application/javascript" src="apz_test_native_event_utils.js"></script>
  <script src="/tests/SimpleTest/paint_listener.js"></script>
</head>
<body>
  <div style="height: 200vh;"></div>
</body>
<script type="application/javascript">

async function test() {
  const moveDistance = 10;

  // Start dragging the vertical scrollbar thumb.
  const startPoint = await scrollbarDragStart(window, 1);
  await promiseNativeMouseEventWithAPZ({
    target: window,
    offsetX: startPoint.x,
    offsetY: startPoint.y,
    type: "mousemove",
  });
  await promiseNativeMouseEventWithAPZ({
    target: window,
    offsetX: startPoint.x,
    offsetY: startPoint.y,
    type: "mousedown",
  });

  // Move the thumb and wait for a scroll event triggered by the movement.
  let scrollEventPromise = waitForScrollEvent(window);
  await promiseNativeMouseEventWithAPZ({
    target: window,
    offsetX: startPoint.x,
    offsetY: startPoint.y + moveDistance,
    type: "mousemove",
  });
  await scrollEventPromise;

  let scrollPosition = window.scrollY;

  // Append an element to the scroll container to expand the scroll range.
  const content = document.createElement("div");
  content.style.height = "200vh";
  document.body.appendChild(content);

  // flush the above change.
  document.documentElement.getBoundingClientRect();

  // Make sure the change has been reflected into APZ.
  await promiseApzFlushedRepaints();

  // Move the thumb again.
  scrollEventPromise = waitForScrollEvent(window);
  await promiseNativeMouseEventWithAPZ({
    target: window,
    offsetX: startPoint.x,
    offsetY: startPoint.y + moveDistance * 2,
    type: "mousemove",
  });

  await scrollEventPromise;
  ok(window.scrollY <= scrollPosition * 2,
     `The scroll position ${window.scrollY} should be less than ${scrollPosition*2}`);

  await promiseNativeMouseEventWithAPZ({
    target: window,
    offsetX: startPoint.x,
    offsetY: startPoint.y + moveDistance * 2,
    type: "mouseup",
  });
}

waitUntilApzStable()
.then(test)
.then(subtestDone, subtestFailed);

</script>
</html>

Messung V0.5
C=98 H=91 G=94

¤ Dauer der Verarbeitung: 0.10 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

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

Software

     Produkte
     Quellcodebibliothek

Aktivitäten

     Artikel über Sicherheit
     Anleitung zur Aktivierung von SSL

Muße

     Gedichte
     Musik
     Bilder

Jenseits des Üblichen ....

Besucherstatistik

Besucherstatistik

Monitoring

Montastic status badge