-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Handle case when layout object does not exist in Delegated Ink API up…
…dateInkTrailStartPoint Early exit if layout object associated with presentation area element does not exist. Bug: 1264352 Change-Id: I70fa3c2e3f36c6eba36ab4202e21198bdea31b46 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3261969 Reviewed-by: Kent Tamura <[email protected]> Commit-Queue: Olga Gerchikov <[email protected]> Cr-Commit-Position: refs/heads/main@{#938777} NOKEYCHECK=True GitOrigin-RevId: 83b73115559bb86fff5f904319e70febbea0766e
- Loading branch information
1 parent
e74727c
commit 16a57cc
Showing
2 changed files
with
33 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
21 changes: 21 additions & 0 deletions
21
blink/web_tests/external/wpt/delegated-ink/delete-presentation-area.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
<!DOCTYPE html> | ||
<script src="/resources/testharness.js"></script> | ||
<script src="/resources/testharnessreport.js"></script> | ||
<script src="/resources/testdriver.js"></script> | ||
<script src="/resources/testdriver-actions.js"></script> | ||
<script src="/resources/testdriver-vendor.js"></script> | ||
|
||
<canvas id="canvas"></canvas> | ||
<script> | ||
promise_test(async (t) => { | ||
const presenter = await navigator.ink.requestPresenter({presentationArea: canvas}); | ||
const style = { color: "green", diameter: 6 }; | ||
|
||
window.addEventListener("pointermove", evt => { | ||
presenter.updateInkTrailStartPoint(evt, style); | ||
}); | ||
document.body.removeChild(canvas); | ||
const actions_promise = new test_driver.Actions().pointerMove(10, 10).send(); | ||
t.add_cleanup(() => actions_promise); | ||
}, "No crash when accessing presenter associated with deleted presentation area."); | ||
</script> |