How can I make it so the window cant be resized out of the bounds of the current monitor? Or make it so the plugin is resized to the max monitor width / height on load.
cuz I have 3 monitors -- and when the plugin is on the middle main monitor, and gets resized into the second monitor -- next time the plugin loads, it gets centered in the middle monitor, and the drag-arrow in the bottom right of the plugin is out of bounds and invisible on the bottom of the screen....
Wouldn't it make sense to have some sort of functionality controlling / preventing this behavior baked in?
EDIT : Oops. Doh. I just noticed a method called "SetWindowSizeLimits"....
EDIT 2 : It's not working the way I would've expected it too...assume screenHeight and screenWidth are 1080 and 960 here...
Quote:
int screenHeight, screenWidth;
GetDesktopResolution(screenWidth, screenHeight);
GetGUIResize()->SetWindowSizeLimits(0,
/* Min Width */ GUI_WIDTH / 2,
/* Min Height */ GUI_HEIGHT / 2,
/* Max Width */ screenWidth,
/* Max Height */ screenHeight
);
|