gnash-commit
[Top][All Lists]
Advanced

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

[Gnash-commit] gnash ./ChangeLog backend/Makefile.am backend/g...


From: Rob Savoye
Subject: [Gnash-commit] gnash ./ChangeLog backend/Makefile.am backend/g...
Date: Tue, 04 Apr 2006 20:42:56 +0000

CVSROOT:        /sources/gnash
Module name:    gnash
Branch:         
Changes by:     Rob Savoye <address@hidden>     06/04/04 20:42:56

Modified files:
        .              : ChangeLog 
        backend        : Makefile.am gnash.cpp 
        libbase        : image_filters.cpp 
        macros         : gstreamer.m4 opengl.m4 
        plugin         : plugin.cpp 
        plugin/mozilla-sdk: pluginbase.h 
        testsuite/actionscript.all: Makefile.am 

Log message:
        * backend/gnash.cpp: Add -j and -k options to set the width and
        height of the window. This is used only by the plugin. Uncomment
        gtk_plug() code, it works now! If the window ID is set, don't set
        the window size again.
        * plugin/plugin.cpp: Always return the value when Mozilla
        asks. Add -j and -k options to set the window size for the player
        instead of letting it default to the movie size.
        * libbase/image_filters.cpp: Add struct name to eliminate
        warning.
        * macros/gstreamer.m4: Change where the -I and -L gets added.
        * macros/opengl.m4: Change where the -I and -L gets added.
        * plugin/mozilla-sdk/pluginbase.h: Add a destructor to eliminate
        warnings.
        * testsuite/actionscript.all/Makefile.am: Add the test case source
        files to the distribution tarball. Include the generated swf
        movies so people don't need Ming installed to have "make check"
        work.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/ChangeLog.diff?tr1=1.198&tr2=1.199&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/backend/Makefile.am.diff?tr1=1.18&tr2=1.19&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/backend/gnash.cpp.diff?tr1=1.20&tr2=1.21&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/libbase/image_filters.cpp.diff?tr1=1.5&tr2=1.6&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/macros/gstreamer.m4.diff?tr1=1.2&tr2=1.3&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/macros/opengl.m4.diff?tr1=1.14&tr2=1.15&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/plugin/plugin.cpp.diff?tr1=1.22&tr2=1.23&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/plugin/mozilla-sdk/pluginbase.h.diff?tr1=1.3&tr2=1.4&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/gnash/gnash/testsuite/actionscript.all/Makefile.am.diff?tr1=1.18&tr2=1.19&r1=text&r2=text

Patches:
Index: gnash/ChangeLog
diff -u gnash/ChangeLog:1.198 gnash/ChangeLog:1.199
--- gnash/ChangeLog:1.198       Mon Apr  3 04:26:06 2006
+++ gnash/ChangeLog     Tue Apr  4 20:42:55 2006
@@ -1,3 +1,23 @@
+2006-04-04  Rob Savoye  <address@hidden>
+
+       * backend/gnash.cpp: Add -j and -k options to set the width and
+       height of the window. This is used only by the plugin. Uncomment
+       gtk_plug() code, it works now! If the window ID is set, don't set
+       the window size again.
+       * plugin/plugin.cpp: Always return the value when Mozilla
+       asks. Add -j and -k options to set the window size for the player
+       instead of letting it default to the movie size.
+       * libbase/image_filters.cpp: Add struct name to eliminate
+       warning.
+       * macros/gstreamer.m4: Change where the -I and -L gets added.
+       * macros/opengl.m4: Change where the -I and -L gets added.
+       * plugin/mozilla-sdk/pluginbase.h: Add a destructor to eliminate
+       warnings.
+       * testsuite/actionscript.all/Makefile.am: Add the test case source
+       files to the distribution tarball. Include the generated swf
+       movies so people don't need Ming installed to have "make check"
+       work.
+
 2006-04-02  Rob Savoye  <address@hidden>
 
        * gnash/Makefile.am: Move libamf to DIST_SUBDIRS, since it's not
@@ -357,13 +377,13 @@
        both cases to return a meaningful result. We always build the
        plugin now, so having firefox-config isn't a failure anymore.
        * libbase/dlmalloc.h: Move USE_DL_MALLOC ifdef up a few lines. 
