From 22bd294c7baed75a24b1df7cc423042c965acbdb Mon Sep 17 00:00:00 2001 From: Dana Jansens Date: Wed, 4 Dec 2002 01:02:56 +0000 Subject: [PATCH] unregister for events when destroyed --- otk/widget.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/otk/widget.cc b/otk/widget.cc index fa729a6f..e95848a6 100644 --- a/otk/widget.cc +++ b/otk/widget.cc @@ -55,6 +55,8 @@ OtkWidget::~OtkWidget() if (_visible) hide(); + _event_dispatcher->clearHandler(_window); + std::for_each(_children.begin(), _children.end(), PointerAssassin()); if (_parent) -- 2.45.2