tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

selection_cross_shadow_boundary_helper.js (573B)


      1 // Helper file for test_selection_cross_shadow_boundary_* related tests
      2 
      3 function drag(
      4  fromTarget,
      5  fromX,
      6  fromY,
      7  toTarget,
      8  toX,
      9  toY,
     10  withAccelKey = false
     11 ) {
     12  synthesizeMouse(fromTarget, fromX, fromY, {
     13    type: "mousemove",
     14    accelKey: withAccelKey,
     15  });
     16  synthesizeMouse(fromTarget, fromX, fromY, {
     17    type: "mousedown",
     18    accelKey: withAccelKey,
     19  });
     20  synthesizeMouse(toTarget, toX, toY, {
     21    type: "mousemove",
     22    accelKey: withAccelKey,
     23  });
     24  synthesizeMouse(toTarget, toX, toY, {
     25    type: "mouseup",
     26    accelKey: withAccelKey,
     27  });
     28 }