gnash-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnash-commit] gnash ChangeLog gui/Player.cpp server/parser/sh...


From: Sandro Santilli
Subject: [Gnash-commit] gnash ChangeLog gui/Player.cpp server/parser/sh...
Date: Tue, 22 May 2007 19:38:55 +0000

CVSROOT:        /sources/gnash
Module name:    gnash
Changes by:     Sandro Santilli <strk>  07/05/22 19:38:54

Modified files:
        .              : ChangeLog 
        gui            : Player.cpp 
        server/parser  : shape_character_def.cpp 

Log message:
                * gui/Player.cpp (run): use movie url for window title (-u).
                  Useful when reading stdin...
                * server/parser/shape_character_def.cpp (read): don't force
                  fill and line style of glyphs to have a corresponding style
                  definition, just warn if the value in a styleChangeRecord is
                  neither 0 or 1. Set style to 0 when invalid.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.3309&r2=1.3310
http://cvs.savannah.gnu.org/viewcvs/gnash/gui/Player.cpp?cvsroot=gnash&r1=1.50&r2=1.51
http://cvs.savannah.gnu.org/viewcvs/gnash/server/parser/shape_character_def.cpp?cvsroot=gnash&r1=1.25&r2=1.26

Patches:
Index: ChangeLog
===================================================================
RCS file: /sources/gnash/gnash/ChangeLog,v
retrieving revision 1.3309
retrieving revision 1.3310
diff -u -b -r1.3309 -r1.3310
--- ChangeLog   22 May 2007 19:05:20 -0000      1.3309
+++ ChangeLog   22 May 2007 19:38:54 -0000      1.3310
@@ -1,5 +1,14 @@
 2007-05-22 Sandro Santilli <address@hidden>
 
+       * gui/Player.cpp (run): use movie url for window title (-u).
+         Useful when reading stdin...
+       * server/parser/shape_character_def.cpp (read): don't force
+         fill and line style of glyphs to have a corresponding style
+         definition, just warn if the value in a styleChangeRecord is
+         neither 0 or 1. Set style to 0 when invalid.
+
+2007-05-22 Sandro Santilli <address@hidden>
+
        * testsuite/misc-ming.all/loop_test-Runner.cpp: don't expect
          failure in invalidated bounds after Udo commits.
        * testsuite/misc-ming.all/replace_sprites1test.c: Change expected

Index: gui/Player.cpp
===================================================================
RCS file: /sources/gnash/gnash/gui/Player.cpp,v
retrieving revision 1.50
retrieving revision 1.51
diff -u -b -r1.50 -r1.51
--- gui/Player.cpp      14 May 2007 16:56:10 -0000      1.50
+++ gui/Player.cpp      22 May 2007 19:38:54 -0000      1.51
@@ -313,7 +313,7 @@
     }
 
     // Now that we know about movie size, create gui window.
-    _gui->createWindow(infile, width, height);
+    _gui->createWindow(_url.c_str(), width, height);
 
     movie_root& root = VM::init(*_movie_def).getRoot();
     sprite_instance* m = root.get_root_movie();

Index: server/parser/shape_character_def.cpp
===================================================================
RCS file: /sources/gnash/gnash/server/parser/shape_character_def.cpp,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -b -r1.25 -r1.26
--- server/parser/shape_character_def.cpp       14 May 2007 20:28:14 -0000      
1.25
+++ server/parser/shape_character_def.cpp       22 May 2007 19:38:54 -0000      
1.26
@@ -17,7 +17,7 @@
 // Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 //
 
-/* $Id: shape_character_def.cpp,v 1.25 2007/05/14 20:28:14 strk Exp $ */
+/* $Id: shape_character_def.cpp,v 1.26 2007/05/22 19:38:54 strk Exp $ */
 
 // Based on the public domain shape.cpp of Thatcher Ulrich <address@hidden> 
2003
 
@@ -195,7 +195,7 @@
     if ( tag_type == SWF::DEFINEFONT || tag_type == SWF::DEFINEFONT2 )
     {
            assert(!with_style);
-           m_fill_styles.push_back(fill_style());
+           //m_fill_styles.push_back(fill_style());
     }
 
 
@@ -280,22 +280,35 @@
                if (style > 0) {
                    style += fill_base;
                }
