flex-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Coleman <david_coleman_...@hotmail.com>
Subject RE: Problem resizing TileGroup
Date Mon, 16 Dec 2013 15:01:37 GMT
add a resize listener in the component definition

> Date: Fri, 13 Dec 2013 09:56:46 -0600
> Subject: Re: Problem resizing TileGroup
> From: markzolotoy@gmail.com
> To: users@flex.apache.org
> 
> How would I receive ResizeEvent in my TileGroup?
> 
> 
> On Mon, Nov 25, 2013 at 2:29 PM, David Coleman <
> david_coleman_007@hotmail.com> wrote:
> 
> > Try this:
> >
> > do not directly calculate your screen changes, but do this in the
> > updateDisplayList method.When receiving the ResizeEvent, only call the
> > invalidateDisplayList() method, which sets a framework flag that will
> > trigger execution of updateDisplayList()
> > Also there are events specific events fired on maximize/restore events
> > that you can use to trigger an extra re-draw in these cases if the stock
> > life-cycle event flow is not meeting your needs.
> >
> > > Date: Mon, 25 Nov 2013 14:03:40 -0600
> > > Subject: Problem resizing TileGroup
> > > From: markzolotoy@gmail.com
> > > To: users@flex.apache.org
> > >
> > > I have screens that are generated at the run time. I am using a TileGroup
> > > as a main container for such screens. When a screen construction is done
> > I
> > > am recalculating the total height of the TileGroup and change it. Here is
> > > the code I am using for that:
> > >
> > > private function resizeTileGroup():void
> > > {
> > > var maxH:int = 0;
> > > for (var i:int=1;i<=mainWindow.rowCount;i++)
> > > {
> > > var elt:DisplayObject = mainWindow.getChildAt(i * mainWindow.columnCount
> > -
> > > mainWindow.columnCount);
> > > maxH += elt.height;
> > > }
> > > mainWindow.height = maxH + mainWindow.verticalGap * mainWindow.rowCount;
> > > }
> > >
> > > I dont have any problem with the code itself, but when a user changes a
> > > screen size by clicking on Restore down button this particular screen is
> > > not wrapped properly.
> > > Fields are overlapping each other. If I dont resize TiltGroup with the
> > > above code then there is no problem with screen resizing. Any ideas,
> > please?
> > >
> > > Thanks
> >
> >
 		 	   		  
Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message