blob: b55d10cb7d564c0a58dd3125801eae42fe8c8950 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
/*
dyn - dynamical object management
Copyright (c)2003-2004 Thomas Grill (gr@grrrr.org)
For information on usage and redistribution, and for a DISCLAIMER OF ALL
WARRANTIES, see the file, "license.txt," in this distribution.
*/
#include "dyn_proto.h"
dyn_conn::~dyn_conn()
{
dyn_patchable *sobj = NULL,*dobj = NULL;
if(src != DYN_ID_NONE && (sobj = src->Patchable()))
sobj->RmvOutlet(this);
if(dst != DYN_ID_NONE && (dobj = dst->Patchable()))
dobj->RmvInlet(this);
if(sobj || dobj) {
src = dst = DYN_ID_NONE;
ident->Callback(DYN_SIGNAL_DISCONN);
}
if(sobj && dobj) {
// sys_lock();
obj_disconnect((t_object *)sobj->pdobj,slet,(t_object *)dobj->pdobj,dlet);
// sys_unlock();
}
}
/*
void dyn_conn::Invalidate()
{
if(src != DYN_ID_NONE || dst != DYN_ID_NONE) {
src = dst = DYN_ID_NONE;
ident->Callback(DYN_SIGNAL_DISCONN);
}
}
*/
|