I saw this issue come up on the Apollo forums the other day. If you want to constrain the dimensions of an Apollo application window, use the maxSize and the minSize properties of NativeWindow. I usually do it in an initialization function after setting the bounds of my window, like this:
var win:NativeWindow = systemManager.stage.window;
win.width = 800;
win.height = 600;
win.maxSize = new Point(800, 600);
win.minSize = new Point(800, 600);
win.visible = true;
You can also use the bounds property of NativeWindow to set its size and location at the same time.

Cool, Looking like VB.net a little
I’m guessing the only way to do this in Javascript would be to use the onresize event, and then using the resizeTo method to attempt to keep the window at the size you want?Or is there a better way?
Is there a way to NOT show the resizable-arrows… say I want to make the width fixed but height changeable… in that case I don’t want the cursor change on the sides.
Peter, we are looking at better solutions for future releases, but you’re right that it’s not easy to do currently.Phillip, right now the grippers always show up, but that’s something that should be fixed in future releases.Christian
Thanks Christian
I’m looking to try and center the main application window. Is there a way to do this? I found one solution on the adobe forums but that code didn’t work, my application would load and then disapear.Any ideas?
Your point is….?In what way do the paranoid rantings of a blowhard right wing tv commentator compare to the threat represented by a US senator with subpoena power?www.ihikaye.com” title=”Hikaye” target=”_blank”>HikayeAs for Chomsky, his paranoid rantings are no less offensive than O’Reilly’s except that they are more interesting due to the magnitude of the intellectual resources he brings to the discussion. I wish he had stuck to generative grammar.
Thanks Christian |{^-_-^}|
I’m looking to try and center the main application window.
Nice code.I hate previous code
Is there a way to do this? I found one solution on the adobe forums but that code didn’t work, my application would load and then disapear
Is there a way to do this? I found one solution on the adobe forums but that code didn’t work, my application would load and then disapear.
thanks.. this information is a gold mine for me becouse i was getting mad about this problem and find a solution finally..Great work
( Constraining the Dimensions of an Apollo Application Window ) very godd
I’m looking to try and center the main application window. !
Is there a way to NOT show the resizable-arrows… say I want to make the width fixed but height changeable… in that case I don’t want the cursor change on the sides.this is good idea
Is there a way to NOT show the resizable-arrows… say I want to make the width fixed but height changeable… in that case I don’t want the cursor change on the sides.
O yeah thank you very good idea
var win:NativeWindow = systemManager.stage.window;win.width = 800;win.height = 600;win.maxSize = new Point(800, 600);win.minSize = new Point(800, 600);win.visible = true;
I’m looking to try and center the main application window. !Thanks
Is there a way to NOT show the resizable-arrows… Thanks Chritian
var win:NativeWindow = systemManager.stage.window;win.width = 800;win.height = 600;win.maxSize = new Point(800, 600);win.minSize = new Point(800, 600);win.visible = true;
say I want to make the width fixed but height changeable… in that case I don’t want the cursor change on the sides.
Is there a way to NOT show the resizable-arrows… say I want to make the width fixed but height changeable… in that case I don’t want the cursor change on the sides.
I’m guessing the only way to do this in Javascript would be to use the onresize event, and then using the resizeTo method to attempt to keep the window at the size you want?Or is there a better way?
)
I’m looking to try and center the main application window.
Really good article. Im use this script in my windows. Thanks
Is there a way to NOT show the resizable-arrows… say I want to make the width fixed but height changeable… in that case I don’t want the cursor change on the sides.this is good idea
I’m guessing the only way to do this in Javascript would be to use the onresize event, and then using the resizeTo method to attempt to keep the window at the size you want?
Is there a way to NOT show the resizable-arrows…
thanks you I’m guessing the only way to do this in Javascript would be to use the onresize event, and then using the resizeTo method to attempt to keep the window at the size you want?
Is there a way to NOT show the resizable-arrows…
thnks I found one solution on the adobe forums like