for channel in self.channels:
channel.unrealize()
+ self.mixer.destroy()
+
def on_open_cb(self, *args):
dlg = gtk.FileChooserDialog(title='Open', parent=self.window,
action=gtk.FILE_CHOOSER_ACTION_OPEN,
return OutputChannel_New(channel);
}
+static PyObject*
+Mixer_destroy(MixerObject *self, PyObject *args)
+{
+ if (self->mixer) {
+ destroy(self->mixer);
+ self->mixer = NULL;
+ }
+ Py_INCREF(Py_None);
+ return Py_None;
+}
static PyMethodDef Mixer_methods[] = {
{"add_channel", (PyCFunction)Mixer_add_channel, METH_VARARGS, "Add a new channel"},
{"add_output_channel", (PyCFunction)Mixer_add_output_channel, METH_VARARGS, "Add a new output channel"},
+ {"destroy", (PyCFunction)Mixer_destroy, METH_VARARGS, "Destroy JACK Mixer"},
// {"remove_channel", (PyCFunction)Mixer_remove_channel, METH_VARARGS, "Remove a channel"},
{NULL}
};