I'm looking for a tiled layout that performs well during resizing of
the browser window. The flexmdi approach below is very slow.

Is there a way I can improve the event handling, or is flexmdi the
wrong choice? I've thought of writing a container that does this sort
of tiling, and supports maximize of one child (but no
minimize/close/cascade), but I'm not sure I have the time to tackle
that project.

Alternatively, is there a good way to defer the re-tile until the
resize is complete?

Thanks.


<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml";
        xmlns:flexmdi="flexlib.mdi.containers.*"
        layout="vertical" creationComplete="init()"
        horizontalScrollPolicy="off" verticalScrollPolicy="off">
        
        <mx:Script>
                <![CDATA[
                        import mx.events.ResizeEvent;
                        private function init():void {
                                mdic.windowManager.tile(false, 10);
                                
mdic.addEventListener(ResizeEvent.RESIZE,resize);
                        }
                        private function resize(event:Event):void {
                                mdic.windowManager.tile(false, 10);             
                
                        }
                ]]>
        </mx:Script>

<flexmdi:MDICanvas  id="mdic" width="100%" height="100%"
horizontalScrollPolicy="off" verticalScrollPolicy="off">
     <flexmdi:MDIWindow  title="One"/>
    <flexmdi:MDIWindow title="Two" />
    <flexmdi:MDIWindow title="Three" />
   <flexmdi:MDIWindow title="Four" />
    <flexmdi:MDIWindow title="Five" />
</flexmdi:MDICanvas>
        
</mx:Application>

Reply via email to