|
|
Hello
I noticed that setting the callback for Fl_Scroll's scrollbar causes the scrollbar to freeze (even though the callback is triggered). A minimal reproducible example:
#include <FL/Fl_Window.H>
#include <FL/Fl_Scrollbar.H>
#include <FL/Fl_Scroll.H>
#include <FL/Fl_Box.H>
#include <FL/Fl.H>
void cb(Fl_Widget *, void *) {
puts("works");
}
int main() {
Fl_Window w(400, 300);
Fl_Scroll s(50, 10, 340, 280);
Fl_Box b(100, 500, 80, 40, "whatever");
s.end();
w.end();
w.show();
s.scrollbar.callback(cb, 0);
return Fl::run();
}
While the behaviour with a regular Fl_Scrollbar just works:
int main() {
Fl_Window w(400, 300);
Fl_Scrollbar s(10, 10, 20, 280);
w.end();
w.show();
s.callback(cb, 0);
return Fl::run();
}
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or unsubscribe.
[ Direct Link to Message ] | |
|
| |