STR 1416: Fluid would not output the correct code for a window's hotspot

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@5412 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Matthias Melcher 2006-09-04 20:01:15 +00:00
parent 84360f49f2
commit 3ef18e4b7d
4 changed files with 26 additions and 22 deletions

View File

@ -1,5 +1,6 @@
CHANGES IN FLTK 1.1.8
- Fixed Fluid hotspot bug (STR #1416)
- Fixed image copy code (STR #1412)
- Fixed latin-to-roman text conversion (STR #1411)
- Fixed Cygwin timeout for "select" calls (STR #1151)

View File

@ -2196,9 +2196,14 @@ void Fl_Widget_Type::write_widget_code() {
write_c("%s%s->deactivate();\n", indent(), var);
if (!is_group() && resizable())
write_c("%sFl_Group::current()->resizable(%s);\n", indent(), var);
if (hotspot())
write_c("%s%s->hotspot(o);\n", indent(),
is_class() ? "this" : name() ? name() : "w");
if (hotspot()) {
if (is_class())
write_c("%shotspot(%s);\n", indent(), var);
else if (is_window())
write_c("%s%s->hotspot(%s);\n", indent(), var, var);
else
write_c("%s%s->window()->hotspot(%s);\n", indent(), var, var);
}
}
void Fl_Widget_Type::write_extra_code() {

View File

@ -25,10 +25,10 @@
// http://www.fltk.org/str.php
//
// generated by Fast Light User Interface Designer (fluid) version 1.0107
// generated by Fast Light User Interface Designer (fluid) version 1.0108
#include "about_panel.h"
void show_help(const char *name);
void show_help(const char *name);
Fl_Double_Window *about_panel=(Fl_Double_Window *)0;
@ -271,36 +271,34 @@ static void cb_Close(Fl_Return_Button* o, void*) {
}
Fl_Double_Window* make_about_panel() {
Fl_Double_Window* w;
{ Fl_Double_Window* o = about_panel = new Fl_Double_Window(315, 175, "About FLUID");
w = o;
o->color(FL_LIGHT1);
o->selection_color(FL_DARK1);
w->hotspot(o);
{ about_panel = new Fl_Double_Window(315, 175, "About FLUID");
about_panel->color(FL_LIGHT1);
about_panel->selection_color(FL_DARK1);
about_panel->hotspot(about_panel);
{ Fl_Box* o = new Fl_Box(10, 10, 115, 120);
o->image(image_fluid);
}
} // Fl_Box* o
{ Fl_Box* o = new Fl_Box(135, 10, 170, 69, "FLTK User\nInterface Designer\nVersion 1.1.7");
o->color((Fl_Color)12);
o->selection_color(FL_DARK1);
o->labelfont(1);
o->labelsize(18);
o->align(FL_ALIGN_TOP_LEFT|FL_ALIGN_INSIDE);
}
} // Fl_Box* o
{ Fl_Box* o = new Fl_Box(135, 89, 170, 42, "Copyright 1998-2006 by\nBill Spitzak and others");
o->align(132|FL_ALIGN_INSIDE);
}
} // Fl_Box* o
{ Fl_Button* o = new Fl_Button(89, 141, 123, 25, "View License...");
o->labelcolor(FL_DARK_BLUE);
o->callback((Fl_Callback*)cb_View);
}
} // Fl_Button* o
{ Fl_Return_Button* o = new Fl_Return_Button(222, 141, 83, 25, "Close");
o->callback((Fl_Callback*)cb_Close);
}
o->set_non_modal();
o->end();
}
return w;
} // Fl_Return_Button* o
about_panel->set_non_modal();
about_panel->end();
} // Fl_Double_Window* about_panel
return about_panel;
}
//

View File

@ -25,12 +25,12 @@
// http://www.fltk.org/str.php
//
// generated by Fast Light User Interface Designer (fluid) version 1.0107
// generated by Fast Light User Interface Designer (fluid) version 1.0108
#ifndef about_panel_h
#define about_panel_h
#include <FL/Fl.H>
extern void show_help(const char *name);
extern void show_help(const char *name);
#include <FL/Fl_Double_Window.H>
extern Fl_Double_Window *about_panel;
#include <FL/Fl_Box.H>