Quote:
Originally Posted by lb0
I like the look of Window_Resize and Move - does this mean a script can resize it's own GUI window?
|
Yep.
Besides checking and resetting window size and position in each defer cycle, you can prevent a user from changing the size or position of the window by dragging on the frame by blocking "WM_NCLBUTTONDOWN" mouse events:
Code:
iOK = reaper.JS_WindowMessage_Intercept(window, "WM_NCLBUTTONDOWN", false)
If you block these messages, you will probably have to check for clicks on the "Close" button yourself.
(There may be other, better ways to prevent resizing that I am not familiar with. Unfortunately, window frame styles don't seem to be cross-platform applicable.)