FLUID: Disables MergeBack.

I decided to disable MergeBack for now. During testing,
some issues could not be resolved, and focus should
be on V1.4.
This commit is contained in:
Matthias Melcher 2023-10-31 19:33:42 +01:00
parent bcc6de5332
commit 4b02c36149
8 changed files with 242 additions and 417 deletions

View File

@ -665,9 +665,9 @@ void Fl_Code_Type::write_code1(Fd_Code_Writer& f) {
if ( handle_editor_changes() == 1 ) {
main_window->redraw(); // tell fluid to redraw; edits may affect tree's contents
}
f.tag(FD_TAG_GENERIC, 0);
// Matt: disabled f.tag(FD_TAG_GENERIC, 0);
f.write_c_indented(name(), 0, '\n');
f.tag(FD_TAG_CODE, get_uid());
// Matt: disabled f.tag(FD_TAG_CODE, get_uid());
}
/**

View File

@ -278,7 +278,7 @@ void Fl_Menu_Item_Type::write_static(Fd_Code_Writer& f) {
f.write_c(", %s", ut);
if (use_v) f.write_c(" v");
f.write_c(") {\n");
f.tag(FD_TAG_GENERIC, 0);
// Matt: disabled f.tag(FD_TAG_GENERIC, 0);
f.write_c_indented(callback(), 1, 0);
if (*(d-1) != ';' && *(d-1) != '}') {
const char *p = strrchr(callback(), '\n');
@ -289,7 +289,7 @@ void Fl_Menu_Item_Type::write_static(Fd_Code_Writer& f) {
if (*p != '#' && *p) f.write_c(";");
}
f.write_c("\n");
f.tag(FD_TAG_MENU_CALLBACK, get_uid());
// Matt: disabled f.tag(FD_TAG_MENU_CALLBACK, get_uid());
f.write_c("}\n");
if (k) {
f.write_c("void %s::%s(Fl_Menu_* o, %s v) {\n", k, cn, ut);

View File

@ -2848,7 +2848,7 @@ void Fl_Widget_Type::write_static(Fd_Code_Writer& f) {
f.write_c(", %s", ut);
if (use_v) f.write_c(" v");
f.write_c(") {\n");
f.tag(FD_TAG_GENERIC, 0);
// Matt: disabled f.tag(FD_TAG_GENERIC, 0);
f.write_c_indented(callback(), 1, 0);
if (*(d-1) != ';' && *(d-1) != '}') {
const char *p = strrchr(callback(), '\n');
@ -2859,7 +2859,7 @@ void Fl_Widget_Type::write_static(Fd_Code_Writer& f) {
if (*p != '#' && *p) f.write_c(";");
}
f.write_c("\n");
f.tag(FD_TAG_WIDGET_CALLBACK, get_uid());
// Matt: disabled f.tag(FD_TAG_WIDGET_CALLBACK, get_uid());
f.write_c("}\n");
if (k) {
f.write_c("void %s::%s(%s* o, %s v) {\n", k, cn, t, ut);

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1271,6 +1271,8 @@ void write_cb(Fl_Widget *, void *) {
write_code_files();
}
#if 0
// Matt: disabled
/**
Merge the possibly modified content of code files back into the project.
*/
@ -1313,6 +1315,7 @@ int mergeback_code_files()
void mergeback_cb(Fl_Widget *, void *) {
mergeback_code_files();
}
#endif
/**
Write the strings that are used in i18n.
@ -1665,7 +1668,7 @@ Fl_Menu_Item Main_Menu[] = {
{"Save As &Template...", 0, save_template_cb, 0, FL_MENU_DIVIDER},
{"&Print...", FL_COMMAND+'p', print_menu_cb},
{"Write &Code...", FL_COMMAND+FL_SHIFT+'c', write_cb, 0},
{"MergeBack Code", FL_COMMAND+FL_SHIFT+'m', mergeback_cb, 0},
// Matt: disabled {"MergeBack Code", FL_COMMAND+FL_SHIFT+'m', mergeback_cb, 0},
{"&Write Strings...", FL_COMMAND+FL_SHIFT+'w', write_strings_cb, 0, FL_MENU_DIVIDER},
{relative_history[0], FL_COMMAND+'1', menu_file_open_history_cb, absolute_history[0]},
{relative_history[1], FL_COMMAND+'2', menu_file_open_history_cb, absolute_history[1]},

View File

@ -14,6 +14,9 @@
// https://www.fltk.org/bugs.php
//
#if 0
// Matt: disabled
#include "mergeback.h"
#include "fluid.h"
@ -485,3 +488,6 @@ int Fd_Mergeback::merge_back(const Fl_String &s, const Fl_String &p, int task) {
code = NULL;
return ret;
}
#endif

View File

@ -14,6 +14,9 @@
// https://www.fltk.org/bugs.php
//
// Matt: disabled
#if 0
#ifndef _FLUID_MERGEBACK_H
#define _FLUID_MERGEBACK_H
@ -75,3 +78,5 @@ extern int merge_back(const Fl_String &s, const Fl_String &p, int task);
#endif // _FLUID_MERGEBACK_H
#endif