mirror of
https://github.com/isledecomp/isle.git
synced 2026-01-28 10:41:15 +00:00
Fix
This commit is contained in:
parent
adc6b75135
commit
f1ea99e440
@ -40,6 +40,14 @@ class MxRect32 {
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline void CopyFrom(const MxRect32& p_rect)
|
||||
{
|
||||
this->m_left = p_rect.m_left;
|
||||
this->m_top = p_rect.m_top;
|
||||
this->m_right = p_rect.m_right;
|
||||
this->m_bottom = p_rect.m_bottom;
|
||||
}
|
||||
|
||||
inline void Intersect(const MxRect32& p_rect)
|
||||
{
|
||||
m_left = Max(p_rect.m_left, m_left);
|
||||
@ -99,14 +107,6 @@ class MxRect32 {
|
||||
inline void SetBottom(MxS32 p_bottom) { m_bottom = p_bottom; }
|
||||
|
||||
private:
|
||||
inline void CopyFrom(const MxRect32& p_rect)
|
||||
{
|
||||
this->m_left = p_rect.m_left;
|
||||
this->m_top = p_rect.m_top;
|
||||
this->m_right = p_rect.m_right;
|
||||
this->m_bottom = p_rect.m_bottom;
|
||||
}
|
||||
|
||||
inline static MxS32 Min(MxS32 p_a, MxS32 p_b) { return p_a <= p_b ? p_a : p_b; };
|
||||
inline static MxS32 Max(MxS32 p_a, MxS32 p_b) { return p_a <= p_b ? p_b : p_a; };
|
||||
|
||||
|
||||
@ -80,7 +80,9 @@ void MxSmkPresenter::LoadFrame(MxStreamChunk* p_chunk)
|
||||
MxRect32* rect;
|
||||
|
||||
while (cursor.Next(rect)) {
|
||||
invalidateRect = *rect;
|
||||
// This should probably be using the assignment operator,
|
||||
// but it's currently reducing the match significantly.
|
||||
invalidateRect.CopyFrom(*rect);
|
||||
invalidateRect.AddPoint(m_location);
|
||||
MVideoManager()->InvalidateRect(invalidateRect);
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user