#include <org/xwt/plat/Linux.h>
-void org::xwt::plat::X11$X11PixelBuffer::fixEnvironment() {
+void org::xwt::plat::Linux::fixEnvironment() {
// see http://lists.debian.org/debian-glibc/2003/debian-glibc-200311/msg00647.html
setenv("LD_ASSUME_KERNEL", "2.4.1", 0);
}
int oldmousex, oldmousey;
MINMAXINFO* mmi;
+ int resizable;
POINT point;
HWND hwnd2;
RECT rect, rect2;
mmi = (MINMAXINFO*)lParam;
mmi->ptMinTrackSize.x = ((uint32_t)root->minwidth) + addwidth;
mmi->ptMinTrackSize.y = ((uint32_t)root->minheight) + addheight;
- mmi->ptMaxTrackSize.x = org::xwt::plat::Win32::getScreenWidth();
- mmi->ptMaxTrackSize.y = org::xwt::plat::Win32::getScreenHeight();
+ resizable = !((root->minwidth == root->maxwidth) && (root->minheight == root->maxheight));
+ mmi->ptMaxTrackSize.x = resizable ? org::xwt::plat::Win32::getScreenWidth() : mmi->ptMinTrackSize.x;
+ mmi->ptMaxTrackSize.y = resizable ? org::xwt::plat::Win32::getScreenHeight() : mmi->ptMinTrackSize.y;
return 0;
case WM_PAINT:
public native void setLimits(int minw, int minh, int maxw, int maxh);
public native void blit(PixelBuffer s, int sx, int sy, int dx, int dy, int dx2, int dy2);
public native void dispatchEvent(gnu.gcj.RawData ev);
-
+ public void setMinimumSize(int minx, int miny, boolean resizable) {
+ setLimits(minx, miny, resizable ? Short.MAX_VALUE : minx, resizable ? Short.MAX_VALUE : miny);
+ }
public X11Surface(Box root, boolean framed) {
super(root);
this.framed = framed;