2001-04-20 05:40:52 -04:00
|
|
|
$OpenBSD: patch-db_tree_cc,v 1.2 2001/04/20 09:40:53 wilfried Exp $
|
|
|
|
--- db_tree.cc.orig Wed Apr 11 21:12:19 2001
|
|
|
|
+++ db_tree.cc Fri Apr 20 11:24:35 2001
|
2001-04-02 11:14:51 -04:00
|
|
|
@@ -36,8 +36,8 @@ extern void s_fl_alert (const char *fmt,
|
|
|
|
|
|
|
|
class db_tree {
|
|
|
|
vector<string> databases,tables,strings;
|
|
|
|
- static void close (Fl_Widget *w,void *p) { w->hide(); delete w;}
|
|
|
|
- static void close_b (Fl_Return_Button *b,void *p) {Fl_Window *w = (Fl_Window *)p; w->hide(); delete w;}
|
|
|
|
+ static void close (Fl_Widget *w,void *p) { w->hide(); delete w; w=0;}
|
|
|
|
+ static void close_b (Fl_Return_Button *b,void *p) {Fl_Window *w = (Fl_Window *)p; w->hide(); delete w; w=0;}
|
|
|
|
static void put_it(Fl_Widget* w,void* p){
|
2001-04-20 05:40:52 -04:00
|
|
|
Fl_Toggle_Tree* t=(Fl_Toggle_Tree*) w; if (Fl::event_key()!=65259) return;
|
2001-04-02 11:14:51 -04:00
|
|
|
if (!t->current()) return; if (sql_command->value()[0]) sql_command->insert(" ");
|
|
|
|
@@ -111,7 +111,7 @@ public:
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
t->update_height(); w->resizable(t);
|
|
|
|
- w->show(); while (w->visible()) Fl::wait();
|
|
|
|
+ w->show(); while (w && w->visible()) Fl::wait();
|
|
|
|
}
|
|
|
|
~db_tree (void) {
|
|
|
|
databases.clear();tables.clear();strings.clear();
|