[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[sc-dev] SF.net SVN: supercollider:[8114] trunk/build/SCClassLibrary/Common/Control/ OSCpathResponder.sc
Revision: 8114
http://supercollider.svn.sourceforge.net/supercollider/?rev=8114&view=rev
Author: jamshark70
Date: 2008-12-12 04:33:09 +0000 (Fri, 12 Dec 2008)
Log Message:
-----------
Bugfix for the bugfix: maxPathSize could become nil when removing the last pathResponder for a command. That caused an error later.
Modified Paths:
--------------
trunk/build/SCClassLibrary/Common/Control/OSCpathResponder.sc
Modified: trunk/build/SCClassLibrary/Common/Control/OSCpathResponder.sc
===================================================================
--- trunk/build/SCClassLibrary/Common/Control/OSCpathResponder.sc 2008-12-12 01:01:56 UTC (rev 8113)
+++ trunk/build/SCClassLibrary/Common/Control/OSCpathResponder.sc 2008-12-12 04:33:09 UTC (rev 8114)
@@ -11,7 +11,7 @@
classvar <>cmdPathIndices;
var <>pathResponders;
- var <>maxPathSize;
+ var <>maxPathSize = 0;
*new { arg addr, cmdName, action, pathSize;
^super.new(addr, cmdName, action).init(pathSize);
@@ -49,7 +49,7 @@
removeChild { arg responder;
pathResponders.remove(responder);
if(responder.path.size == maxPathSize) {
- maxPathSize = pathResponders.maxValue({ |resp| resp.path.size });
+ maxPathSize = pathResponders.maxValue({ |resp| resp.path.size }) ? 0;
};
if(this.isEmpty) { this.remove };
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
_______________________________________________
sc-dev mailing list
info (subscription, etc.): http://www.beast.bham.ac.uk/research/sc_mailing_lists.shtml
archive: https://listarc.bham.ac.uk/marchives/sc-dev/
search: https://listarc.bham.ac.uk/lists/sc-dev/search/