nit: Silence nightly `dead_code` lint

This commit is contained in:
TÖRÖK Attila 2024-04-20 16:33:29 +02:00
parent 7f33dace8e
commit 3ca7cc821e
5 changed files with 10 additions and 15 deletions

View File

@ -49,13 +49,11 @@ impl<'gc> Graphic<'gc> {
let static_data = GraphicStatic {
id: swf_shape.id,
bounds: swf_shape.shape_bounds.clone(),
render_handle: Some(context.renderer.register_shape(
(&swf_shape).into(),
&MovieLibrarySource {
library,
gc_context: context.gc_context,
},
)),
render_handle: Some(
context
.renderer
.register_shape((&swf_shape).into(), &MovieLibrarySource { library }),
),
shape: swf_shape,
movie,
};

View File

@ -238,13 +238,9 @@ impl MorphShapeStatic {
handle
} else {
let library = library.library_for_movie(self.movie.clone()).unwrap();
let handle = context.renderer.register_shape(
(&frame.shape).into(),
&MovieLibrarySource {
library,
gc_context: context.gc_context,
},
);
let handle = context
.renderer
.register_shape((&frame.shape).into(), &MovieLibrarySource { library });
frame.shape_handle = Some(handle.clone());
handle
}

View File

@ -346,7 +346,6 @@ impl<'gc> MovieLibrary<'gc> {
pub struct MovieLibrarySource<'a, 'gc> {
pub library: &'a MovieLibrary<'gc>,
pub gc_context: &'a Mutation<'gc>,
}
impl<'a, 'gc> ruffle_render::bitmap::BitmapSource for MovieLibrarySource<'a, 'gc> {

View File

@ -164,6 +164,7 @@ impl<'gc> Eq for NetStream<'gc> {}
pub enum NetStreamType {
/// The stream is an FLV.
Flv {
#[allow(dead_code)] // set but never read
header: FlvHeader,
/// The currently playing video track's stream instance.

View File

@ -247,6 +247,7 @@ impl VertexAttributeFormat {
pub struct ShaderConfig<'a> {
pub shader_type: ShaderType,
pub vertex_attributes: &'a [Option<VertexAttributeFormat>; 8],
#[allow(dead_code)] // set but never read
pub sampler_configs: &'a [SamplerConfig; 8],
pub version: AgalVersion,
}