summaryrefslogtreecommitdiff
path: root/libs/ardour/panner.cc
diff options
context:
space:
mode:
authorCarl Hetherington <carl@carlh.net>2009-12-13 23:48:48 +0000
committerCarl Hetherington <carl@carlh.net>2009-12-13 23:48:48 +0000
commit383b24cc48e542d83fca90d4263f800b33d69402 (patch)
treeea4a2cd1f5ebd59a7224194eba9d5dc7be2b700f /libs/ardour/panner.cc
parent60cc81ea1a4637defa51b059da9ad2a2285ae276 (diff)
Fix crashes on increasing a bus' number of outputs.
git-svn-id: svn://localhost/ardour2/branches/3.0@6364 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/panner.cc')
-rw-r--r--libs/ardour/panner.cc22
1 files changed, 12 insertions, 10 deletions
diff --git a/libs/ardour/panner.cc b/libs/ardour/panner.cc
index 85c8e403e9..14f5a2038e 100644
--- a/libs/ardour/panner.cc
+++ b/libs/ardour/panner.cc
@@ -921,7 +921,10 @@ Panner::reset (uint32_t nouts, uint32_t npans)
if (nouts < 2) {
/* no need for panning with less than 2 outputs */
- goto send_changed;
+ if (changed) {
+ Changed (); /* EMIT SIGNAL */
+ }
+ return;
}
switch (nouts) {
@@ -999,6 +1002,14 @@ Panner::reset (uint32_t nouts, uint32_t npans)
(*x)->update ();
}
+ /* must emit Changed here, otherwise the changes to the pan_control below raise further
+ signals which the GUI is not prepared for until it has seen the Changed here.
+ */
+
+ if (changed) {
+ Changed (); /* EMIT SIGNAL */
+ }
+
/* force hard left/right panning in a common case: 2in/2out
*/
@@ -1021,17 +1032,8 @@ Panner::reset (uint32_t nouts, uint32_t npans)
_streampanners.back()->set_position (1.0);
_streampanners.back()->pan_control()->list()->reset_default (1.0);
-
- changed = true;
}
}
-
- send_changed:
- if (changed) {
- Changed (); /* EMIT SIGNAL */
- }
-
- return;
}
void