diff options
| author | Matthias Melcher <github@matthiasm.com> | 2024-09-15 14:00:10 +0200 |
|---|---|---|
| committer | Matthias Melcher <github@matthiasm.com> | 2024-09-15 14:00:15 +0200 |
| commit | da20d8397df263db882e914405bb03b9792f4692 (patch) | |
| tree | 49f2b1adddea656aa06c52e310d4938e1415a87f /fluid | |
| parent | b9b2f5d10fde23d7d0bb184547846e6508fb4313 (diff) | |
FLUID: Improved paste order option
Diffstat (limited to 'fluid')
| -rw-r--r-- | fluid/file.cxx | 3 | ||||
| -rw-r--r-- | fluid/fluid.cxx | 2 |
2 files changed, 5 insertions, 0 deletions
diff --git a/fluid/file.cxx b/fluid/file.cxx index 73b51f52c..d06283670 100644 --- a/fluid/file.cxx +++ b/fluid/file.cxx @@ -406,6 +406,9 @@ Fl_Type *Fd_Project_Reader::read_children(Fl_Type *p, int merge, Strategy strate t->layout_widget(); } + if (strategy == kAddAsFirstChild) { + strategy = kAddAfterCurrent; + } if (strategy == kAddAfterCurrent) { Fl_Type::current = t; } else { diff --git a/fluid/fluid.cxx b/fluid/fluid.cxx index b45e85cc2..44814574e 100644 --- a/fluid/fluid.cxx +++ b/fluid/fluid.cxx @@ -1421,6 +1421,8 @@ void paste_cb(Fl_Widget*, void*) { // If the current widget is a group widget and it is not folded, // add the new widgets inside the group. strategy = kAddAsLastChild; + // The following alternative also works quite nicely + //strategy = kAddAsFirstChild; } } if (!read_file(cutfname(), 1, strategy)) { |
