gnash-commit
[Top][All Lists]
Advanced

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

[Gnash-commit] [SCM] Gnash branch, master, updated. release_0_8_9_final-


From: Gabriele Giacone
Subject: [Gnash-commit] [SCM] Gnash branch, master, updated. release_0_8_9_final-1965-g254b0be
Date: Tue, 29 Apr 2014 00:28:01 +0000

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Gnash".

The branch, master has been updated
       via  254b0bea74d38f06c3caad765fb419181204a4a6 (commit)
      from  0eda8017de798ccb156d2bc5d78fc5d862f15a76 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://git.savannah.gnu.org/cgit//commit/?id=254b0bea74d38f06c3caad765fb419181204a4a6


commit 254b0bea74d38f06c3caad765fb419181204a4a6
Author: Gabriele Giacone <address@hidden>
Date:   Tue Apr 29 02:26:18 2014 +0200

    Fix tests with --enable-sound=none.

diff --git a/libcore/movie_root.cpp b/libcore/movie_root.cpp
index 553d22a..32a6073 100644
--- a/libcore/movie_root.cpp
+++ b/libcore/movie_root.cpp
@@ -857,9 +857,9 @@ movie_root::advance()
 
     bool advanced = false;
 
-#ifdef USE_SOUND
     try {
         
+#ifdef USE_SOUND
         sound::sound_handler* s = _runResources.soundHandler();
 
         if (s && _timelineSound) {
@@ -928,6 +928,7 @@ movie_root::advance()
             }
         }
         else {
+#endif  // USE_SOUND
             // Driven by frame rate
             const size_t elapsed = now - _lastMovieAdvancement;
             if (elapsed >= _movieAdvancementDelay) {
@@ -935,7 +936,9 @@ movie_root::advance()
                 advanceMovie();
                 _lastMovieAdvancement = now;
             }
+#ifdef USE_SOUND
         }
+#endif  // USE_SOUND
         
         // Always do this.
         executeAdvanceCallbacks();
@@ -952,7 +955,6 @@ movie_root::advance()
         log_error(_("Buffer overread during advance: %s"), e.what());
         clear(_actionQueue);
     }
-#endif  // USE_SOUND
     
     return advanced;
 }
