diff options
author | John DeSilva <desilvjo@umich.edu> | 2015-12-13 12:20:18 -0500 |
---|---|---|
committer | John DeSilva <desilvjo@umich.edu> | 2015-12-13 12:27:05 -0500 |
commit | f244a7075c2a296d725d7acad0c043cc002a7f0b (patch) | |
tree | bf0ca7e94394dc5f1265f480779e0121b55c9f5f /components/script/dom/touchevent.rs | |
parent | e493a0655e69c1472a53708d213fd102decc59cb (diff) | |
download | servo-f244a7075c2a296d725d7acad0c043cc002a7f0b.tar.gz servo-f244a7075c2a296d725d7acad0c043cc002a7f0b.zip |
Make Event's isTrusted attribute unforgeable
Diffstat (limited to 'components/script/dom/touchevent.rs')
-rw-r--r-- | components/script/dom/touchevent.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/components/script/dom/touchevent.rs b/components/script/dom/touchevent.rs index 7340316f9fc..5d6b85a550a 100644 --- a/components/script/dom/touchevent.rs +++ b/components/script/dom/touchevent.rs @@ -114,4 +114,9 @@ impl<'a> TouchEventMethods for &'a TouchEvent { fn ChangedTouches(&self) -> Root<TouchList> { self.changed_touches.get() } + + /// https://dom.spec.whatwg.org/#dom-event-istrusted + fn IsTrusted(&self) -> bool { + self.uievent.IsTrusted() + } } |