diff base/PlayParameterRepository.cpp @ 83:b2067aff8cd6

* Fix crash in spectrogram layer when replacing model * Change sample player's sample path to a single sample directory. This makes it immune to OS path separator differences, and ensures it can reject configure calls that try to set a nonexistent directory. Reloading play parameters (e.g. sample program) should now work. * some win32 fixes.
author Chris Cannam
date Wed, 26 Apr 2006 16:00:13 +0000
parents bf42d8d63885
children c30728d5625c
line wrap: on
line diff
--- a/base/PlayParameterRepository.cpp	Wed Apr 26 14:09:55 2006 +0000
+++ b/base/PlayParameterRepository.cpp	Wed Apr 26 16:00:13 2006 +0000
@@ -50,23 +50,27 @@
 
 	    std::cerr << "PlayParameterRepository: Adding play parameters for " << model << std::endl;
 
-	    m_playParameters[model] = new PlayParameters;
+            PlayParameters *params = new PlayParameters;
+	    m_playParameters[model] = params;
 
-            m_playParameters[model]->setPlayPluginId
+            params->setPlayPluginId
                 (AudioGenerator::getDefaultPlayPluginId(model));
 
-            m_playParameters[model]->setPlayPluginConfiguration
+            params->setPlayPluginConfiguration
                 (AudioGenerator::getDefaultPlayPluginConfiguration(model));
 
-	    connect(m_playParameters[model], SIGNAL(playParametersChanged()),
+	    connect(params, SIGNAL(playParametersChanged()),
 		    this, SLOT(playParametersChanged()));
 
-	    connect(m_playParameters[model], SIGNAL(playPluginIdChanged(QString)),
+	    connect(params, SIGNAL(playPluginIdChanged(QString)),
 		    this, SLOT(playPluginIdChanged(QString)));
 
-	    connect(m_playParameters[model], SIGNAL(playPluginConfigurationChanged(QString)),
+	    connect(params, SIGNAL(playPluginConfigurationChanged(QString)),
 		    this, SLOT(playPluginConfigurationChanged(QString)));
 
+            std::cerr << "Connected play parameters " << params << " for model "
+                      << model << " to this " << this << std::endl;
+
 	} else {
 
 	    std::cerr << "PlayParameterRepository: Model " << model << " not playable" <<  std::endl;