diff --git a/testsuite/MovieTester.cpp b/testsuite/MovieTester.cpp
index 5066983..67ae51c 100644
--- a/testsuite/MovieTester.cpp
+++ b/testsuite/MovieTester.cpp
@@ -634,7 +634,7 @@ MovieTester::initTestingSoundHandlers()
 void
 MovieTester::initTestingMediaHandlers()
 {
-#ifdef USE_SOUND
+#ifdef USE_MEDIA
     // TODO: allow selection.
     _mediaHandler.reset(media::MediaFactory::instance().get(""));
 #endif
diff --git a/testsuite/actionscript.all/Makefile.am 
b/testsuite/actionscript.all/Makefile.am
index 94ef849..f5a552e 100644
--- a/testsuite/actionscript.all/Makefile.am
+++ b/testsuite/actionscript.all/Makefile.am
@@ -110,7 +110,6 @@ ASTESTS =                   \
        Random.as               \
        Selection.as            \
        SharedObject.as         \
-       Sound.as                \
        Stage.as                \
        String.as               \
        System.as               \
@@ -139,6 +138,10 @@ ASTESTS =                  \
        argstest.as             \
        $(NULL)
 
+if BUILD_LIBSOUND
+ASTESTS += Sound.as
+endif
+
 if HAVE_PERL
 if ENABLE_HAXE
 HAXETESTS = \
diff --git a/testsuite/misc-haxe.all/classes.all/media/media.am 
b/testsuite/misc-haxe.all/classes.all/media/media.am
index 322f86e..9e5558c 100644
--- a/testsuite/misc-haxe.all/classes.all/media/media.am
+++ b/testsuite/misc-haxe.all/classes.all/media/media.am
@@ -37,7 +37,9 @@ MEDIA_TESTS_V9 += media/SoundMixer_as.swf
 
 MEDIA_TESTS_V9 += media/SoundTransform_as.swf
 
+if BUILD_LIBSOUND
 MEDIA_TESTS_V6 += media/Sound_as.swf
+endif
 
 MEDIA_TESTS_V6 += media/Video_as.swf
 
@@ -51,5 +53,8 @@ EXTRA_DIST += media/Camera_as.hx \
        media/SoundLoaderContext_as.hx \
        media/SoundMixer_as.hx \
        media/SoundTransform_as.hx \
-       media/Sound_as.hx \
        media/Video_as.hx
+
+if BUILD_LIBSOUND
+EXTRA_DIST += media/Sound_as.hx
+endif
diff --git a/testsuite/misc-ming.all/Makefile.am 
b/testsuite/misc-ming.all/Makefile.am
index e9db815..6f1fcca 100644
--- a/testsuite/misc-ming.all/Makefile.am
+++ b/testsuite/misc-ming.all/Makefile.am
@@ -32,7 +32,11 @@ CLEANFILES =  \
 DISTCLEANFILES = XMLSocketTester
 
 SUBDIRS = . loop loading displaylist_depths action_order register_class \
-          init_action sound
+          init_action
+
+if BUILD_LIBSOUND
+SUBDIRS += sound
+endif
 
 EXTRA_DIST = \
        DragDropTest.as \
diff --git a/testsuite/misc-swfc.all/Makefile.am 
b/testsuite/misc-swfc.all/Makefile.am
index ba3a0c3..c0e74e5 100644
--- a/testsuite/misc-swfc.all/Makefile.am
+++ b/testsuite/misc-swfc.all/Makefile.am
@@ -22,7 +22,6 @@ AUTOMAKE_OPTIONS = dejagnu
 # These will get executed and parsed for test output
 SANE_SCTESTS = \
        hello.sc \
-       sound.sc \
        soft_reference_test1.sc \
        movieclip_destruction_test1.sc \
        movieclip_destruction_test2.sc \
@@ -42,6 +41,10 @@ SANE_SCTESTS = \
        stackscope.sc \
        $(NULL)
 
+if BUILD_LIBSOUND
+SANE_SCTESTS += sound.sc
+endif
+
 # These ones are the ones for which consistency check fail 
 BOGO_SCTESTS = \
        $(NULL)
@@ -50,9 +53,12 @@ BOGO_SCTESTS = \
 INTERACTIVE_SCTESTS = \
        button_test1.sc \
        button_test2.sc  \
-       sound_stop.sc  \
        $(NULL)
 
+if BUILD_LIBSOUND
+INTERACTIVE_SCTESTS += sound_stop.sc
+endif
+
 AM_CPPFLAGS = -I.. \
         -I$(top_srcdir)                \
         -I$(top_srcdir)/libbase \
@@ -81,10 +87,11 @@ AUXMOVIES = \
 
 EXTRA_DIST = $(SANE_SCTESTS) $(BOGO_SCTESTS) $(AUXMOVIES) 
$(INTERACTIVE_SCTESTS) check.sc Dejagnu.sc hello.sc
 
-check_PROGRAMS = \
-       button_test1runner \
-       sound_stop_runner \
-       $(NULL)
+check_PROGRAMS = button_test1runner
+
+if BUILD_LIBSOUND
+check_PROGRAMS += sound_stop_runner
+endif
 
 abs_mediadir = $(abs_top_srcdir)/testsuite/media 
 
diff --git a/testsuite/movies.all/tic_tac2-TestRunner.cpp 
b/testsuite/movies.all/tic_tac2-TestRunner.cpp
index 4204841..7013d81 100644
--- a/testsuite/movies.all/tic_tac2-TestRunner.cpp
+++ b/testsuite/movies.all/tic_tac2-TestRunner.cpp
@@ -42,69 +42,71 @@ TRYMAIN(_runtest);
 int
 trymain(int /*argc*/, char** /*argv*/)
 {
-       string filename = string(SRCDIR) + string("/") + string(INPUT_FILENAME);
-       MovieTester tester(filename);
+    string filename = string(SRCDIR) + string("/") + string(INPUT_FILENAME);
+    MovieTester tester(filename);
 
-       gnash::LogFile& dbglogfile = gnash::LogFile::getDefaultInstance();
-       dbglogfile.setVerbosity(1);
+    gnash::LogFile& dbglogfile = gnash::LogFile::getDefaultInstance();
+    dbglogfile.setVerbosity(1);
 
-       const MovieClip* root = tester.getRootMovie();
-       assert(root);
+    const MovieClip* root = tester.getRootMovie();
+    assert(root);
 
-       check_equals(root->get_frame_count(), 10);
-       check_equals(root->get_current_frame(), 0);
+    check_equals(root->get_frame_count(), 10);
+    check_equals(root->get_current_frame(), 0);
 
-       const MovieClip* slides = dynamic_cast<const MovieClip*>(
-               tester.findDisplayItemByTarget("_level0.slides"));
-       check(slides);
+    const MovieClip* slides = dynamic_cast<const MovieClip*>(
+        tester.findDisplayItemByTarget("_level0.slides"));
+    check(slides);
 
-       const Button* button = dynamic_cast<const Button*>(
-               tester.findDisplayItemByTarget("_level0.b1"));
-       check(button);
+    const Button* button = dynamic_cast<const Button*>(
+        tester.findDisplayItemByTarget("_level0.b1"));
+    check(button);
 
-       tester.advance(); 
-       check_equals(root->get_current_frame(), 1);
-       check_equals(slides->get_current_frame(), 0);
+    tester.advance();
+    check_equals(root->get_current_frame(), 1);
+    check_equals(slides->get_current_frame(), 0);
 
-       // Not much happens w/out clicking on the play button
-       for (int i=0; i<10; ++i) tester.advance(); 
-       check_equals(root->get_current_frame(), 1);
-       check_equals(slides->get_current_frame(), 0);
+    // Not much happens w/out clicking on the play button
+    for (int i=0; i<10; ++i) tester.advance();
+    check_equals(root->get_current_frame(), 1);
+    check_equals(slides->get_current_frame(), 0);
 
-       // Should start now
-       tester.movePointerTo(395, 301); tester.click();
-       check_equals(root->get_current_frame(), 1);
-       check_equals(slides->get_current_frame(), 0);
+    // Should start now
+    tester.movePointerTo(395, 301); tester.click();
+    check_equals(root->get_current_frame(), 1);
+    check_equals(slides->get_current_frame(), 0);
 
-       for (unsigned int i=0; i<3; ++i) {
-               std::stringstream s; s << "iteration " << i;
-               tester.advance(); 
-               check_equals_label(s.str(), root->get_current_frame(), 2+i);
-               check_equals_label(s.str(), slides->get_current_frame(), 0);
-       }
+    for (unsigned int i=0; i<3; ++i) {
+        std::stringstream s; s << "iteration " << i;
+        tester.advance();
+        check_equals_label(s.str(), root->get_current_frame(), 2+i);
+        check_equals_label(s.str(), slides->get_current_frame(), 0);
+    }
 
+#if USE_SOUND
     // Tweak initial offset (dunno based on what really)
     tester.advanceClock(1000);
-    tester.advance(false); 
-       check_equals(root->get_current_frame(), 4);
-       check_equals(slides->get_current_frame(), 0);
+    tester.advance(false);
+    check_equals(root->get_current_frame(), 4);
+    check_equals(slides->get_current_frame(), 0);
 
-       for (unsigned int i=0; i<12; ++i) {
+    for (unsigned int i=0; i<12; ++i) {
         tester.advanceClock(1000);
-        tester.advance(false); 
-               std::stringstream s; s << "i" << i;
-           check_equals_label(s.str(), slides->get_current_frame(), i);
+        tester.advance(false);
+        std::stringstream s; s << "i" << i;
+        check_equals_label(s.str(), slides->get_current_frame(), i);
         // TODO: check invalidated bounds!
     }
 
-       check_equals(slides->get_current_frame(), 11);
-       check_equals(root->get_current_frame(), 4);
+    check_equals(slides->get_current_frame(), 11);
+    check_equals(root->get_current_frame(), 4);
 
     // It's stuck there
-       for (int i=0; i<10; ++i) tester.advance(); 
-       check_equals(slides->get_current_frame(), 11);
-       check_equals(root->get_current_frame(), 4);
+    for (int i=0; i<10; ++i) tester.advance();
+    check_equals(slides->get_current_frame(), 11);
+    check_equals(root->get_current_frame(), 4);
+#endif // USE_SOUND
 
-       return 0;
+    return 0;
 }
 

-----------------------------------------------------------------------

Summary of changes:
 libcore/movie_root.cpp                             |    6 +-
 testsuite/MovieTester.cpp                          |    2 +-
 testsuite/actionscript.all/Makefile.am             |    5 +-
 testsuite/misc-haxe.all/classes.all/media/media.am |    7 ++-
 testsuite/misc-ming.all/Makefile.am                |    6 +-
 testsuite/misc-swfc.all/Makefile.am                |   19 +++--
 testsuite/movies.all/tic_tac2-TestRunner.cpp       |   90 ++++++++++----------
 7 files changed, 79 insertions(+), 56 deletions(-)


hooks/post-receive
-- 
Gnash



reply via email to

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