Re: [flexcoders] AIR: Detecting when window resize is complete (mouse up)
Lushen, thanks for the response. Are you saying that you are able to receive MOUSE_UP events from your application when the user lets go of the mouse button as they finish resizing the application's window? I don't. On my application, I have: addEventListener(MouseEvent.MOUSE_UP, test); While I can click inside the application window and see the mouse_up events, if I click the edge of the window, resize it, and let go, I don't get any MOUSE_UP event. I get the same results if I add the event listener to the stage or nativeWindow as well. If I use MOUSE_OUT or ROLL_OVER, I likewise don't receive any events because the cursor is not inside the application bounds while it's resizing the window. If I used MOUSE_OVER, the user would have to make the cursor enter the application area after resizing the window in order for the event to be dispatched. Any other ideas? Thanks! Aaron On Thu, Jan 15, 2009 at 8:09 PM, Lushen Wu l...@iasyndicate.com wrote: I use mouseup in my application.. it seems to work for me. you coudl also play around with MOUSE_LEAVE and ROLL_OVER for the stage (activate the rollover listener for resize whenever you get a RESIZE event, then remove the listener when you have satisfactorily resized) Cheers, Lushen On 1/15/2009 3:56 PM, Aaron Hardy wrote: Hey folks, In my project I have a component that is a percentage width of its containing window. When the user resizes the window, it triggers the component to update its display list WHILE the user is dragging the window resize handle. Rather than updating the component's display while the user is dragging, I'd like to wait until the user lets go of the drag to update the component's display. Is there an event I can capture that will tell me when the user releases the mouse button after a window resize? NativeWindow.resize seems to be dispatched while the user is resizing. While that's not what I'm looking for, I tried watching that event and then adding a mouse up event listener to both the stage and native window to detect when the user then lets go of the mouse button, but a mouse up event never seems to be dispatched when the user releases the mouse button after resizing. Does anyone know of a good way to detect this or know of a creative workaround? Thanks! Aaron
[flexcoders] AIR: Detecting when window resize is complete (mouse up)
Hey folks, In my project I have a component that is a percentage width of its containing window. When the user resizes the window, it triggers the component to update its display list WHILE the user is dragging the window resize handle. Rather than updating the component's display while the user is dragging, I'd like to wait until the user lets go of the drag to update the component's display. Is there an event I can capture that will tell me when the user releases the mouse button after a window resize? NativeWindow.resize seems to be dispatched while the user is resizing. While that's not what I'm looking for, I tried watching that event and then adding a mouse up event listener to both the stage and native window to detect when the user then lets go of the mouse button, but a mouse up event never seems to be dispatched when the user releases the mouse button after resizing. Does anyone know of a good way to detect this or know of a creative workaround? Thanks! Aaron
Re: [flexcoders] AIR: Detecting when window resize is complete (mouse up)
I use mouseup in my application.. it seems to work for me. you coudl also play around with MOUSE_LEAVE and ROLL_OVER for the stage (activate the rollover listener for resize whenever you get a RESIZE event, then remove the listener when you have satisfactorily resized) Cheers, Lushen On 1/15/2009 3:56 PM, Aaron Hardy wrote: Hey folks, In my project I have a component that is a percentage width of its containing window. When the user resizes the window, it triggers the component to update its display list WHILE the user is dragging the window resize handle. Rather than updating the component's display while the user is dragging, I'd like to wait until the user lets go of the drag to update the component's display. Is there an event I can capture that will tell me when the user releases the mouse button after a window resize? NativeWindow.resize seems to be dispatched while the user is resizing. While that's not what I'm looking for, I tried watching that event and then adding a mouse up event listener to both the stage and native window to detect when the user then lets go of the mouse button, but a mouse up event never seems to be dispatched when the user releases the mouse button after resizing. Does anyone know of a good way to detect this or know of a creative workaround? Thanks! Aaron