Add HTMLCanvasDataSource::Empty that represent transparent black instead of HTMLCanvasDataSource::Image(None) (#33519)

* `HTMLCanvasDataSource::Empty` that represent transparent black instead of Image(None)

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>

* Fix warning from 3a0d27b231

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>

---------

Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
This commit is contained in:
Samson 2024-09-22 16:04:53 +02:00 committed by GitHub
parent bab769a7cf
commit 3e29131d64
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 41 additions and 36 deletions

View file

@ -116,8 +116,10 @@ pub enum LayoutElementType {
pub enum HTMLCanvasDataSource {
WebGL(ImageKey),
Image(Option<IpcSender<CanvasMsg>>),
Image(IpcSender<CanvasMsg>),
WebGPU(ImageKey),
/// transparent black
Empty,
}
pub struct HTMLCanvasData {