+38
−4
Loading
Note: if the original imageBitmap has been use for display, the source surface will have been cropped and the original cropping IntRect has been lost, in this case use cropped mSurface instead of mdata. If some of the new clip rect falls outside the source we have to crop the source if it hasn't been cropped. Q: Should I attempt to get tests for this added to WPT? Differential Revision: https://phabricator.services.mozilla.com/D124607