From 4ddde5f4fa3f4b77c2ddf1d4848d06628d396842 Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Fri, 12 Apr 2013 02:11:25 +0300 Subject: fix random rare crashes in npc and possible other windows. --- src/gui/widgets/textpreview.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/gui/widgets/textpreview.cpp') diff --git a/src/gui/widgets/textpreview.cpp b/src/gui/widgets/textpreview.cpp index 8f0fa6104..d7885930d 100644 --- a/src/gui/widgets/textpreview.cpp +++ b/src/gui/widgets/textpreview.cpp @@ -65,6 +65,9 @@ TextPreview::TextPreview(const Widget2 *const widget, TextPreview::~TextPreview() { + if (gui) + gui->removeDragged(this); + instances--; if (instances == 0) -- cgit v1.2.3-60-g2f50