avm1: Remove `DisplayObject::prev_avm1_clip`
It is no longer needed.
This commit is contained in:
parent
de6163569e
commit
81f803d77e
|
@ -466,11 +466,8 @@ impl<'gc> Avm1<'gc> {
|
||||||
clip: DisplayObject<'gc>,
|
clip: DisplayObject<'gc>,
|
||||||
) {
|
) {
|
||||||
// Adding while iterating is safe, as this does not modify any active nodes.
|
// Adding while iterating is safe, as this does not modify any active nodes.
|
||||||
if clip.next_avm1_clip().is_none() && clip.prev_avm1_clip().is_none() {
|
if clip.next_avm1_clip().is_none() {
|
||||||
if let Some(head) = self.clip_exec_list {
|
clip.set_next_avm1_clip(gc_context, self.clip_exec_list);
|
||||||
head.set_prev_avm1_clip(gc_context, Some(clip));
|
|
||||||
clip.set_next_avm1_clip(gc_context, self.clip_exec_list);
|
|
||||||
}
|
|
||||||
self.clip_exec_list = Some(clip);
|
self.clip_exec_list = Some(clip);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -74,11 +74,6 @@ pub struct DisplayObjectBase<'gc> {
|
||||||
scale_y: Percent,
|
scale_y: Percent,
|
||||||
skew: f64,
|
skew: f64,
|
||||||
|
|
||||||
/// The previous display object in order of AVM1 execution.
|
|
||||||
///
|
|
||||||
/// `None` in an AVM2 movie.
|
|
||||||
prev_avm1_clip: Option<DisplayObject<'gc>>,
|
|
||||||
|
|
||||||
/// The next display object in order of execution.
|
/// The next display object in order of execution.
|
||||||
///
|
///
|
||||||
/// `None` in an AVM2 movie.
|
/// `None` in an AVM2 movie.
|
||||||
|
@ -133,7 +128,6 @@ impl<'gc> Default for DisplayObjectBase<'gc> {
|
||||||
scale_x: Percent::from_unit(1.0),
|
scale_x: Percent::from_unit(1.0),
|
||||||
scale_y: Percent::from_unit(1.0),
|
scale_y: Percent::from_unit(1.0),
|
||||||
skew: 0.0,
|
skew: 0.0,
|
||||||
prev_avm1_clip: None,
|
|
||||||
next_avm1_clip: None,
|
next_avm1_clip: None,
|
||||||
masker: None,
|
masker: None,
|
||||||
maskee: None,
|
maskee: None,
|
||||||
|
@ -342,14 +336,6 @@ impl<'gc> DisplayObjectBase<'gc> {
|
||||||
self.parent = parent;
|
self.parent = parent;
|
||||||
}
|
}
|
||||||
|
|
||||||
fn prev_avm1_clip(&self) -> Option<DisplayObject<'gc>> {
|
|
||||||
self.prev_avm1_clip
|
|
||||||
}
|
|
||||||
|
|
||||||
fn set_prev_avm1_clip(&mut self, node: Option<DisplayObject<'gc>>) {
|
|
||||||
self.prev_avm1_clip = node;
|
|
||||||
}
|
|
||||||
|
|
||||||
fn next_avm1_clip(&self) -> Option<DisplayObject<'gc>> {
|
fn next_avm1_clip(&self) -> Option<DisplayObject<'gc>> {
|
||||||
self.next_avm1_clip
|
self.next_avm1_clip
|
||||||
}
|
}
|
||||||
|
@ -989,16 +975,6 @@ pub trait TDisplayObject<'gc>:
|
||||||
self.parent().filter(|p| p.as_container().is_some())
|
self.parent().filter(|p| p.as_container().is_some())
|
||||||
}
|
}
|
||||||
|
|
||||||
fn prev_avm1_clip(&self) -> Option<DisplayObject<'gc>> {
|
|
||||||
self.base().prev_avm1_clip()
|
|
||||||
}
|
|
||||||
fn set_prev_avm1_clip(
|
|
||||||
&self,
|
|
||||||
gc_context: MutationContext<'gc, '_>,
|
|
||||||
node: Option<DisplayObject<'gc>>,
|
|
||||||
) {
|
|
||||||
self.base_mut(gc_context).set_prev_avm1_clip(node);
|
|
||||||
}
|
|
||||||
fn next_avm1_clip(&self) -> Option<DisplayObject<'gc>> {
|
fn next_avm1_clip(&self) -> Option<DisplayObject<'gc>> {
|
||||||
self.base().next_avm1_clip()
|
self.base().next_avm1_clip()
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue