Esempio n. 1
0
ComponentView::~ComponentView () {
    Component* subj = GetSubject();

    if (subj != nil) {
        subj->Detach(this);
    }
}
Esempio n. 2
0
static void DetachComponentViews (Editor* ed) {
    int i = 0;
    Viewer* viewer;
    Component* comp = ed->GetComponent();

    if (comp != nil) {
        while ((viewer = ed->GetViewer(i++)) != nil) {
            GraphicView* gv = viewer->GetGraphicView();
            comp->Detach(gv);
        }
    }
}