-       * macros/firefox.m4: Add new macro to repklace the old one, which
+       * macros/firefox.m4: Add new macro to replace the old one, which
        is renamed. Turns out none of the flags from mozill-config are
        needed, so only find the path to install the plugin.
        * macros/kde.m4: Turn more errors into notices so the build
        doesn't stop if KDE parts aren't installed. We only want to use
        them if building klash. Optionally skip some tests if klash isn';t
-       installed. Otherwise they get set if they;re installed even if
+       installed. Otherwise they get set if they're installed even if
        you aren't building klash.
        * plugin/Makefile.am: Don't use the DEFS from firefox-config,
        only MOZ_X11 is needed by the SDK. Add include path to our own
Index: gnash/backend/Makefile.am
diff -u gnash/backend/Makefile.am:1.18 gnash/backend/Makefile.am:1.19
--- gnash/backend/Makefile.am:1.18      Thu Mar 30 01:52:00 2006
+++ gnash/backend/Makefile.am   Tue Apr  4 20:42:56 2006
@@ -81,7 +81,9 @@
        gtksup.cpp gtksup.h
 
 gnash_SOURCES = gnash.cpp
-gnash_LDFLAGS = -module -avoid-version -no-undefined
+gnash_LDFLAGS = -module -avoid-version -no-undefined #-Wl,-z,defs
+
+
 gnash_LDADD =  $(AM_LDFLAGS) \
        ../backend/libgnashbackend.la \
        ../server/libgnashserver.la \
Index: gnash/backend/gnash.cpp
diff -u gnash/backend/gnash.cpp:1.20 gnash/backend/gnash.cpp:1.21
--- gnash/backend/gnash.cpp:1.20        Fri Mar 31 00:57:33 2006
+++ gnash/backend/gnash.cpp     Tue Apr  4 20:42:56 2006
@@ -239,6 +239,8 @@
     bool sdl_abort = true;
     int  delay = 31;
     float      tex_lod_bias;
+    int        width = 0;
+    int        height = 0;
 #ifndef HAVE_GTK2
     int windowid = 0;
 #else
@@ -263,7 +265,7 @@
     dbglogfile.setWriteDisk(false);
 //    dbglogfile.removeLog();
     
-    while ((c = getopt (argc, argv, "hvaps:cfd:m:x:r:t:b:1ew")) != -1) {
+    while ((c = getopt (argc, argv, "hvaps:cfd:m:x:r:t:b:1ewj:k:")) != -1) {
        switch (c) {
          case 'h':
              usage (argv[0]);
@@ -295,6 +297,14 @@
           case 'd':
               delay = strtol(optarg, NULL, 0);
               break;
+          case 'j':
+              width = strtol(optarg, NULL, 0);
+              dbglogfile << "Setting width to: " << width << endl;
+              break;
+          case 'k':
+              height = strtol(optarg, NULL, 0);
+              dbglogfile << "Setting height to: " << height << endl;
+              break;
           case 'e':
               s_event_thread = true;
               break;
@@ -308,7 +318,7 @@
               do_loop = false;
               break;
           case 'r':
-              render_arg = atoi(optarg);
+              render_arg = strtol(optarg, NULL, 0);
               switch (render_arg) {
                 case 0:
                     // Disable both
@@ -386,9 +396,13 @@
         fprintf(stderr, "error: can't get info about %s\n", infiles[0]);
         exit(1);
     }
-    
-    int        width = int(movie_width * s_scale);
-    int        height = int(movie_height * s_scale);
+
+    if (!width) {    
+        width = int(movie_width * s_scale);
+    }
+    if (!height) {
+        height = int(movie_height * s_scale);
+    }
     
     if (do_render) {
 #ifndef HAVE_GTK2
@@ -453,13 +467,13 @@
             SDL_GL_SetAttribute(SDL_GL_STENCIL_SIZE, 1);
         }
 #else
-//         if (windowid) {
-//             window = gtk_plug_new(windowid);
-//             dbglogfile << "Created GTK Plug window" << endl;
-//         } else {
+        if (windowid) {
+            window = gtk_plug_new(windowid);
+            dbglogfile << "Created GTK Plug window" << endl;
+        } else {
             window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
             dbglogfile << "Created top level window" << endl;
-//        }
+        }
 //         if (!glconfig) {
 //             static const int attrib_list[] = {
 //                 // GDK_GL_ALPHA_SIZE, 1,
@@ -482,7 +496,9 @@
         GtkMenu *popup_menu = GTK_MENU(gtk_menu_new());
         
         drawing_area = gtk_drawing_area_new();
-        gtk_widget_set_size_request(drawing_area, width, height);
+        if (!windowid) {
+            gtk_widget_set_size_request(drawing_area, width, height);
+        }
         // Set OpenGL-capability to the widget.
         gtk_widget_set_gl_capability(drawing_area, glconfig,
                                       NULL, TRUE, GDK_GL_RGBA_TYPE);
Index: gnash/libbase/image_filters.cpp
diff -u gnash/libbase/image_filters.cpp:1.5 gnash/libbase/image_filters.cpp:1.6
--- gnash/libbase/image_filters.cpp:1.5 Wed Mar 29 05:42:41 2006
+++ gnash/libbase/image_filters.cpp     Tue Apr  4 20:42:56 2006
@@ -347,7 +347,7 @@
     FILTER_COUNT
     };
 
-struct {
+struct filter_table {
     float      (*filter_function)(float);
     float      support;
 } filter_table[] =
Index: gnash/macros/gstreamer.m4
diff -u gnash/macros/gstreamer.m4:1.2 gnash/macros/gstreamer.m4:1.3
--- gnash/macros/gstreamer.m4:1.2       Wed Mar 29 05:42:41 2006
+++ gnash/macros/gstreamer.m4   Tue Apr  4 20:42:56 2006
@@ -128,15 +128,15 @@
           for i in $libslist; do
            if test -f $i/libgstreamer-${version}.a -o -f 
$i/libgstreamer-${version}.so; then
              if test x"$i" != x"/usr/lib"; then
-               ac_cv_path_gstreamer_lib="$i"
+               ac_cv_path_gstreamer_lib="-L$i -lgstreamer"
                break
               else
-               ac_cv_path_gstreamer_lib=""
+               ac_cv_path_gstreamer_lib="-lgstreamer"
                break
              fi
            else
              if test -f $i/libgstreamer-${version}.a -o -f 
$i/libgstreamer-${version}.so; then
-               ac_cv_path_gstreamer_lib="$i/${topdir}"
+               ac_cv_path_gstreamer_lib="-L$i/${topdir} -lgstreamer-${version}"
                break
              fi
            fi
@@ -144,9 +144,9 @@
       else
        if test -f $i/libgstreamer-${version}.a -o -f 
$i/libgstreamer-${version}.so; then
           if test x"${ac_cv_path_gstreamer_lib}" != x"/usr/lib"; then
-           ac_cv_path_gstreamer_lib="${ac_cv_path_gstreamer_lib}"
+           ac_cv_path_gstreamer_lib="-L${ac_cv_path_gstreamer_lib} 
-lgstreamer-${version}"
            else
-           ac_cv_path_gstreamer_lib=""
+           ac_cv_path_gstreamer_lib="-lgstreamer-${version}"
           fi
         fi
       fi
@@ -158,10 +158,10 @@
   fi
 
   if test x"${ac_cv_path_gstreamer_lib}" != x ; then
-    GSTREAMER_LIBS="-L${ac_cv_path_gstreamer_lib} -lgstreamer-${version}"
+    GSTREAMER_LIBS="${ac_cv_path_gstreamer_lib}"
     AC_MSG_WARN([You need GStreamer 0.10 or greater for sound support!])
   else
-    GSTREAMER_LIBS="-lgstreamer-${version}"
+    GSTREAMER_LIBS=""
   fi
 
   AC_SUBST(GSTREAMER_CFLAGS)
Index: gnash/macros/opengl.m4
diff -u gnash/macros/opengl.m4:1.14 gnash/macros/opengl.m4:1.15
--- gnash/macros/opengl.m4:1.14 Wed Mar 29 05:42:41 2006
+++ gnash/macros/opengl.m4      Tue Apr  4 20:42:56 2006
@@ -116,14 +116,12 @@
           if test -f $i/libGL.a -o -f $i/libGL.so; then
             if test x"$i" != x"/usr/lib"; then
               ac_cv_path_opengl_lib="-L$i -lGL -lGLU"
-#              AC_MSG_RESULT(${ac_cv_path_opengl_lib})
               break
             else
             if test -f $i/libopengl32.a; then
               ac_cv_path_opengl_lib="-L$i -lopengl32 -lglu32"
               break
             fi
-#              AC_MSG_RESULT(yes)
               break
             fi
           fi
@@ -131,9 +129,9 @@
     else
       if test -f ${ac_cv_path_opengl_lib}/libGL.a -o -f 
${ac_cv_path_opengl_lib}/libGL.so; then
         if test x"${ac_cv_path_opengl_lib}" != x"/usr/lib"; then
-          ac_cv_path_opengl_lib="${ac_cv_path_opengl_lib}"
+          ac_cv_path_opengl_lib="-L${ac_cv_path_opengl_lib} -lGL -lGLU"
          else
-          ac_cv_path_opengl_lib=""
+          ac_cv_path_opengl_lib="-lGL -lGLU"
         fi
       fi
     fi
Index: gnash/plugin/mozilla-sdk/pluginbase.h
diff -u gnash/plugin/mozilla-sdk/pluginbase.h:1.3 
gnash/plugin/mozilla-sdk/pluginbase.h:1.4
--- gnash/plugin/mozilla-sdk/pluginbase.h:1.3   Thu Jan 19 23:50:11 2006
+++ gnash/plugin/mozilla-sdk/pluginbase.h       Tue Apr  4 20:42:56 2006
@@ -33,7 +33,9 @@
 
 class nsPluginInstanceBase
 {
-public:
+ public:
+  virtual ~nsPluginInstanceBase() { return; }
+ 
   // these three methods must be implemented in the derived
   // class platform specific way
   virtual NPBool init(NPWindow* aWindow) = 0;
Index: gnash/plugin/plugin.cpp
diff -u gnash/plugin/plugin.cpp:1.22 gnash/plugin/plugin.cpp:1.23
--- gnash/plugin/plugin.cpp:1.22        Fri Mar 31 00:57:33 2006
+++ gnash/plugin/plugin.cpp     Tue Apr  4 20:42:56 2006
@@ -600,18 +600,7 @@
 {
     log_trace("%s: enter for instance %p", __PRETTY_FUNCTION__, this);    
     
-    NPError err = NPERR_NO_ERROR;
-    switch (aVariable) {
-      case NPPVpluginNameString:
-      case NPPVpluginDescriptionString:
-          return NS_PluginGetValue(aVariable, aValue) ;
-          break;
-      default:
-          err = NPERR_INVALID_PARAM;
-          break;
-    }
-    return err;
-
+    return NS_PluginGetValue(aVariable, aValue) ;
 }
 
 /// \brief Write a status message
@@ -1043,7 +1032,13 @@
     // setup the command line
     char num[30];
     memset(num, 0, 30);
-    sprintf(num, "%d", (int)win);
+    sprintf(num, "%ld", win);
+    char num2[30];
+    memset(num2, 0, 30);
+    sprintf(num2, "%d", mWidth);
+    char num3[30];
+    memset(num3, 0, 30);
+    sprintf(num3, "%d", mHeight);
     
 //     cmd_line[0] = new char(procname.size()+1);
 //     strcpy(cmd_line[0], procname.c_str());
@@ -1064,6 +1059,8 @@
        (char *)_procname.c_str(),
        "-x", num,
        (char *)filespec.c_str(),
+       "-j", num2,
+       "-k", num3,
        0
     };
     
Index: gnash/testsuite/actionscript.all/Makefile.am
diff -u gnash/testsuite/actionscript.all/Makefile.am:1.18 
gnash/testsuite/actionscript.all/Makefile.am:1.19
--- gnash/testsuite/actionscript.all/Makefile.am:1.18   Tue Apr  4 16:57:29 2006
+++ gnash/testsuite/actionscript.all/Makefile.am        Tue Apr  4 20:42:56 2006
@@ -78,11 +78,17 @@
        XML.swf                 \
        Function.swf            
 
-EXTRA_DIST = $(GENERATED:.swf=.as)
+EXTRA_DIST = $(GENERATED:.swf=.as) $(GENERATED)
 
-all: $(GENERATED)
+if ENABLE_MING
+TARGET = $(GENERATED)
+else
+TARGET = 
+endif
 
-swf: $(GENERATED)
+all: $(TARGET)
+
+swf: $(TARGET)
 
 index-html: 
        sh ./gen-index.sh $(GENERATED)




reply via email to

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