all: use trait upcasting
This commit is contained in:
parent
f0caafc862
commit
09e5f89174
44 changed files with 90 additions and 269 deletions
|
|
@ -212,12 +212,9 @@ impl WlBuffer {
|
|||
match &*self.storage.borrow() {
|
||||
None => None,
|
||||
Some(s) => match s {
|
||||
WlBufferStorage::Shm { .. } => surface
|
||||
.shm_textures
|
||||
.front()
|
||||
.tex
|
||||
.get()
|
||||
.map(|t| t.into_texture()),
|
||||
WlBufferStorage::Shm { .. } => {
|
||||
surface.shm_textures.front().tex.get().map(|t| t as _)
|
||||
}
|
||||
WlBufferStorage::Dmabuf { tex, .. } => tex.clone(),
|
||||
},
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue