[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] gnash gui/gui.cpp ChangeLog
From: |
Sandro Santilli |
Subject: |
[Gnash-commit] gnash gui/gui.cpp ChangeLog |
Date: |
Wed, 18 Oct 2006 15:20:18 +0000 |
CVSROOT: /sources/gnash
Module name: gnash
Changes by: Sandro Santilli <strk> 06/10/18 15:20:18
Modified files:
gui : gui.cpp
. : ChangeLog
Log message:
* gui/gui.cpp: let initial _last_invalidated_rect be null;
don't directly access rect private members.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/gui/gui.cpp?cvsroot=gnash&r1=1.32&r2=1.33
http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.1301&r2=1.1302
Patches:
Index: gui/gui.cpp
===================================================================
RCS file: /sources/gnash/gnash/gui/gui.cpp,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -b -r1.32 -r1.33
--- gui/gui.cpp 17 Oct 2006 15:30:04 -0000 1.32
+++ gui/gui.cpp 18 Oct 2006 15:20:17 -0000 1.33
@@ -75,10 +75,6 @@
_depth(16)
{
// GNASH_REPORT_FUNCTION;
- _last_invalidated_bounds.m_x_min = 0.0f;
- _last_invalidated_bounds.m_y_min = 0.0f;
- _last_invalidated_bounds.m_x_max = 0.0f;
- _last_invalidated_bounds.m_y_max = 0.0f;
}
Gui::Gui(unsigned long xid, float scale, bool loop, unsigned int depth) :
@@ -90,10 +86,6 @@
_yscale(scale),
_depth(depth)
{
- _last_invalidated_bounds.m_x_min = 0.0f;
- _last_invalidated_bounds.m_y_min = 0.0f;
- _last_invalidated_bounds.m_x_max = 0.0f;
- _last_invalidated_bounds.m_y_max = 0.0f;
}
Gui::~Gui()
@@ -242,33 +234,21 @@
if (redraw_flag)
{
- draw_bounds.m_x_min = -1e10f;
- draw_bounds.m_y_min = -1e10f;
- draw_bounds.m_x_max = +1e10f;
- draw_bounds.m_y_max = +1e10f;
+ // TODO: use more meaningful ordinate values ?
+ draw_bounds = rect(-1e10f, -1e10f, +1e10f, +1e10f);
}
else
{
-
// Union it with the previous frame (when a character moved,
// we also need to redraw it's previous position).
draw_bounds = changed_bounds;
- // TODO: the following condition seems bogus to me...
- // what about always calling expand_to_rect
- // and let rect class take care of any check ?
- if (_last_invalidated_bounds.m_x_min <=
_last_invalidated_bounds.m_x_max)
- {
draw_bounds.expand_to_rect(_last_invalidated_bounds);
- }
}
// Avoid drawing of stopped movies
- // TODO: the following condition seems a bit undeadable to me,
- // do we mean to catch an *empty* rect ? what about
- // adding a is_empty() method to rect class then ?
- if (draw_bounds.m_x_min <= draw_bounds.m_x_max)
+ if ( ! draw_bounds.is_null() )
{
// Tell the GUI that we only need to update this region
Index: ChangeLog
===================================================================
RCS file: /sources/gnash/gnash/ChangeLog,v
retrieving revision 1.1301
retrieving revision 1.1302
diff -u -b -r1.1301 -r1.1302
--- ChangeLog 18 Oct 2006 14:54:58 -0000 1.1301
+++ ChangeLog 18 Oct 2006 15:20:18 -0000 1.1302
@@ -1,5 +1,7 @@
2006-10-18 Sandro Santilli <address@hidden>
+ * gui/gui.cpp: let initial _last_invalidated_rect be null;
+ don't directly access rect private members.
* server/rect.h: added constructor taking all coordinates.
* backend/render_handler_ogl.cpp: don't directly access rect
"to-be" private members.