2 classvar resetActions, shutdownActions;
5 resetActions = Array.new;
6 shutdownActions = Array.new; // braindead extensions may rely on these
9 *registerForReset {|aFunction|
10 this.deprecated(thisMethod, OnError.class.findMethod(\add));
11 OnError.add(aFunction)
13 *registerForShutdown {|aFunction|
14 this.deprecated(thisMethod, ShutDown.class.findMethod(\add));
15 ShutDown.add(aFunction)
19 Pflow : FilterPattern {
21 Error("Pflow was replaced. please use Pstep instead").throw;
29 this.deprecated(thisMethod, Object.class.findMethod(\new));
30 "NB Model's functionality is duplicated by Object".postln;
33 changed { arg what ... moreArgs;
34 dependants.do({ arg item;
35 item.update(this, what, *moreArgs);
38 addDependant { arg dependant;
39 if (dependants.isNil, {
40 dependants = IdentitySet.new(4);
42 dependants.add(dependant);
44 removeDependant { arg dependant;
45 if (dependants.notNil, {
46 dependants.remove(dependant);
54 Panner : MultiOutUGen {
56 this.deprecated(UGen.class.findMethod(\checkNInputs));
57 ^super.checkNInputs(n)
59 checkInputs { this.deprecated; ^this.checkNInputs(1) }
64 this.deprecated(UGen.class.findMethod(\checkNInputs));
65 ^super.checkNInputs(n)
72 // platform neutral (eventually)
73 this.deprecated(thisMethod, File.class.findMethod(\openDialog));
75 { arg path; function.value(true,path) },
76 { function.value(false) } );
77 //CocoaDialog.getPaths({arg paths; function.value(paths.first) },nil)
79 // warning: doesn't handle doAction (no instance)
86 *new { arg prompt,defaultString="",func;
88 this.deprecated(thisMethod);
90 b = TextField(l,Rect(0,0,150,30));
91 b.string = String.new ++ defaultString;
92 b.action = {arg field; func.value(true,field.value); l.close; };
101 this.deprecated(thisMethod, Mix.class.findMethod(\new));
104 *arFill { arg n,func;
105 this.deprecated(thisMethod, Mix.class.findMethod(\fill));
111 // rgb() still will not work in variable declarations in classes
112 // because rgb is no longer a literal
114 // move them to init methods
115 rgb { arg green,blue;
116 this.deprecated(thisMethod, Color.class.findMethod(\new255));
117 ^Color(this / 255.0,green / 255.0, blue / 255.0)
125 this.deprecated(thisMethod, Server.findMethod(\free));
126 RootNode.new.freeAll;
129 this.deprecated(thisMethod, Synth.class.findMethod(\new));
130 Server.default.doWhenBooted({
135 this.deprecated(thisMethod, Synth.class.findMethod(\new));
136 //if not already playing, play
139 this.deprecated(thisMethod, Server.findMethod(\sampleRate));
140 ^Server.default.sampleRate ? Server.default.options.sampleRate ? 44100.0
149 this.deprecated(thisMethod, File.findMethod(\write));
150 file = File.new(path, "wb");
153 if(file.length < this.size,{
154 Error("Write file failed !!!! " ++ path).throw;
164 this.deprecated(thisMethod)
167 this.deprecated(thisMethod)
172 this.deprecated(thisMethod, ServerOptions.findMethod(\zeroConf_))
176 this.deprecated(thisMethod, ServerOptions.findMethod(\zeroConf));
180 numAudioBusChannels_{|num|
181 this.numPrivateAudioBusChannels = num - (numInputBusChannels + numOutputBusChannels);
182 this.deprecated(thisMethod);
187 // Buffer objects are cached in an Array for easy
188 // auto buffer info updating
190 this.deprecated(thisMethod, Buffer.findRespondingMethodFor(\cache));
196 this.deprecated(thisMethod, Buffer.findRespondingMethodFor(\uncache));
197 if((buf = Buffer.cachedBufferAt(this, i)).notNil) { buf.free };
200 // /b_info on the way
201 // keeps a reference count of waiting Buffers so that only one responder is needed
203 this.deprecated(thisMethod, Buffer.findRespondingMethodFor(\cache));
206 resetBufferAutoInfo {
207 this.deprecated(thisMethod, Meta_Buffer.findRespondingMethodFor(\clearServerCaches));
208 Buffer.clearServerCaches(this);
213 // map to Bus objects
214 busMap { arg firstControl, aBus ... args;
216 this.deprecated(thisMethod, Node.findMethod(\map));
218 args.pairsDo({ arg control, bus; values.addAll([control, bus.index, bus.numChannels])});
219 server.sendMsg(48, nodeID, firstControl, aBus.index, aBus.numChannels, *values);
222 busMapMsg { arg firstControl, aBus ... args;
224 this.deprecated(thisMethod, Node.findMethod(\mapMsg));
226 args.pairsDo({ arg control, bus; values.addAll([control, bus.index, bus.numChannels])});
227 ^[48, nodeID, firstControl, aBus.index, aBus.numChannels] ++ values;
233 memStore { arg libname = \global, completionMsg, keepDef = true;
234 this.deprecated(thisMethod, this.class.findRespondingMethodFor(\add));
235 this.add(libname, completionMsg, keepDef);
240 shapeNumber { arg shapeName;
241 this.deprecated(thisMethod, this.class.class.findMethod(\shapeNumber));
242 ^this.class.shapeNumber(shapeName)
248 this.deprecated(thisMethod, Meta_Help.findRespondingMethodFor(\gui));
254 occurencesOf { | obj |
255 this.deprecated(thisMethod, Collection.findRespondingMethodFor(\occurrencesOf));
256 ^this.occurrencesOf(obj);
261 copy { arg buf, dstStartAt = 0, srcStartAt = 0, numSamples = -1;
263 this.deprecated(thisMethod, this.class.findRespondingMethodFor(\copyData));
264 this.copyData(buf, dstStartAt, srcStartAt, numSamples);