summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAlbrecht Schlosser <albrechts.fltk@online.de>2022-03-05 15:50:49 +0100
committerAlbrecht Schlosser <albrechts.fltk@online.de>2022-03-05 15:50:49 +0100
commit5ebb76050b77aaf6047669968fc3919f3dd043f5 (patch)
tree32afa4c0315e3bcfd7919385a1f57b4f401b6803 /src
parentc2c77956145e7cacb9a3c18ca019ff316f56fa03 (diff)
Fix size_range() - continued (issue #392)
- fix window size of GL windows as reported for test/glpuzzle.cxx - fix window not resizing on ctrl/+/- (X11 only) Unfortunately the previous commit "optimized" a necessary X11 message away. This is now fixed. Fixes #392.
Diffstat (limited to 'src')
-rw-r--r--src/Fl_Gl_Window.cxx1
-rw-r--r--src/Fl_x.cxx1
2 files changed, 2 insertions, 0 deletions
diff --git a/src/Fl_Gl_Window.cxx b/src/Fl_Gl_Window.cxx
index b87872ed2..f0e608cda 100644
--- a/src/Fl_Gl_Window.cxx
+++ b/src/Fl_Gl_Window.cxx
@@ -70,6 +70,7 @@ int Fl_Gl_Window::can_do(int a, const int *b) {
void Fl_Gl_Window::show() {
int need_after = 0;
if (!shown()) {
+ Fl_Window::default_size_range();
if (!g) {
g = pGlWindowDriver->find(mode_,alist);
if (!g && (mode_ & FL_DOUBLE) == FL_SINGLE) {
diff --git a/src/Fl_x.cxx b/src/Fl_x.cxx
index 40c0e02ea..6933ee05d 100644
--- a/src/Fl_x.cxx
+++ b/src/Fl_x.cxx
@@ -2097,6 +2097,7 @@ void Fl_X11_Window_Driver::resize(int X,int Y,int W,int H) {
if (resize_from_program && shown()) {
float s = Fl::screen_driver()->scale(screen_num());
if (is_a_resize) {
+ size_range(); // calls sendxjunk()
if (is_a_move) {
XMoveResizeWindow(fl_display, fl_xid(pWindow), rint(X*s), rint(Y*s), W>0 ? W*s : 1, H>0 ? H*s : 1);
} else {