-               if ( style <= m_fill_styles.size() ) // 1-based index 
+
+               if ( tag_type == SWF::DEFINEFONT || tag_type == 
SWF::DEFINEFONT2 )
                {
-                       current_path.setLeftFill(style);
-                       IF_VERBOSE_PARSE(
-                       if (SHAPE_LOG) {
-                           log_parse(_("  shape_character read: fill0 (left) = 
%d"), current_path.getLeftFill());
+                       if ( style > 1 ) // 0:hide 1:renderer
+                       {
+                               IF_VERBOSE_MALFORMED_SWF(
+                               log_swferror(_("Invalid fill style %d in 
fillStyle0Change record for font tag (0 or 1 valid). Set to 0."), style);
+                               );
+                               style = 0;
                        }
-                       )
                }
                else
                {
+                       if ( style > m_fill_styles.size() ) // 1-based index 
+                       {
                        IF_VERBOSE_MALFORMED_SWF(
-                       log_swferror(_("Unknown fill style %d in 
fillStyle0Change record - %u defined"), style, m_fill_styles.size());
+                               log_swferror(_("Invalid fill style %d in 
fillStyle0Change record - %u defined. Set to 0."), style, m_fill_styles.size());
                        );
+                               style = 0;
+                       }
                }
 
+               current_path.setLeftFill(style);
+               IF_VERBOSE_PARSE(
+               if (SHAPE_LOG) {
+                   log_parse(_("  shape_character read: fill0 (left) = %d"), 
current_path.getLeftFill());
+               }
+               );
+
            }
            if ((flags & flagFillStyle1Change) && num_fill_bits > 0)
            {
@@ -310,21 +323,33 @@
                if (style > 0) {
                    style += fill_base;
                }
-               if ( style <= m_fill_styles.size() ) // 1-based index 
+
+               if ( tag_type == SWF::DEFINEFONT || tag_type == 
SWF::DEFINEFONT2 )
                {
-                       current_path.setRightFill(style); // getRightFill() = 
style;
-                       IF_VERBOSE_PARSE (
-                       if (SHAPE_LOG) {
-                           log_parse(_("  shape_character read: fill1 (right) 
= %d"), current_path.getRightFill());
+                       if ( style > 1 ) // 0:hide 1:renderer
+                       {
+                               IF_VERBOSE_MALFORMED_SWF(
+                               log_swferror(_("Invalid fill style %d in 
fillStyle1Change record for font tag (0 or 1 valid). Set to 0."), style);
+                               );
+                               style = 0;
                        }
-                       )
                }
                else
                {
+                       if ( style > m_fill_styles.size() ) // 1-based index 
+                       {
                        IF_VERBOSE_MALFORMED_SWF(
-                       log_swferror(_("Unknown fill style %d in 
fillStyle1Change record, %u defined "), style, m_fill_styles.size());
+                               log_swferror(_("Invalid fill style %d in 
fillStyle1Change record - %u defined. Set to 0."), style, m_fill_styles.size());
                        );
+                               style = 0;
+                       }
+               }
+               current_path.setRightFill(style); // getRightFill() = style;
+               IF_VERBOSE_PARSE (
+               if (SHAPE_LOG) {
+                   log_parse(_("  shape_character read: fill1 (right) = %d"), 
current_path.getRightFill());
                }
+               )
            }
            if ((flags & flagLineStyleChange) && num_line_bits > 0)
            {
@@ -339,22 +364,33 @@
                if (style > 0) {
                    style += line_base;
                }
-               if ( style <= m_line_styles.size() ) // 1-based index 
+               if ( tag_type == SWF::DEFINEFONT || tag_type == 
SWF::DEFINEFONT2 )
                {
-                       current_path.setLineStyle(style);
-                       IF_VERBOSE_PARSE (
-                       if (SHAPE_LOG)
+                       if ( style > 1 ) // 0:hide 1:renderer
                        {
-                           log_parse(_("  shape_character_read: line = %d"), 
current_path.getLineStyle());
+                               IF_VERBOSE_MALFORMED_SWF(
+                               log_swferror(_("Invalid line style %d in 
lineStyleChange record for font tag (0 or 1 valid). Set to 0."), style);
+                               );
+                               style = 0;
                        }
-                       )
                }
                else
                {
+                       if ( style > m_fill_styles.size() ) // 1-based index 
+                       {
                        IF_VERBOSE_MALFORMED_SWF(
-                       log_swferror(_("Unknown line style %d in 
lineStyleChange record, %u defined "), style, m_line_styles.size());
+                               log_swferror(_("Invalid fill style %d in 
lineStyleChange record - %u defined. Set to 0."), style, m_line_styles.size());
                        );
+                               style = 0;
+                       }
                }
+               current_path.setLineStyle(style);
+               IF_VERBOSE_PARSE (
+               if (SHAPE_LOG)
+               {
+                   log_parse(_("  shape_character_read: line = %d"), 
current_path.getLineStyle());
+               }
+               )
            }
            if (flags & flagHasNewStyles)
            {




reply via email to

[Prev in Thread] Current Thread [Next in Thread]