From 7a69c22bd71d3c191eb3598f1b4450907414a578 Mon Sep 17 00:00:00 2001 From: Matthias Melcher Date: Tue, 5 Dec 2023 17:54:01 +0100 Subject: #856: FLUID: improved Declaration dialog Also makes enum comment in Fl_File_Chooser.fl manageable. Not backward compatible: don't try to recreate the File Chooser with older FLUID versions. --- fluid/Fl_Function_Type.cxx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'fluid/Fl_Function_Type.cxx') diff --git a/fluid/Fl_Function_Type.cxx b/fluid/Fl_Function_Type.cxx index ccb195224..ce6493911 100644 --- a/fluid/Fl_Function_Type.cxx +++ b/fluid/Fl_Function_Type.cxx @@ -940,7 +940,7 @@ void Fl_Decl_Type::read_property(Fd_Project_Reader &f, const char *c) { */ void Fl_Decl_Type::open() { if (!decl_panel) make_decl_panel(); - decl_input->value(name()); + decl_input->buffer()->text(name()); if (is_in_class()) { decl_class_choice->value(public_); decl_class_choice->show(); @@ -963,7 +963,7 @@ void Fl_Decl_Type::open() { else if (!w) Fl::wait(); } // check values - const char*c = decl_input->value(); + const char*c = decl_input->buffer()->text(); while (isspace(*c)) c++; message = c_check(c&&c[0]=='#' ? c+1 : c); // alert user @@ -1018,6 +1018,7 @@ void Fl_Decl_Type::write_code1(Fd_Code_Writer& f) { || (!strncmp(c,"typedef",7) && isspace(c[7])) || (!strncmp(c,"FL_EXPORT",9) && isspace(c[9])) || (!strncmp(c,"struct",6) && isspace(c[6])) + || (!strncmp(c,"enum",4) && isspace(c[4])) ) ) { f.write_public(public_); write_comment_h(f, f.indent(1)); -- cgit v1.2.3