[flexcoders] Re: Undefined Method Error

2008-07-08 Thread Claudiu Ursica
Have you tried to access it via outerDocument.methodName, you'l find
some example if you google for this It means that you use
outerDocument to to target the method outside your inline item
renderer... 

PS.
If I'm not mistaking there is also a parentDocument, but better check
before trying it.

HTH,
Claudiu



[flexcoders] Tabbing children from custom item renderer inside List

2008-08-01 Thread Claudiu Ursica
Hi,

I have a List, whose dataprovider is loaded from a server. The list is
using a custom itemRenderer to render data. The renderer has amongst
other things 2 numeric steppers inside it. The list can have durin
execution none, one or many items. I want to be able to use tab and go
through the the list items (to be more specific to jump from first
numeric stepper in the renderer to the second, and then go to the next
item first numreic stepper and then second numeric stepper and then
third item first numeric stepper etc.)

This is easily accomplished with a repeater but seems impossible for
me to achieve it with the list.

Any help is apreciated.

the code snippet looks something like this:




cust item renderer


.





TIA,
Claudiu



[flexcoders] Re: Tabbing children from custom item renderer inside List

2008-08-03 Thread Claudiu Ursica
Ok, I managed to send the focus to the second numeric stepper, but when
I hit tab again I loose the tab and cannot sent the focus to the second
item in the list on the first numeric stepper.

Now my code looks something like this:

http://www.adobe.com/2006/mxml";
 implements="mx.managers.IFocusManagerComponent"
 width="100%"
 height="100%"
 verticalAlign="middle">

.. skins and other stuff ..

 
 





 

 
 

 

 
 

 

 




As said before the only components that I am interested in being in the
tabloop are the 2 numeric steppers.  Maybe I'm missing something but
when the focus is on the "stepperTwo" and I hit tab it goes away. I have
no idea how to send the focus on the second item in the list, eg the
first numeric stepper of the second item...

I have tried to do stuff in the focuOut evt handler for the second
numeric stepper but it doesn't seem to work 


TIA,
Claudiu



[flexcoders] Re: Tabbing children from custom item renderer inside List

2008-08-03 Thread Claudiu Ursica
Ok, I managed to send the focus to the second numeric stepper, but when
I hit tab again I loose the tab and cannot sent the focus to the second
item in the list on the first numeric stepper.

Now my code looks something like this:

http://www.adobe.com/2006/mxml";
 implements="mx.managers.IFocusManagerComponent"
 width="100%"
 height="100%"
 verticalAlign="middle">

.. skins and other stuff ..

 
 





 

 
 

 

 
 

 

 




As said before the only components that I am interested in being in the
tabloop are the 2 numeric steppers.  Maybe I'm missing something but
when the focus is on the "stepperTwo" and I hit tab it goes away. I have
no idea how to send the focus on the second item in the list, eg the
first numeric stepper of the second item...

I have tried to do stuff in the focuOut evt handler for the second
numeric stepper but it doesn't seem to work 


TIA,
Claudiu



[flexcoders] Re: Tabbing children from custom item renderer inside List

2008-08-04 Thread Claudiu Ursica
The problem here is that the default behaviour sends the focus outside
the list in the document that contains the list... ie the
txtAdaugaItem textfield in the code below... I managed before to switch
the tab between the 2 steppers catching the focusOut event of the first
stepper (stepperOne), but I had the same problem when the focus leaves
the second stepper (stepperTwo). It goes outside the list. If I prevent
default I don't know how to send the focus to the second renderer on the
first stepper (stepperOne). I can get it's index, but that is as far as
I got ...

Another strange thing is that I traced getNextFocusManagerComponent() on
the focusOut event of the stepperTwo and it displays the button
(btnAdaugaItem) which is after the textfield that is actually focused
(see bold id's below).

Sorry for being such a apin in the a** but this is getting a little
frustrating  and I am under pressure here te meet a deadline.


Thanks,
Claudiu



http://www.adobe.com/2006/mxml";
 layout="absolute"
 initialize="appInitializeHandler(event)">

 
 
 

 

 
 
 

 
 
 

 

 






--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> You'll need more code in keyFocusChangeHandler.  It has to not call
> preventDefault when it is time to transfer the tab to the next
renderer.
>
> 
>
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]
On
> Behalf Of Claudiu Ursica
> Sent: Sunday, August 03, 2008 5:52 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Tabbing children from custom item renderer
> inside List
>
>
>
> Ok, I managed to send the focus to the second numeric stepper, but
when
> I hit tab again I loose the tab and cannot sent the focus to the
second
> item in the list on the first numeric stepper.
>
> Now my code looks something like this:
>
>  xmlns:mx="http://www.adobe.com/2006/mxml";
> implements="mx.managers.IFocusManagerComponent"
> width="100%"
> height="100%"
> verticalAlign="middle">
>
> .. skins and other stuff ..
>
> 
> 
> 
>
>
>
>
> 
>
>  minimum="2"
> maximum="100"
> width="46"
> height="20"
> cornerRadius="3"
> &nbs! p;   backgroundColor="white"
> borderStyle="solid"
> borderThickness="0"
> tabEnabled="true">
> 
>
> 
>
>  minimum="2"
> maximum="100"
> width="46"
> height="20"
> cornerRadius="3"
> backgroundColor="white"
> borderStyle="solid"
> borderThickness="0"
> tabEnabled="true">
>! 
>
>  &n! bsp;&nbs p;  tabEnabled="false"
> id="buttonRemoveItem"
> width="15"
> height="14"
> styleName="removeItemButtonSkin"
> click="itemRendererDeleteButtonHandler(event)"
> buttonMode="true"
> />
>
> 
>
> 
>
>
> As said before the only components that I am interested in being in
the
> tabloop are the 2 numeric steppers.  Maybe I'm missing something but
> when the focus is on the "stepperTwo" and I hit tab it goes away. I
have
> no idea how to send the focus on the second item in the list, eg the
> first numeric stepper of! the second item...
>
> I have tried to do stuff in the focuOut evt handler for the second
> numeric stepper but it doesn't seem to work 
>
>
> TIA,
> Claudiu
>



[flexcoders] Re: how to change the state of custom item renderer of list control on "itemFocu

2008-08-04 Thread Claudiu Ursica
I tried myself several times to get itemFocusIn on the list but it
doesn't for some strange reason. However you can have a state variable
on the parent of the list and send that to the renderer. Depending on
the type of renderer: inline set currentState =
{outerDocument.stateNameOrWhateverYouName It}, dropin rendere you
override the data setter, and access it via
parentDocument.stateNameOrWhateverYouName in the setter.

if you want a reference to the list form the renderer try this

var parentList : List = this.parent.parent as List; 

and if you want the current selected item index try this

var parentListDataProvider:ArrayCollection = parentList.dataProvider
as ArrayCollection;
var itemIndex:int = parentList.itemRendererToIndex(this);


HTH
Claudiu




--- In flexcoders@yahoogroups.com, "prashant194" <[EMAIL PROTECTED]> wrote:
>
> Hello all,
> 
> I am using my custom component as item renderer of list control. The
> list displays my component very well but i have no idea how can i have
> a control over the list item which is my custom component. I want to
> change the state of my custom component whenever "itemFocusIn" event
> is fired. 
> How can i do that?
>




[flexcoders] Re: How to show the Hand Cursor on the Close Button?

2008-08-05 Thread Claudiu Ursica
var btn:Button = this.mx_internal::closeButton;
btn.useHandCursor = true;

However the mx:internal might change in the future so this is not
bullet proof.


--- In flexcoders@yahoogroups.com, "flexawesome" <[EMAIL PROTECTED]> wrote:
>
> Hey there,
> 
> In the titlewindow component, I set showCloseButton = true; Do you know 
> how can I show the Hand Cursor on the Close button?
> 
> Thanks
>




[flexcoders] Re: coloring a box

2008-10-08 Thread Claudiu Ursica
Try this:


package com.whatever.anotherwhatever.gradientbox
{
import mx.containers.Box;

[Style(name="fillColors", type="Array", arrayType="Number",
format="Color", inherit="no")]
public class GradientBox extends Box
{
import flash.display.*;
import flash.geom.*;
import flash.utils.*;

import mx.core.EdgeMetrics;
import mx.utils.GraphicsUtil;

import mx.logging.ILogger;
import mx.logging.Log;


private var myCornerRadius:Number;// top corner radius
private var myFillColors:Array;// fill colors (two)
private var _orientation : String = "vertical"

private static const log:ILogger =
Log.getLogger("com.betfair.controls.gradientbox.GradientBox");
[Bindable]
public static var ORIENT_VERTICAL : String = "vertical";
[Bindable]
public static var ORIENT_HORIZONTAL : String = "horizontal";

//
-
//

private function setupStyles():void
{
myCornerRadius = getStyle("cornerRadius") as Number;
if (isNaN(myCornerRadius)) myCornerRadius = 0;

// A Style metadata tag has been added for the fillColors
property since it is not a member of the superclass (Box)

myFillColors = getStyle("fillColors") as Array;
if (!myFillColors) myFillColors = [0xFF, 0xFF];
}

//
-
//

override protected function 
updateDisplayList(unscaledWidth:Number,
unscaledHeight:Number):void
{
log.debug("GradientBox::updateDisplayList()");

super.updateDisplayList(unscaledWidth, unscaledHeight);

setupStyles();

var g:Graphics = graphics;
var b:EdgeMetrics = borderMetrics;
var w:Number = unscaledWidth - b.left - b.right;
var h:Number = unscaledHeight - b.top - b.bottom;
var m:Matrix;

if (this._orientation == ORIENT_VERTICAL)
{
m = verticalGradientMatrix(0, 0, w, h);
}
else
{
m = horizontalGradientMatrix(0, 0, w, h);
}
g.clear();
g.beginGradientFill("linear", myFillColors, [1, 1], [0,
255], m);   
GraphicsUtil.drawRoundRectComplex(g, b.left, b.top, w, h,
myCornerRadius, myCornerRadius, myCornerRadius, myCornerRadius);
g.endFill();

}

public function set orientation(val : String) : void
{
this._orientation = val;
}

public function get orientation() : String 
{
return this._orientation;
}
}
}

handles both orientations

HTH,
Cheers, 
Claudiu



--- In flexcoders@yahoogroups.com, "Amy" <[EMAIL PROTECTED]> wrote:
>
> --- In flexcoders@yahoogroups.com, "gr33neye501"  wrote:
> >
> > Does anyone know how to apply a gradient color to a Box control;
> > gradient going left to right, ie horizontally. 
> > 
> > I use style "fillColors: #ff, #ff" to get a vertical gradient,
> > top to bottom. but don't know how to do it horizontally.
> > 
> > your help guys is really needed.
> 
> http://livedocs.adobe.com/flex/3/html/help.html?content=skinstyle_3.html
> 
> HTH;
> 
> Amy
>




[flexcoders] Re: adding the user input to an arraycollection

2008-10-16 Thread Claudiu Ursica
Add them as Object, the idea is to update the bookSales if I'm reading
this right? so when you pass the to the function you do it as pair
values {bookType: "Fiction", Sales: 143}.

HTH,
Cheers,
Claudiu

--- In flexcoders@yahoogroups.com, sainath evuri <[EMAIL PROTECTED]> wrote:
>
> i would like to get the input from the user using textinput boxes
and add them to the arraycollection defined in the code below.
> 
> i had defined a method addToArray for serving the purpose.what
should be the type of the arguments passed to that function.
> th code follows:
> 
> http://www.adobe.com/2006/mxml"; 
> layout="absolute">
> 
> 
> 
> 
> 
> 
>  labelFunction="chartLabel">
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
>   Connect with friends all over the world. Get Yahoo! India
Messenger at http://in.messenger.yahoo.com/?wm=n/
>




Re: [flexcoders] Locale in Flex

2008-10-16 Thread claudiu ursica
You need to be more specific. If you're running a web app is highly porbably to 
save that into a cookie on user computer. You pass that to flash as input  
parameter and precess it when flex loads (mainappp creationComplete or 
something - you'll have it in the :parameters" variable in the main app). if 
you want to read it form client's computer that is doable to google it for some 
solution it must be there. There are lots of utlities functions inside the 
framework.

HTH,
Claudiu





- Original Message 
From: Ciby Jose <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Thursday, October 16, 2008 1:20:09 PM
Subject: [flexcoders] Locale in Flex


How do I  Get Client specific System Locale in flex 
suppose if the client is working in japan the locale i want is ja_JP
or if he is in us locale i want is en_US 




  

Re: [flexcoders] Custom event - Create, dispatch, and listen to.

2008-10-17 Thread claudiu ursica
You also may want to avveride the clone method in the custom event class:
/**
 *  @private
 */
override public function clone():Event
{
return new RemoteClick(type, bubbles, cancelable);
}

   - just omit the arguments if you are not using any

Cheers,
Claudiu


- Original Message 
From: shaun <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Friday, October 17, 2008 6:23:59 AM
Subject: Re: [flexcoders] Custom event - Create, dispatch, and listen to.


Hi,

Class names should begin with an Uppercase letter. RemoteClick not 
remoteClick.
The type String can be lowercase if you want..

Something like the following..

package modulecode
{
import flash.events. Event;

public static const remoteClick: String="remoteCl ick";

public class RemoteClick extends Event
{
public function RemoteClick( type:String= "remoteClick" ,
bubbles:Boolean= false,

cancelable:Boolean= false)
{
super(type, bubbles, cancelable);
} 
}
}

//Some component that dispatches and handles RemoteClick events



public function handleButtonClick( ):void{
var eventObj:RemoteClic k = new RemoteClick( ); //no bubble
dispatchEvent( eventObj) ;
}

public function handleRemoteClickEv ent(e:RemoteClic k):void{
trace("handleRemote Click: "+e);
}

public function init():void{
addEventListener( "remoteClick" , handleRemoteClickEv ent);
}








Or

//Some component that dispatches RemoteClick events. NOTE : the name of 
the event and the type.



[Event(name= "remoteClick" , type="modulecode. RemoteClick" )]



public function handleButtonClick( ):void{
var eventObj:RemoteClic k = new RemoteClick( ); //no bubble
dispatchEvent( eventObj) ;
}








Use MyCanvas2 in another component..



function handleRemoteClick( e:RemoteClick) :void{ ... }





HTH.
- shaun


__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

Re: [flexcoders] Rippling through state changes

2008-10-17 Thread claudiu ursica
How about write a custom item renderer and expose a public property "state" 
name it however you want. Bind that property 
to the current state of your custom component. When the parent state changes, 
the item renderer wil update also.

HTH,
Claudiu




- Original Message 
From: Paul Andrews <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Friday, October 17, 2008 4:33:45 PM
Subject: [flexcoders] Rippling through state changes


I have some custom components (nothing special) that are displaying product 
information. essentially I can use the same component for seprate purposes:

Product info (each product can be added to the shopping cart), shopping cart 
(each product can be removed from the cart). Within the main component, I 
have TileLists or datagrdids with item renderers. When the custom component 
flips between states, I need the individual items contained therein to 
switch state too.

I'm trying to think of the most elegant way to do this. Any thoughs 9apart 
from the fact I'll go Doh! real soon now).

I've tended to avoid states, but seem to be embracing them big time now..

Paul 



__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

Re: [flexcoders] custom event not working in popup

2008-10-17 Thread claudiu ursica
Are you sure you are listening for the same event type in main? From what I can 
see your custom event is of type
"formSubmitted" while the main listens for "formUpdate" ...

Claudiu



- Original Message 
From: Mark Hosny <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Friday, October 17, 2008 4:59:55 PM
Subject: [flexcoders] custom event not working in popup


Hey guys,

I now know that my custom event is not working properly in my popup window when 
listening for the event in the main app. When I do this, it works:

POPUP WINDOW

[Event(name= "formUpdate" ,type="flash. events.Event" )]


dispatchEvent(new Event('formUpdate',true));

MAIN APP
application. systemManager. addEventListener ("formUpdate",handleUpdateFormSu 
bmitted);

private function handleUpdateFormSub mitted(event: Event):void {
Alert.show('SUCCESS');
}

When I use a custom event it doesn't work:

[Event(name= "formUpdate" ,type="com. event.CustomEven t")]


var evt:CustomEvent = new CustomEvent( CustomEvent. ON_TEST_CASE,
{
memberID:memberID_ txt.text
}
);
 this.dispatchEvent( evt);

MAIN APP
application. systemManager. addEventListener ("formUpdate",handleUpdateFormSu 
bmitted);

private function handleUpdateFormSub mitted(event: CustomEvent) :void {
Alert.show('SUCCESS');
}

CUSTOM EVENT
package com.event

{
import flash.events. *
   

public class CustomEvent extends Event
{


//- PUBLIC & INTERNAL VARIABLES  - - - 
- - - -
   

// event constants
public static const ON_TEST_CASE: String = "formSubmitted";
   

public var params:Object;

public function CustomEvent( $type:String, $params:Object, 
$bubbles:Boolean = true, $cancelable: Boolean = true)
{
super($type, true, $cancelable) ;
   

this.params = $params;
}
   


   

public override function clone():Event
{
return new CustomEvent( type, this.params, bubbles, cancelable);
}
   

public override function toString():String
{
returnformatToString("CustomEvent", "params", "type", "bubbles", 
"cancelable");
}
   

//- END CLASS  - - - - - 
- - - -
}

}

Thanks,

Hoz





__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

Re: [flexcoders] how to add internal padding in canvas?

2008-10-17 Thread claudiu ursica
The panel component supports padding, wil that suit you?

HTH,
Claudiu



- Original Message 
From: markflex2007 <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Friday, October 17, 2008 5:07:27 PM
Subject: [flexcoders] how to add internal padding in canvas?


I want to add right padding and left padding inside canvas so the
controls in side do not touch the side of canvas, but canvas do not
have padding attribute, how to do this.

Thanks

MK



__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

Re: [flexcoders] Listem to an event sent by a DataGrid ItemRenderer

2008-10-19 Thread claudiu ursica
Can you provide a larger code snippet? Try listen to the event on the stage 
maybe taht will help.

Cheers, 
Claudiu.





- Original Message 
From: Sébastien Tromp <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Saturday, October 18, 2008 1:18:39 PM
Subject: [flexcoders] Listem to an event sent by a DataGrid ItemRenderer


Hello,

I am stuck with an issue whose solution I cannot find on the Internet.

I have an application with a DataGrid:








where CountDownRenderer is a custom ItemRenderer that can dispatch a 
TimerEvent.TIMER_ COMPLETE event.

I would like to listen in my main application (where the DataGrid is 
defined) to this TIMER_COMPLETE event, but I have not managed to do it.

I have tried things like:
currentConstruction s.addEventListen er(TimerEvent. TIMER_COMPLETE, 
handleTimerComplete );
or
remainingTime. addEventListener (TimerEvent. TIMER_COMPLETE, 
handleTimerComplete );

but in neither case is the event caught.

Do you have any idea on how this could be achieved?

Thanks a lot,
Sébastien



__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

Re: [flexcoders] Alert.show - Detect when closed from another mxml component

2008-10-21 Thread claudiu ursica
Suposedly you'd have a data model in there, in you app, you can hold a boolean 
value and set it to true everytime you call Alert show and set it to false on 
close. In your other mxml just check that property of the model and you're 
done. (Not sure it is the best way to do it though.). 

HTH,
Claudiu



- Original Message 
From: sleblang <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Monday, October 20, 2008 10:52:25 PM
Subject: [flexcoders] Alert.show - Detect when closed from another mxml 
component


I have an Alert.show() being called from a command class. I need to detect when 
this Alert is closed in another mxml component (as opposed to the command 
class). What's the best way to determine when it's been closed?  Does the event 
bubble? So far I have not been able to 'catch' it.

Thanks for any and all replies.
 


  

Re: [flexcoders] Custom List Renderer Memory Leak

2008-10-21 Thread claudiu ursica
Can you paste the code snippet that update the list?

Cheers,
Claudiu



- Original Message 
From: darkcube86 <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Tuesday, October 21, 2008 7:49:53 PM
Subject: [flexcoders] Custom List Renderer Memory Leak


I have a list which always displays 3 items using a custom list
renderer.  As items are added to this list, the last one in the list
is removed (FIFO Queue), and a DefaultListEffect is used to animate
incoming and outgoing items with a fade effect.

The problem is that after some time (~5000 items passed through this
list) the memory usage gets very very high, and if I profile the
application I can see that instances of my renderer are not being removed.

In order to solve this I attempted to create a factory that would
cache the tiles and reuse them and use that as my itemRenderer
instead, but unfortunately it appears that if I reuse a tile that has
already been used it doesn't show up at all.  I thought this was
probably due to the list effect setting it to invisible, height 0,
etc... so I attempted to reset all those settings before passing the
item from the factory to the list, but it still just isn't working
correctly.

Is there a way to reuse the renderers and still have them show up
properly to alleviate my memory leak? 




  

Re: [flexcoders] Re: Alert.show - Detect when closed from another mxml component

2008-10-21 Thread claudiu ursica
You can do that, however it is not very engineering like to bubble lots of 
layer to the application. I would bypass thet event through Cairngorm if I were 
you, provides a more decoupled way of handling things

HTH,
Claudiu



- Original Message 
From: sleblang <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Tuesday, October 21, 2008 10:52:11 PM
Subject: [flexcoders] Re: Alert.show - Detect when closed from another mxml 
component


Thanks for all the suggestions. I am sure one if not all of them would
work. Just out of curiosity, in Flash, you can set a listener for the
Stage to receive via capture or bubble, for example, mouseclicks
(Stage.addEventList ener(MouseEvent. CLICK,clickHandl er)). Is there no
way to do this in Flex with the Alert component and the Stage
(Application. application? )?

--- In [EMAIL PROTECTED] ups.com, claudiu ursica  wrote:
>
> Suposedly you'd have a data model in there, in you app, you can hold
a boolean value and set it to true everytime you call Alert show and
set it to false on close. In your other mxml just check that property
of the model and you're done. (Not sure it is the best way to do it
though.). 
> 
> HTH,
> Claudiu
> 
> 
> 
> - Original Message 
> From: sleblang <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED] ups.com
> Sent: Monday, October 20, 2008 10:52:25 PM
> Subject: [flexcoders] Alert.show - Detect when closed from another
mxml component
> 
> 
> I have an Alert.show() being called from a command class. I need to
detect when this Alert is closed in another mxml component (as opposed
to the command class). What's the best way to determine when it's been
closed?  Does the event bubble? So far I have not been able to 'catch' it.
> 
> Thanks for any and all replies.
>




  

Re: [flexcoders] Binding Getter to Collection Change

2008-10-22 Thread claudiu ursica
Binding only fires when you are hooked into a certain item of the array 
collection changes. So unless you are bound on a certain item, you should 
probably add a listener for CollectionEvent. COLLECTION_ CHANGE yourself and 
handle "by hand" the update.

HTH,
Claudiu



- Original Message 
From: Kevin <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Wednesday, October 22, 2008 1:26:16 AM
Subject: [flexcoders] Binding Getter to Collection Change


I may be missing something simple here, but I would like to create a
getter function in one of my classes that binds to a collection change
event of an ArrayCollection in the same class.  As a simple example,

public var myCollection: ArrayCollection = new ArrayCollection( );

[Bindable]
public function get mySimpleSum( ):int{
return myCollection. length + 10;
}

I would like to bind the view to the getter so that when myCollection
is modified, the getter will refire and the view will update.  So far
nothing I have tried (such as
[Bindable(event= CollectionEvent. COLLECTION_ CHANGE)]) works...

Thoughts?...

Thanks, Kevin




  

Re: [flexcoders] Re: PLaying Flash From Scratch

2008-10-24 Thread claudiu ursica
I guess you are having the flash movie embeded in a flex wrapper. Expose a 
public "start" (or something)function from there (from the flash movie). Just 
call that on the state change interception.

HTH,
Claudiu



- Original Message 
From: John <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Friday, October 24, 2008 12:45:41 PM
Subject: [flexcoders] Re: PLaying Flash From Scratch


Cool, thanks for that.

I now can intercept the change of state within the ViewStack, so any 
ideas how I can then tell the SWF file in the component how to play 
from frame 1?

TIA

--- In [EMAIL PROTECTED] ups.com, "valdhor" <[EMAIL PROTECTED] ..> wrote:
>
> 
http://livedocs. adobe.com/ flex/3/langref/ mx/containers/ ViewStack. html#
event:change
> 
> 
> --- In [EMAIL PROTECTED] ups.com, "John"  wrote:
> >
> > Does anyone have any source code for this? I cannot find anything 
> > mentioned in the Flex 3 documentation.
> > 
> > --- In [EMAIL PROTECTED] ups.com, "Fotis Chatzinikos" 
> >  wrote:
> > >
> > > The view stack has a change event,
> > > 
> > > you can associate a handler there and depending on the index of 
the 
> > stack
> > > call the appropriate swf start/play method
> > > 
> > > 
> > > On Wed, Oct 22, 2008 at 3:20 AM, John <
> > > jpapworth@> wrote:
> > > 
> > > >   My actionscript is not that strong, we have several Flash 
> > animations
> > > > in each of our viewstack children, and reall I wondered if 
there 
> > was
> > > > something we could make it play it from frame 1 of the movie 
> > again.
> > > >
> > > > If we cannot get this to work, is there a similar 
functionality
> > > > within States, where we can use our forward and back buttons 
to
> > > > navigate each way?
> > > >
> > > > TIA
> > > > --- In [EMAIL PROTECTED] ups.com ,
> > > > "valdhor"  wrote:
> > > > >
> > > > > In a viewstack each view is only instantiated when that 
> > particular
> > > > > view is selected. Once instantiated, it is not instantiated 
> > again.
> > > > > What you want to do is have your Flash play when an event 
> > occurs.
> > > > For
> > > > > the instantiation you would probably want to use the
> > > > CreationComplete
> > > > > event. For subsequent times I think the event is Show 
(Although 
> > I
> > > > > could be wrong)
> > > > >
> > > > >
> > > > > --- In [EMAIL PROTECTED] ups.com  > 40yahoogroups. com>, "John"
> > > >  wrote:
> > > > > >
> > > > > > Hi there
> > > > > >
> > > > > > I wonder if someone can help me.
> > > > > >
> > > > > > I have a viewstack with seperate pages - each page has a 
Flash
> > > > > > animation. However, what I have found is when I navigate 
> > through
> > > > the
> > > > > > viewstack, the flash plays, then I goto the next page all 
is
> > > > fine, but,
> > > > > > if I then return to the previous one - it does not reset 
the
> > > > Flash to
> > > > > > frame 1. It has stayed at its last frame.
> > > > > >
> > > > > > Is there a way of telling Flex to play these movies from 
the
> > > > beginning
> > > > > > everytime?
> > > > > >
> > > > > > Regards
> > > > > >
> > > > > > J
> > > > > >
> > > > >
> > > >
> > > > 
> > > >
> > > 
> > > 
> > > 
> > > -- 
> > > Fotis Chatzinikos, Ph.D.
> > > Founder,
> > > Phinnovation
> > > Fotis.Chatzinikos@ ,
> > >
> >
>




  

[flexcoders] Re: Extending the Datagrid to enable paging

2008-10-28 Thread Claudiu Ursica
check this one,

http://www.adobe.com/cfusion/communityengine/index.cfm?event=showdetails&productId=2&postId=11083

hth,
Claudiu

--- In flexcoders@yahoogroups.com, "oneworld95" <[EMAIL PROTECTED]> wrote:
>
> Hi, all. For a current project, I need to extend the DataGrid to
> enable paging of the data. Can you point me to some examples of how to
> do this sort of customization? Thank you.
>




Re: [flexcoders] ItemRenderes are consuming more memory

2008-10-28 Thread claudiu ursica
I'm not sure what you are trying to do, but try to add new instances to the 
list only when needed, otherwise just update already existing elements.

Cheers,
Claudiu





From: jitendra jain <[EMAIL PROTECTED]>
To: flex group flex 
Sent: Tuesday, October 28, 2008 8:34:52 AM
Subject: [flexcoders] ItemRenderes are consuming more memory


I read Alex Blog on Item Renderers. I understood what Alex needs to say. 
I have a tabBar in my application and a datagrid in the viewstack.
whenever anyone clicks on the tab ,my datagrid data changes.
I have 32 columns, with 5 columns having renderes. I have renderers for 
displaying backgroundcolor
I used Profiler and sees that everytime it adds more instances to the list and 
also memory consumption is rising.


 Thanks,

with Regards,
Jitendra Jain




 Connect with friends all over the world. Get Yahoo! India Messenger. 


  

Re: [flexcoders] Html file in Flex application.

2008-10-28 Thread claudiu ursica
Lots of components within the framework (the VBox or HBox for example) have the 
the htmlText property.
Just assign your page to that property.

However I am absolutely sure that there is somewhere there an example related 
to this issue, they have embeded yahoo in flex. Just cannot find it now, try 
google it...

HTH,
Claudiu





From: kotha poornima <[EMAIL PROTECTED]>
To: flexcoders 
Sent: Tuesday, October 28, 2008 10:40:43 AM
Subject: [flexcoders] Html file in Flex application.


Hi all,
Can i embed html file in my flex application? If it is possible please give me 
an idea how can i do the same.


Thanks in Advance,
Poornima.




  

[flexcoders] Re: Flex creating an unwanted extra item in list

2008-06-03 Thread Claudiu Ursica
--- In flexcoders@yahoogroups.com, "spirit_ryder2k"
<[EMAIL PROTECTED]> wrote:
>
> Hi, I'm doing a small app which loads a list of songs from an XML 
> and display it in a list. I'm using a TileList with a custom 
> renderer to render the songs. Because I want to keep track which 
> song has loaded I put a trace comment on the creation event. This 
> all works as intended, the song list has 2 items and 2 item are 
> displayed on screen. But I get 3 traces. It seems that the TileList 
> creates 3 objects but only shows 2.
> 
> Any suggestions on how to make sure it only loads 2 objects? It 
> seems like the first item in the XML list is created twice :(
> 
> Source code below:
> 
> Song1.xml
> -
> 
> 
>   
>   We are broken
>   ../Paramore - We Are Broken.mp3
>   
>   
>   Pressure
>   ../Paramore - Pressure (Acoustic).mp3
>   
> 
> -
> 
> renderer.mxml
> -
> 
> http://www.adobe.com/2006/mxml"; 
> creationComplete="trace('new song ' + data.name)" 
> text="{data.name}"/>
> -
> 
> test.mxml
> -
> 
> http://www.adobe.com/2006/mxml"; 
> layout="absolute" creationComplete="SongServ.send()">
>   
>dataProvider="{SongServ.lastResult.song.track}"  left="10" top="10" 
> right="10" height="200"/>
> 
> -
>

Ok, I've runned into this issue a few weeks ago and Alex Harui,
adviced me to use the rowHeight and set it a value, the flex will now
how to render the lines without creating an extra item. however you'l
still get duplicates first time you trace because of the binding which
will fire twice, and I don't think you can do something about it. You
could unmarshall your XML into objects and reuse those objects if they
already created/ only create them when not already created and then
the binding will fire only when the value of the object is changed.

Hope this helps,
Claudiu.




[flexcoders] Re: Memory issues ... garbage collection only running in IE (not FF or Safari)

2008-10-29 Thread Claudiu Ursica
Here is how we manage collection when it comes to Araay collection.

We declare a custom class whic helds an instance of the array
collection and an array for fast searching. 

[Bindable]
public class FullGameHistorySuiteStatuses
{

private var _suiteStatusesArrayCollection : ArrayCollection = new
ArrayCollection();

private var _suiteStatusesArray : Array = new Array();  


when you add you check if item not already in there, if so just
update, otherwise add 

public function addSuiteStatus(suiteStatus :
FullGameHistroySuiteStatus) : void {

if (this._suiteStatusesArray[suiteStatus.id + "_"] == null)
{   this._suiteStatusesArray[suiteStatus.id + "_"] 
= suiteStatus;
this._suiteStatusesArrayCollection.addItem(suiteStatus);
}

else 
{
FullGameHistroySuiteStatus(this._suiteStatusesArray[suiteStatus.id +
"_"]).updateFullGameHistorySuiteStatus(suiteStatus);
}

}

Put in public getters/setters for props if needed

Now the item class

[Bindable]
public class FullGameHistroySuiteStatus
{

public var id : String;

private var _points : String;
private var _place : String;

//
===
// Constructor
//
===
public function FullGameHistroySuiteStatus(id : String)
{
this.id = id;
}


public function updateFullGameHistorySuiteStatus(suiteStatus :
FullGameHistroySuiteStatus) : void
{
   this._place = suiteStatus.place;
   this._points = suiteStatus.points;
}


This is code snippet extracted form the app, you need to adapt it to
your needs, however it works for us in eficienlyt managing collections
because arrays are very fast for searching while array collections
very good for bindings ...

HTH,
Claudiu

--- In flexcoders@yahoogroups.com, "e_baggg" <[EMAIL PROTECTED]> wrote:
>
> Thanks for the great advice so far...so what is the best way of 
> freeing Images for gc()? I have a DataGrid that has an itemRenderer 
> with a ...if I have a dataProvider ArrayCollection (where 
> each records has a URL that the Image uses)...does simply setting the 
> dataProvider to null take care of marking the image for GC? And 
> anything I have a Bitmap for? Simply setting to null.
> 
> Thanks again. 
> 
> --- In flexcoders@yahoogroups.com, Alex Harui  wrote:
> >
> > If your app creates lots of stuff, you'll create a high-water mark 
> and GC won't run until you get back up near that high-water mark.  
> Images are known to easy ways to set that high-water mark pretty high.
> > 
> > In general, the answer is to re-use instead of re-create, and only 
> create what you need when you need it.
> > 
> > -Alex
> > 
> > From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
> On Behalf Of Blake Barrett
> > Sent: Tuesday, October 28, 2008 3:09 PM
> > To: flexcoders@yahoogroups.com
> > Subject: RE: [flexcoders] Memory issues ... garbage collection only 
> running in IE (not FF or Safari)
> > 
> > e_baggg,
> > You're not the only one. We're experiencing very similar 
> problems. Our app just keeps gobbling memory until the browser 
> crashes. We've had to resort to calling dispose() explicitly on every 
>  and bitmap we ever instantiate, and explicitly calling 
> removeAllChildren() on every contaniner before navigating away from 
> anything. Helps a little. I'm going to look in to the link you 
> mentioned. Maybe that will help us a little more than it has for you 
> (fingers crossed).
> > 
> > Let us all know if you find anything else out.
> > 
> > Blake
> > 
> > 
> > From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
> On Behalf Of e_baggg
> > Sent: Tuesday, October 28, 2008 2:51 PM
> > To: flexcoders@yahoogroups.com
> > Subject: [flexcoders] Memory issues ... garbage collection only 
> running in IE (not FF or Safari)
> > 
> > So I have an app in production which after 10 minutes of usage began
> > to perform EXTREMELY slow, and users had to restart the app. (Flex 
> 3)
> > Windows and Mac...all browsers. I did some Profiling and did not get
> > far. Whenever I take a Memory Snapshot, gc() is forced and all my
> > objects are correctly removed from memory. So why are they not 
> gc()'d
> > in normal runtime?? I know gc() only runs when new memory is 
> requested
> > and nothing is being drawn/rendered. Both seem to be OK on my side.
> > 
> > I have read extensively all the blogs and Adobe docs regarding this
> > issue, including the event listener for ENTER_FRAME which calls
> > System.gc() twice. (http://www.craftymind.com/2008/04/09/kick-
> > starting-the-garbage-collector-in-actionscript-3-with-air/). This
> > unfortunately did not work for me.
> > 
> > To simplify, I created a simple app that adds and removes RichText
> > fields. if I create 50 of them, then remove them all, then Add 

[flexcoders] Drag and drop module

2008-11-10 Thread Claudiu Ursica
Hi,
I have a module who contains a TitleWindow.
In the main application i use a ModuleLoader to loads that module at a
certain time (when I click a button to be more precise).

Everything works fine until I want to move the frehly loaded
TitleWindow (from the module) on the screen. I am not able to maket it
move when clicking it.

If anyone has any input on this it will be appreciated.

TIA,
Claudiu




[flexcoders] Re: Drag and drop module

2008-11-10 Thread Claudiu Ursica
10x Alex,
I downloaded the code and its working I'll see how can I adapt my code
to this but i believe it will be fine.

Cheers,
Claudiu

--- In flexcoders@yahoogroups.com, Alex Harui <[EMAIL PROTECTED]> wrote:
>
> http://blogs.adobe.com/aharui/2007/08/popup_dialogs_as_modules.html
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]
On Behalf Of Claudiu Ursica
> Sent: Monday, November 10, 2008 5:04 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Drag and drop module
> 
> 
> Hi,
> I have a module who contains a TitleWindow.
> In the main application i use a ModuleLoader to loads that module at a
> certain time (when I click a button to be more precise).
> 
> Everything works fine until I want to move the frehly loaded
> TitleWindow (from the module) on the screen. I am not able to maket it
> move when clicking it.
> 
> If anyone has any input on this it will be appreciated.
> 
> TIA,
> Claudiu
>




[flexcoders] Module loaded but not displayed every time...

2008-11-17 Thread Claudiu Ursica
Hi,
I load a module using a custom module loader. Event though the READY
event fires every time, and the visible property traces out to true, I
am not able to see the module each time I load it. This happens only
when I start the application. If I can see it the first time I can
then unload and load it again and it gets displayed. However if I'm
not seeing it the first time it is not visible for good.

Sometimes (not all the time) I gets shown after a while. I have tried
invalidating the display list or similar force repainting techniques
but nothing seems to work.

Has any of you experienced something similar? 
If so please let me know if you have found any workaround.

TIA,
Claudiu



Re: [flexcoders] Re: dataGrid effciency

2008-11-19 Thread claudiu ursica
You can remember your last index of the scroolbar and use scorllToIndex(index : 
int) after the refresh.

HTH,
Claudiu





From: Fu Di <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Wednesday, November 19, 2008 11:03:39 AM
Subject: Re: [flexcoders] Re: dataGrid effciency


thank u, other problem puzzle me, when the dataGrid's data changing and it will 
refresh itself. 
if i drag scrollbar to a  position,after the dataGrid refresh the scrollbar 
will go to top of dataGrid..






From: Tim Hoff <[EMAIL PROTECTED] com>
To: [EMAIL PROTECTED] ups.com
Sent: Wednesday, November 19, 2008 2:36:08 PM
Subject: [flexcoders] Re: dataGrid effciency



Hi,

The biggest performance culprits with a DataGrid, or any of the ListBase
components, is the itemRenderers and the size of the dataProvider.  You
can optimize the itemRenderers by using UIComponent; see Alex's blog. 
And depending on how many items are in the dataProvider, you could see
performance issues there as well.  If you are performing any
calculations you might look at ways to tighten up the code.  With a one
second refresh, you might be asking too much of the UI.

-TH

--- In [EMAIL PROTECTED] ups.com, Fu Di <[EMAIL PROTECTED]> wrote:
>
> hi everyone, i used dataGrid to display a list of real time data. when
i finished it, i found it is slow.
> the DataGrid has 13 DataGridColumns, every column almost nest a
ItemRenderer. i had to do this to meet the requirements of pattern.
> the data update every second, and i need to change the components¢
style in some columns following the data. as i know these two aspects
> will cost large calculation.
>
> who konws how to optimize it or other ways to achieve.
>
> thanks
>





  

[flexcoders] Re: Module loaded but not displayed every time...

2008-11-25 Thread Claudiu Ursica
Hi again, 
I see nobody bumped into this issue...
Since the previous post I have discovered that the module does not
show up because the cration complete event does not fire all the time.
I was able to log the preinitialize event and the init event but when
the module doesn't show it is because the creation complete does not
fire. Eventually the module does show after 2 minutes or so... an then
I see the log for creation complete. 

In my initialize event I initialize some variables and that always
gets done, but I vahe no odea what happends sometimes that determines
the creation complete to fire so late.

Maybe some of you can help with this,
TIA,
Caludiu


--- In flexcoders@yahoogroups.com, "Claudiu Ursica" <[EMAIL PROTECTED]>
wrote:
>
> Hi,
> I load a module using a custom module loader. Event though the READY
> event fires every time, and the visible property traces out to true, I
> am not able to see the module each time I load it. This happens only
> when I start the application. If I can see it the first time I can
> then unload and load it again and it gets displayed. However if I'm
> not seeing it the first time it is not visible for good.
> 
> Sometimes (not all the time) I gets shown after a while. I have tried
> invalidating the display list or similar force repainting techniques
> but nothing seems to work.
> 
> Has any of you experienced something similar? 
> If so please let me know if you have found any workaround.
> 
> TIA,
> Claudiu
>




Re: [flexcoders] Re: Module loaded but not displayed every time...

2008-11-25 Thread claudiu ursica
I am, but via bindings (set via BindUtils.bind setter in the complete handler), 
but I have put a message before those bindings and it is not like the bindings 
are not init, the event doesn't get dispatched. The setters are the one who 
dispatch cairngorm events and in the command (actually delegate) I make a 
request to the server.

I'll post some code tomorrow first thing in the morning...
Cheers,
Claudiu





From: valdhor <[EMAIL PROTECTED]>
To: flexcoders@yahoogroups.com
Sent: Tuesday, November 25, 2008 6:47:09 PM
Subject: [flexcoders] Re: Module loaded but not displayed every time...


Are you contacting a server by any chance?

Perhaps you could post some code?

--- In [EMAIL PROTECTED] ups.com, "Claudiu Ursica" 
wrote:
>
> Hi again, 
> I see nobody bumped into this issue...
> Since the previous post I have discovered that the module does not
> show up because the cration complete event does not fire all the time.
> I was able to log the preinitialize event and the init event but when
> the module doesn't show it is because the creation complete does not
> fire. Eventually the module does show after 2 minutes or so... an then
> I see the log for creation complete. 
> 
> In my initialize event I initialize some variables and that always
> gets done, but I vahe no odea what happends sometimes that determines
> the creation complete to fire so late.
> 
> Maybe some of you can help with this,
> TIA,
> Caludiu
> 
> 
> --- In [EMAIL PROTECTED] ups.com, "Claudiu Ursica" 
> wrote:
> >
> > Hi,
> > I load a module using a custom module loader. Event though the READY
> > event fires every time, and the visible property traces out to true, I
> > am not able to see the module each time I load it. This happens only
> > when I start the application. If I can see it the first time I can
> > then unload and load it again and it gets displayed. However if I'm
> > not seeing it the first time it is not visible for good.
> > 
> > Sometimes (not all the time) I gets shown after a while. I have tried
> > invalidating the display list or similar force repainting techniques
> > but nothing seems to work.
> > 
> > Has any of you experienced something similar? 
> > If so please let me know if you have found any workaround.
> > 
> > TIA,
> > Claudiu
> >
>




  

[flexcoders] Re: Module loaded but not displayed every time...

2008-11-26 Thread Claudiu Ursica
However this is not something I
can be sure of that it is indeed the fix... And the fact that this
happend very randomly doesn't help that much either

TIA,
Claudiu

--- In flexcoders@yahoogroups.com, claudiu ursica <[EMAIL PROTECTED]>
wrote:
>
> I am, but via bindings (set via BindUtils.bind setter in the complete
handler), but I have put a message before those bindings and it is not
like the bindings are not init, the event doesn't get dispatched. The
setters are the one who dispatch cairngorm events and in the command
(actually delegate) I make a request to the server.
>
> I'll post some code tomorrow first thing in the morning...
> Cheers,
> Claudiu
>
>
>
>
> 
> From: valdhor [EMAIL PROTECTED]
> To: flexcoders@yahoogroups.com
> Sent: Tuesday, November 25, 2008 6:47:09 PM
> Subject: [flexcoders] Re: Module loaded but not displayed every
time...
>
>
> Are you contacting a server by any chance?
>
> Perhaps you could post some code?
>
> --- In [EMAIL PROTECTED] ups.com, "Claudiu Ursica" 
> wrote:
> >
> > Hi again,
> > I see nobody bumped into this issue...
> > Since the previous post I have discovered that the module does not
> > show up because the cration complete event does not fire all the
time.
> > I was able to log the preinitialize event and the init event but
when
> > the module doesn't show it is because the creation complete does not
> > fire. Eventually the module does show after 2 minutes or so... an
then
> > I see the log for creation complete.
> >
> > In my initialize event I initialize some variables and that always
> > gets done, but I vahe no odea what happends sometimes that
determines
> > the creation complete to fire so late.
> >
> > Maybe some of you can help with this,
> > TIA,
> > Caludiu
> >
> >
> > --- In [EMAIL PROTECTED] ups.com, "Claudiu Ursica" 
> > wrote:
> > >
> > > Hi,
> > > I load a module using a custom module loader. Event though the
READY
> > > event fires every time, and the visible property traces out to
true, I
> > > am not able to see the module each time I load it. This happens
only
> > > when I start the application. If I can see it the first time I can
> > > then unload and load it again and it gets displayed. However if
I'm
> > > not seeing it the first time it is not visible for good.
> > >
> > > Sometimes (not all the time) I gets shown after a while. I have
tried
> > > invalidating the display list or similar force repainting
techniques
> > > but nothing seems to work.
> > >
> > > Has any of you experienced something similar?
> > > If so please let me know if you have found any workaround.
> > >
> > > TIA,
> > > Claudiu
> > >
> >
>



Re: [flexcoders] unload module but flexmodulefactory remains ?

2008-12-28 Thread claudiu ursica
info.removeEventListener(ModuleEvent. READY, modEventHandler)?? before setting 
it to null
HTH,
Claudiu





From: rockorgames 
To: flexcoders@yahoogroups.com
Sent: Saturday, December 27, 2008 9:20:13 PM
Subject: [flexcoders] unload module but flexmodulefactory remains ?


hm i have this sample app where it simples loads/unloads a simple module..

when
executing in profiler the instance of the module "a" gets removed
without a problem.. but the instance of _a_mx_core_flexmodu lefacto ry only 
goes up..

when first start the app the instance of  _a_mx_core_flexmodu lefacto ry
is 1.. if i remove the module.. the instance of "a" goes to 0 but the
flexmodulefactory instance doesnt.. if i keep on adding and removing
the module the flexmodulefactory instance never goes down... in a
larger app this will be a problem..

anyone knows whats wrong here ?

app:











module:








 


  

Re: [flexcoders] image in tilelist not showing

2008-12-30 Thread claudiu ursica
Are you sure that your binding expression for Image.source evaluates correctly?
You're code seems ok to me. If the type and price are displayed the source 
might be the issue...

Claudiu





From: johndoematrix 
To: flexcoders@yahoogroups.com
Sent: Tuesday, December 30, 2008 3:25:04 PM
Subject: [flexcoders] image in tilelist not showing


hi guys i have a tilelist that is meant to show images from a database
bt only an image icon is shown instead of the actual image. am using
coldfusion as my backend. here is a sample of my code. 



"TileListItemRender er.mxml"


http://www.adobe. com/2006/ mxml">




 





  

Re: [flexcoders] Re: image in tilelist not showing

2008-12-31 Thread claudiu ursica
If I were you I'd override the data setter in the ItemRendere and debug in 
there. If you got the correct data in there you lost me

public override function set data(value : Object) : void
{
super.data = value;
//add debugging code in here and see that the path is indeed 
the right one
}


Claudiu




From: johndoematrix 
To: flexcoders@yahoogroups.com
Sent: Wednesday, December 31, 2008 10:33:40 AM
Subject: [flexcoders] Re: image in tilelist not showing


still confused why the images cant show. i have tested the path to my
images folder and it is correct. is there something am missing?




  

Re: [flexcoders] 1180 Error

2009-01-03 Thread claudiu ursica
I think Manish is right. There is something wrong with your projects settings 
or the class is not in the directory structure you specified in the import 
directive. I'v tried (copy/paste) your code in a new project in my FB eclipse 
plugin and it works smoothly. I run it and no error it display the 3 objects 
you've created.

Claudiu






From: Manish Jethani 
To: flexcoders@yahoogroups.com
Sent: Friday, January 2, 2009 9:02:44 PM
Subject: Re: [flexcoders] 1180 Error


On Fri, Jan 2, 2009 at 3:46 AM, jason1701e  wrote:

> I have the following Address Class:
>
> package com.jherrington
> {
>public class Address
>{

[snip]

> The problem is that I receive an 1180 Error saying the following:
> Call to a possible undefined method Address.

Is your Address class in the source path? Try declaring a variable of
type Address. If you get an error on compilation, your source path is
wrong. You can use the source-path compiler argument to mxmlc to add
the class to the path (or update the Project Properties in Flex
Builder).

Manish

-- 
http://manishjethan i.com/



  

Re: [flexcoders] Cairngorm and ChangeWatcher

2009-01-10 Thread claudiu ursica
http://weblogs.macromedia.com/auhlmann/archives/2007/02/creating_a_popu.html#more

This should give you some directions...

Claudiu





From: lampei 
To: flexcoders@yahoogroups.com
Sent: Saturday, January 10, 2009 1:34:25 AM
Subject: [flexcoders] Cairngorm and ChangeWatcher


I have begun tinkering around with various frameworks and thought I
would start with Cairngorm.  I am refactoring a small application to
use Cairngorm, but ran into a snag.  All of the examples I found just
bound an item in the view to a property of the ModelLocator, and thus
automagically updated the value when the property of the ModelLocator
changed.  However, I had one item that is waiting for a response from
a service, and needed to respond to that change (such as an error
message), rather than just display the updated data that is returned.

I found an example that uses the ChangeWatcher class to watch the
property on the ModelLocator.  This seemed to work fine, but I was
wondering if this is still best practice, as the example I found was
from 2006.

Thanks.




  

Re: [flexcoders] Re: Cairngorm and ChangeWatcher

2009-01-12 Thread claudiu ursica
I don't know if that is indeed the best practice but for now if it suit your 
needs just do it. The main idea is that the model drives the view, and at the 
same time it represent the current state of the up. Having a view bound to that 
model makes the view display the current state for the app. Now you either do 
it by bindings or 

by your own implementation of the observer pattern it is up to you. That 
implementation of the observer in there helps you prevent silent failures, 
otherwise flex bindings should do just fine. I'm not sure this is what you 
expected to hear, and I am sorry if I cannot be more helpful. We had an app 
once an we used a custom error class to handle all the messages/erros in the up 
(something like model.error.doError()) which handled both the messages and 
their displaying triggering. It did just fine, dunno if it was the best way to 
do it, but it worked...

Claudiu



From: lampei 
To: flexcoders@yahoogroups.com
Sent: Sunday, January 11, 2009 4:00:59 PM
Subject: [flexcoders] Re: Cairngorm and ChangeWatcher


That's actually the example I've been using (I thought it was 2006,
not 2007), but it's 2 years old, and my question still holds.  Is this
the best practice or is some other method being used with Cairngorm?

--- In flexcod...@yahoogro ups.com, claudiu ursica  wrote:
>
>
http://weblogs. macromedia. com/auhlmann/ archives/ 2007/02/creating 
_a_popu.html# more
> 
> This should give you some directions.. .
> 
> Claudiu
> 
> 
> 
> 
>  _ _ __
> From: lampei 
> To: flexcod...@yahoogro ups.com
> Sent: Saturday, January 10, 2009 1:34:25 AM
> Subject: [flexcoders] Cairngorm and ChangeWatcher
> 
> 
> I have begun tinkering around with various frameworks and thought I
> would start with Cairngorm.  I am refactoring a small application to
> use Cairngorm, but ran into a snag.  All of the examples I found just
> bound an item in the view to a property of the ModelLocator, and thus
> automagically updated the value when the property of the ModelLocator
> changed.  However, I had one item that is waiting for a response from
> a service, and needed to respond to that change (such as an error
> message), rather than just display the updated data that is returned.
> 
> I found an example that uses the ChangeWatcher class to watch the
> property on the ModelLocator.  This seemed to work fine, but I was
> wondering if this is still best practice, as the example I found was
> from 2006.
> 
> Thanks.
>




  

[flexcoders] Drag And Drop Tree

2009-01-18 Thread Claudiu Ursica
Hi I'm trying to implement the drag and drop functionality inside a
tree, dragging and dropping inside the same tree. However It seems
that I cannot drag and drop leaf nodes... When I handle enterDrag
event the item seems to be appearing only at debug time and gets lost
after that...

here is the code..


http://www.adobe.com/2006/mxml";
layout="absolute">







  







































 





so the code seems to be working when drag and dropping an folder but
not when dropping a leaf, I get a new Item with no label.
I have searched the archives for something similar and found only the
same issue posted twice by 2 different guys and no answers. So I
thought I'll have better luck...

TIA,
Claudiu



Re: [flexcoders] Drag And Drop Tree

2009-01-19 Thread claudiu ursica
Hi Alex,
I can move simple leafs from the root under a folder with no custom handlers, 
if the folder is open. However the thing is that I need to just put (maybe just 
copy not move) the item let's say for argument sake "" 
under "Inbox" folder. I cannot do that unless the "sent" is under some folder 
and move it with the folder, because otherwise the DragSource seeems to return 
an item but I cannot get the data from that item. So I end up dropping an empty 
item. However as said before If I move/copy a folder with items around it works 
fine ... The same happends with the drag complete handler, for just one item 
the drags source traces out to blank event though the length is 1.

Claudiu





From: Alex Harui 
To: "flexcoders@yahoogroups.com" 
Sent: Monday, January 19, 2009 7:47:53 AM
Subject: RE: [flexcoders] Drag And Drop Tree


Setting breakpoints in drag/drop generally doesn’t work because
you tend to release the mouse in order to dig through the debugging info and
when you resume the drag is cancelled.
 
Remove the custom drag event handlers and try with simple data
and see if it works.  We definitely tested drag/drop in Tree so basic cases
work.  One trick for Tree is that what happens on drop is different than in
List.  The node is removed before it is added in Tree, and sometimes that is 
done
in dragComplete handler instead of dragDropHandler
 
From:flexcod...@yahoogro ups.com [mailto:flexcoders@ yahoogroups. com] On 
Behalf Of Claudiu
Ursica
Sent: Sunday, January 18, 2009 9:59 AM
To: flexcod...@yahoogro ups.com
Subject: [flexcoders] Drag And Drop Tree
 
Hi I'm trying to implement the drag and drop
functionality inside a
tree, dragging and dropping inside the same tree. However It seems
that I cannot drag and drop leaf nodes... When I handle enterDrag
event the item seems to be appearing only at debug time and gets lost
after that...

here is the code..


http://www.adobe. com/2006/ mxml"
layout="absolute">






 







































 




so the code seems to be working when drag and dropping an folder but
not when dropping a leaf, I get a new Item with no label.
I have searched the archives for something similar and found only the
same issue posted twice by 2 different guys and no answers. So I
thought I'll have better luck...

TIA,
Claudiu 


  

Re: [flexcoders] Drag And Drop Tree

2009-01-19 Thread claudiu ursica
No custom event just the usual DragDrop events dispatched by the tree e.g. 
dragStart, dragOver, dragDrop, dragComplete...

Claudiu...





From: Sefi Ninio 
To: flexcoders@yahoogroups.com
Sent: Monday, January 19, 2009 11:25:35 AM
Subject: Re: [flexcoders] Drag And Drop Tree


Are you using a custom event?
And if so, did you implement the clone method?


2009/1/19 claudiu ursica 

Hi Alex,
I can move simple leafs from the root under a folder with no custom handlers, 
if the folder is open. However the thing is that I need to just put (maybe just 
copy not move) the item let's say for argument sake "" 
under "Inbox" folder. I cannot do that unless the "sent" is under some folder 
and move it with the folder, because otherwise the DragSource seeems to return 
an item but I cannot get the data from that item. So I end up dropping an empty 
item. However as said before If I move/copy a folder with items around it works 
fine ... The same happends with the drag complete handler, for just one item 
the drags source traces out to blank event though the length is 1.

Claudiu





From: Alex Harui 
To: "flexcod...@yahoogro ups.com" 
Sent: Monday, January 19, 2009 7:47:53 AM
Subject: RE: [flexcoders] Drag And Drop Tree


Setting breakpoints in drag/drop generally doesn't work because
you tend to release the mouse in order to dig through the debugging info and
when you resume the drag is cancelled.
 
Remove the custom drag event handlers and try with simple data
and see if it works.  We definitely tested drag/drop in Tree so basic cases
work.  One trick for Tree is that what happens on drop is different than in
List.  The node is removed before it is added in Tree, and sometimes that is 
done
in dragComplete handler instead of dragDropHandler
 
From:flexcod...@yahoogro ups.com [mailto:flexcoders@ yahoogroups. com] On 
Behalf Of Claudiu
Ursica

Sent: Sunday, January 18, 2009 9:59 AM
To: flexcod...@yahoogro ups.com

Subject: [flexcoders] Drag And Drop Tree 
 
Hi I'm trying to implement the drag and drop
functionality inside a
tree, dragging and dropping inside the same tree. However It seems
that I cannot drag and drop leaf nodes... When I handle enterDrag
event the item seems to be appearing only at debug time and gets lost
after that...

here is the code..


http://www.adobe. com/2006/ mxml"
layout="absolute">






 







































 




so the code seems to be working when drag and dropping an folder but
not when dropping a leaf, I get a new Item with no label.
I have searched the archives for something similar and found only the
same issue posted twice by 2 different guys and no answers. So I
thought I'll have better luck...

TIA,
Claudiu 
 



  

Re: [flexcoders] Drag And Drop Tree

2009-01-19 Thread claudiu ursica
It can be moved around but cannot be dropped into a folder (branch) unless the 
folder is open. I was adding those handlers, so that i can drop item/items 
inside a closed node... And it works for branches but not for leaf nodes ... 

Setting breakpoints in drag/drop
generally doesn’t work because you tend to release the mouse in order to dig
through the debugging info and when you resume the drag is cancelled. 

The funny thing is that the accurate data seems to be there at a certain time 
when debugged, and i tried to store it in a private member of the component and 
that works fine for branches, it seems that it just looses the data it probably 
when dragging over a branch or I don''t know, but the length is still one so I 
end up in adding an empty leaf. That also happens for the dragComplete handler. 
Still adding an empty leaf...







From: Alex Harui 
To: "flexcoders@yahoogroups.com" 
Sent: Monday, January 19, 2009 11:01:07 PM
Subject: RE: [flexcoders] Drag And Drop Tree


If I remove your handlers, I can move Sent just fine.  In your
handler the following line is suspicious:
 
var xml : XML = new XML(items);
 
because items is an array.  Use XML.toXMLString( ) to make sure
you’re trying to put in valid data.
 
From:flexcod...@yahoogro ups.com [mailto:flexcoders@ yahoogroups. com] On 
Behalf Of claudiu
ursica
Sent: Monday, January 19, 2009 12:30 AM
To: flexcod...@yahoogro ups.com
Subject: Re: [flexcoders] Drag And Drop Tree
 
Hi
Alex,
I can move simple leafs from the root under a folder with no custom handlers,
if the folder is open. However the thing is that I need to just put (maybe just
copy not move) the item let's say for argument sake "" under "Inbox" folder. I
cannot do that unless the "sent" is under some folder and move
it with the folder, because otherwise the DragSource seeems to return an item
but I cannot get the data from that item. So I end up dropping an empty item.
However as said before If I move/copy a folder with items around it works fine
... The same happends with the drag complete handler, for just one item the
drags source traces out to blank event though the length is 1.

Claudiu
 


 
From:Alex Harui 
To: "flexcod...@yahoogro ups.com" 
Sent: Monday, January 19, 2009 7:47:53 AM
Subject: RE: [flexcoders] Drag And Drop Tree
Setting breakpoints in drag/drop
generally doesn’t work because you tend to release the mouse in order to dig
through the debugging info and when you resume the drag is cancelled.
 
Remove the custom drag event handlers
and try with simple data and see if it works.  We definitely tested
drag/drop in Tree so basic cases work.  One trick for Tree is that what
happens on drop is different than in List.  The node is removed before it
is added in Tree, and sometimes that is done in dragComplete handler instead of
dragDropHandler
 
From:flexcod...@yahoogro ups.com [mailto:flexcoders@ yahoogroups. com] On 
Behalf Of Claudiu Ursica
Sent: Sunday, January 18, 2009 9:59 AM
To: flexcod...@yahoogro ups.com
Subject: [flexcoders] Drag And Drop Tree
 
Hi I'm trying to implement the drag and drop functionality inside a
tree, dragging and dropping inside the same tree. However It seems
that I cannot drag and drop leaf nodes... When I handle enterDrag
event the item seems to be appearing only at debug time and gets lost
after that...

here is the code..


http://www.adobe. com/2006/ mxml"
layout="absolute">






 







































 




so the code seems to be working when drag and dropping an folder but
not when dropping a leaf, I get a new Item with no label.
I have searched the archives for something similar and found only the
same issue posted twice by 2 different guys and no answers. So I
thought I'll have better luck...

TIA,
Claudiu
  


  

Re: [flexcoders] Centered preloader that displays while image is loading

2009-01-21 Thread claudiu ursica
put a progress bar into your custom image component, then you liste to ther 
progress event and and adjust pthe progress property accordingly.

HTH,
Claudiu





From: stinasius 
To: flexcoders@yahoogroups.com
Sent: Wednesday, January 21, 2009 12:41:02 PM
Subject: [flexcoders] Centered preloader that displays while image is loading


how can i show a preloader while an image?




  

Re: [flexcoders] Flex calling Java/Apache Axis web service

2009-01-21 Thread claudiu ursica
Do you have a policy acess specified on the linux machine?

Claudiu





From: paramjit.parmar 
To: flexcoders@yahoogroups.com
Sent: Wednesday, January 21, 2009 3:20:19 PM
Subject: [flexcoders] Flex calling Java/Apache Axis web service


Hi All,
I have a Java/Apache axis web service which sits on Linux box. I am 
able to call this fine through a Flex .swf file on Windows. However 
when I copythe same swf file to the Linux server I get the error posted 
below. Bar the web service, the rest of the app works the same on both 
platforms. Any pointers much appreciated. I am using Tomcat web server.

[FaultEvent fault=[RPC Fault faultString= "Security error accessing url" 
faultCode="Channel. Security. Error" faultDetail= "Destination: 
DefaultHTTP" ] messageId="13005BD7 -59AB-B3DA- B850-F95031390FF 7" 
type="fault" bubbles=false cancelable=true eventPhase=2]




  

Re: [flexcoders] Re: Flex calling Java/Apache Axis web service

2009-01-22 Thread claudiu ursica
Hi Param,
It is definetly some access issue, but since you have a cross domain .xml it 
should be working. Try to debug somehow to a file if you can the app to see if 
it traces out some access violation and then  you'll be sure. You can see 
exactly from where it is trying to load the crossdomain file then and check it 
in the browser if the link works... We have project deployed and linux boxex 
with policy files but that is done by a diffrent team so I don't know that much 
about  linux boxex, however the i included this line in config.xml 
 to be compliant 
with the new FP policies...
Sorry for not being able to help you any further,
Claudiu





From: paramjit.parmar 
To: flexcoders@yahoogroups.com
Sent: Thursday, January 22, 2009 6:27:01 AM
Subject: [flexcoders] Re: Flex calling Java/Apache Axis web service


Hi Claudiu
I do have a crossdomain. xml at ROOT. Contents as pasted below. The ip 
address of the Linux server is correct. Any further advice much 
appreciated.
Thanks
Param

/var/lib/tomcat6/ webapps/ROOT# cat crossdomain. xml





--- In flexcod...@yahoogro ups.com, claudiu ursica  
wrote:
>
> Do you have a policy acess specified on the linux machine?
> 
> Claudiu
> 
> 
> 
> 
>  _ _ __
> From: paramjit.parmar 
> To: flexcod...@yahoogro ups.com
> Sent: Wednesday, January 21, 2009 3:20:19 PM
> Subject: [flexcoders] Flex calling Java/Apache Axis web service
> 
> 
> Hi All,
> I have a Java/Apache axis web service which sits on Linux box. I am 
> able to call this fine through a Flex .swf file on Windows. However 
> when I copythe same swf file to the Linux server I get the error 
posted 
> below. Bar the web service, the rest of the app works the same on 
both 
> platforms. Any pointers much appreciated. I am using Tomcat web 
server.
> 
> [FaultEvent fault=[RPC Fault faultString= "Security error accessing 
url" 
> faultCode="Channel. Security. Error" faultDetail= "Destination: 
> DefaultHTTP" ] messageId="13005BD7 -59AB-B3DA- B850-F95031390FF 7" 
> type="fault" bubbles=false cancelable=true eventPhase=2]
>




  

Re: [flexcoders] E4X help?

2009-02-15 Thread claudiu ursica
node.da...@key == "type" ? If U want both values you should iterate ...
Claudiu





From: flexaustin 
To: flexcoders@yahoogroups.com
Sent: Monday, February 16, 2009 1:58:46 AM
Subject: [flexcoders] E4X help?


Is it possible to get the value of "type" from this XML?


Ed< /data>
M< /data>

−

Christia an
M< /data>


So in this example end up with M for both?


   


  

[flexcoders] Re: Question for Cairngorm with Flex Module?

2009-02-21 Thread Claudiu Ursica
--- In flexcoders@yahoogroups.com, "markflex2007" 
wrote:
>
> Hi,
> 
> I build a Flex Module with cairngorm ,I load the module in main
> application and I need to load it many times.
> 
> it works fine when I load the module at first time but I get error
> when I load it again.
> 
> The error message is : "Only one ServiceLocator instance can be
> instantiated"
> 
> Do you have a idea to fix this.Thanks for help.
> 
> 
> Mark
>

The ServiceLocator is a singleton as you probably already know, and if
by any chance you have an instance in the shell app and another one in
the module you'll get that error. You can put your service instance in
the shell ServiceLocator and inject it into module when when the Ready
event fires. 

If what i said is not the case with your app, then post some code and
I'll have a look...

Cheers,
Claudiu



Re: [flexcoders] Accessing parentDocument using custom events?

2009-02-23 Thread claudiu ursica
First of all why do you need to do this?

I'm not sure I understand exactly what you are trying to do but you can inject 
data into item renderer form parent document and access that data inside the 
renderer.

Or you can hold references to your component (visual component) inside a model 
class dispatch an event which will be handled by a command and inside that 
command get the reference to that visual component. 

HTH,
Claudiu





From: oneworld95 
To: flexcoders@yahoogroups.com
Sent: Monday, February 23, 2009 10:05:15 PM
Subject: [flexcoders] Accessing parentDocument using custom events?


Is it possible to have a custom component in an itemRenderer access a
variable in the parentDocument using a custom event? Not sure how to
do this so I'm looking for an example. 


   


  

Re: [flexcoders] Hie

2009-02-27 Thread claudiu ursica
My on the fly thought on this would be have an item renderer for the repeater 
(eve though I'd go with a List for performance reasons), to override the data 
setter in your item renderer and check there if the value is valid leave the 
text alone or put it black and red if invalid. }>



This above code shows me all in black as I have not applied this empStatus to 
format. So how to do that?



Thankx and Regards

Vik
Founder
www.sakshum. com
www.sakshum. blogspot. com

   


  

Re: [flexcoders] updating an item renderer

2009-03-02 Thread claudiu ursica
The way I see it all the the item renderer is there only for display purposes. 
All the sock retrievals goes in to the provider, rr I mean the model which 
feeds the list provider. If you use binding the list will automatically display 
that changes. Now here-s something we do to avoid object creation... We use an 
array for fast retieval on the element and an array collection for binding ...
In your case that would be translated into something like a stocks collection 
manager which has an stocksArray : Array and stocksAC: ArrayColection. U use an 
id to identify the element in the collection and that is unique ... when a 
stock comes in if it's new u add it, otherwise just update an existing one ... 
The rest is the magic of binding ...

public function addStock(stock : Stock) : void
{
if (this._stocksArray.id + "_"] == null)
{
this._stocksArray[stock.id + "_"] = stock;
this._stocksArrayCollection.addItem(stock);
}
else 
{
Stock(this._stocksArray[stock.id + "_"]).update(stock);
}
}

the update function shoul be in the Stock class and jus update stock 
properties...

HTH,
Claudiu

Probably you have an answer by now form other peeps but I just started readimng 
tehm emails 





From: flexrookie 
To: flexcoders@yahoogroups.com
Sent: Sunday, March 1, 2009 3:58:30 AM
Subject: [flexcoders] updating an item renderer


hi list, first post...

i have an architectural question about datatproviders and
itemrenderers that i'll pose with a canonical example.

suppose i have an array of StockInfo objects that is populated by a
3rd party library. each StockInfo object dispatches UPDATE events when
a stock price changes. i want to render the prices in HorizontalList
with a custom renderer.

here's the general application shell:

 = 

http://www.adobe. com/2006/ mxml"
layout="absolute"
applicationComplete ="applicationCom pleteListener( event)">




 = 

i need to wire the stocks array to the list. of course, given that i
already have an array of StockInfo objects, it's tempting to make an
ArrayCollection wrapper that gives direct access to the StockInfo
objects. e.g.,

provider = new ArrayCollection( );
provider.addItem( {stockInfo: someStockInfoObj ect});

then the StockInfoRenderer could register for UPDATE events and redraw
when the event occurs. but i'm hesitant about that approach. if i went
that route,

1) within the StockInfoRenderer, where would i register for the UPDATE
event? in commitProperties( )?
2) within the StockInfoRenderer, where would i *remove* the UPDATE
listener?
3) given that renderers are reused, are there issues with synching, or
with stranded listeners causing memory build-up?

more generally, what's the right way to wire my list to the stocks
array? it feels like i might be forced to handle UPDATE for each
StockInfo object, and write a 'price' variable into a data provider.
e.g., 

provider.getItemAt( i).price = value;
provider.itemUpdate d(provider. getItemAt( i), "price");

seems a shame, given that i already have an array of StockInfo
objects. the above two lines presuppose that i'm going to hunt for the
item index every time a stock price changes. : (

another general question, do i even need the itemUpdate() call, or is
that part automated?

thanks for any advice!

flexrookie


   


  

Re: [flexcoders] Re: Modules Communication

2009-03-03 Thread claudiu ursica
You should probably have ca comunication manager something like a central event 
dispatcher (I believe the Mate framework already does this but i might be 
mistaking) and register panels within that scope. so when a panel fires an 
event the other listening panels check if the event is adressed to them and 
actually consume catch that event...

there was some guy doing a prof of concept for this google for ALON desing 
pattern ...

HTH, 
Claudiu





From: thelordsince1984 
To: flexcoders@yahoogroups.com
Sent: Tuesday, March 3, 2009 10:53:49 AM
Subject: [flexcoders] Re: Modules Communication


--- In flexcod...@yahoogro ups.com, Guy Morton  wrote:
>
> Have you read the section "Using interfaces for module communication" 
> in the docs? That's been working for me.
>

thanks for the reply..

For Guy Morton...

i've read it but modules are created at runtime so i would have a
maneger that controls communication over modules.is it true?

For Alex Harui

how can i achieve the commuication between modules..for example a
module dispatch an event...the event is catch by a manager and then
fires to the rigth destination. ..rember that i have an
application. ..it contains panels and each panel could contain a module...

thanks again

Regards Lorenzo


   


  

Re: [flexcoders] Question: Strategies for compiling individual modules into SWCs

2009-03-03 Thread claudiu ursica
Try with ant or maven, have to manually write build scripts though...


HTH,
Claudiu



From: David Adams 
To: flexcoders@yahoogroups.com
Sent: Friday, February 27, 2009 5:23:56 AM
Subject: [flexcoders] Question: Strategies for compiling individual modules 
into SWCs


I'm new to Flex so apologies in advance for what is probably a basic
question. I've been working on a code generator that spits out
MXML/ActionScript files and dumps them into a directory. For
simplicities sake, imagine that I'm dumping out three MXML files and
the goal is to produce an individual SWC for each. Is there any way to
do this using FlexBuilder short of creating an individual library
project for each module? I'd prefer to have a single project for all
of my generated modules yet have each compiled individually. At a
guess:

-- Is this not really possible?
-- Is there some kind of compiler setting or project property I can exploit?
-- Is this the sort of thing where I should update my code generator
to interact with the command-line compiler instead of messing with
FlexBuilder? (I'd rather not go this route, honestly.)
-- Is this what ANT is for?

Any strategies or suggestions welcome. And, if I've stated my
question/problem poorly, I'll be happy to try and clarify.

Thanks in advance for any help,

 - - - --
David Adams
Wallaga Lake 2546 NSW
 - - - --

   


  

[flexcoders] Module unload GC

2009-03-05 Thread Claudiu Ursica
Hi,
I'm using a module in my app. And I'm profiling the app to see if unloading 
cleans after itself... The thing is the first time I unload nothing happens all 
the instances are still there in the Profiler. Now if I load the module again, 
the memory increases and the insatnces no. doubles. However when I unload the 
second time, the cleaning happens and I'm getting the memory and instances no 
from before the load. Is this normal, it looks to me like I'm having a module 
in there all the time after the first load... I'm pretty sure I do my internal 
cleaning OK before unloading the module, fact proved by the second, third forth 
load/unload 

Has anyone bumped into this? 
How reliable is the Profiler on this?

Any input is appreciated.

TIA,
Claudiu

  




Re: [flexcoders] Module unload GC

2009-03-05 Thread claudiu ursica
I read this too, however when watching in profiler the gc runs a removes a set 
of the instances, the thing that bothers me is that after first load/unload the 
memory looks like the module is there. After the second load looks like 2 
modules are load I get duplicate instances ... After the second unload and 
forcing running gc a few times from profilet a set of instances is collected, 
but i still have the memory looking like I have one module in there. I don't 
get it how come that on set of instances are removed and one is there for 
good... It seems there is no way to see if my cleaning is actually hapenning 
... One could say is happening since the second, third, forth load/unload are 
actually cleaned but there's still a set of instances in the memory ... 







From: Nate Beck 
To: flexcoders@yahoogroups.com
Sent: Thursday, March 5, 2009 7:55:01 PM
Subject: Re: [flexcoders] Module unload GC


Garbage Collection happens when it needs to happen.  You have no control over 
it.  This is from Grant Skinner's blog:


Deferred GC and Indeterminacy
A
*very* important thing to understand about the Garbage Collector in FP9
is that it's operations are deferred. Your objects will not be removed
immediately when all active references are deleted, instead they will
be removed at some indeterminate time in the future (from a developer
standpoint). The GC uses a set of heuristics
that look at RAM allocation and the size of the memory stack (among
other things) to determine when to run. As a developer, you must accept
that fact that you will have no way of knowing when (or even if) your
inactive objects will get deallocated. You must also be aware that
inactive objects will continue to execute indefinitely (until the GC 
deallocates it), so code will keep running (ex. enterFrames) , sounds
will keep playing, loads will keep happening, events will keep firing,
etc. 
It's very important to remember that you have no control over when
your objects will be deallocated, so you must make them as inert as
possible when you are finished with them. Strategies to manage this
will be the focus for a future article. 


On Thu, Mar 5, 2009 at 3:58 AM, Claudiu Ursica  wrote:

Hi,
I'm using a module in my app. And I'm profiling the app to see if unloading 
cleans after itself... The thing is the first time I unload nothing happens all 
the instances are still there in the Profiler. Now if I load the module again, 
the memory increases and the insatnces no. doubles. However when I unload the 
second time, the cleaning happens and I'm getting the memory and instances no 
from before the load. Is this normal, it looks to me like I'm having a module 
in there all the time after the first load... I'm pretty sure I do my internal 
cleaning OK before unloading the module, fact proved by the second, third forth 
load/unload 

Has anyone bumped into this? 
How reliable is the Profiler on this?

Any input is appreciated.

TIA,
Claudiu




-- 

Cheers,
Nate
 - - - -
http://blog. natebeck. net



   


  

Re: [flexcoders] Module unload GC

2009-03-05 Thread claudiu ursica
I'll try that first thing in the morning...
For now I'm loading the same module, but in the future there will be more 
modules, however since we only have one now and still working on it we have to 
test with one module... The thing I fear the most if that the same thing will 
happen for different modules, and then I'll have a serious memory leak. The 
modules will be quite complex with lots of functionality and animations 
(diffren games loaded on the same shell), that's why cleaning is so important...

I was going to duplicate the module into another project to see if that still 
happens... Right now I'm nullifying manually the url of the module when 
unloading but whi knows what happens behind the scenes...









From: Nate Beck 
To: flexcoders@yahoogroups.com
Sent: Thursday, March 5, 2009 8:16:52 PM
Subject: Re: [flexcoders] Module unload GC


Well if we're talking about modules...

If you're loading the same module over and over again that might be the 
problem... A while back I had to modify ModuleLoader and while I was in the 
code I seem to remember it has some caching built into it.  So it may be 
possible that ModuleLoader is holding on to a reference of a module.

I got around the caching issue when loading the same module over and over again 
by appending a random number to the loaded module.  (ex: myModule.swf? 
uid=123456789) .

The ModuleLoader stuff I was working on was back in 2.0.1... so it might be 
very different now.

Hope this helps.


On Thu, Mar 5, 2009 at 10:08 AM, claudiu ursica  wrote:

I read this too, however when watching in profiler the gc runs a removes a set 
of the instances, the thing that bothers me is that after first load/unload the 
memory looks like the module is there. After the second load looks like 2 
modules are load I get duplicate instances ... After the second unload and 
forcing running gc a few times from profilet a set of instances is collected, 
but i still have the memory looking like I have one module in there. I don't 
get it how come that on set of instances are removed and one is there for 
good... It seems there is no way to see if my cleaning is actually hapenning 
... One could say is happening since the second, third, forth load/unload are 
actually cleaned but there's still a set of instances in the memory ... 







 From: Nate Beck 
To: flexcod...@yahoogro ups.com
Sent: Thursday, March 5, 2009 7:55:01 PM
Subject: Re: [flexcoders] Module unload GC


Garbage Collection happens when it needs to happen.  You have no control over 
it.  This is from Grant Skinner's blog:


Deferred GC and Indeterminacy
A
*very* important thing to understand about the Garbage Collector in FP9
is that it's operations are deferred. Your objects will not be removed
immediately when all active references are deleted, instead they will
be removed at some indeterminate time in the future (from a developer
standpoint). The GC uses a set of heuristics
that look at RAM allocation and the size of the memory stack (among
other things) to determine when to run. As a developer, you must accept
that fact that you will have no way of knowing when (or even if) your
inactive objects will get deallocated. You must also be aware that
inactive objects will continue to execute indefinitely (until the GC 
deallocates it), so code will keep running (ex. enterFrames) , sounds
will keep playing, loads will keep happening, events will keep firing,
etc. 
It's very important to remember that you have no control over when
your objects will be deallocated, so you must make them as inert as
possible when you are finished with them. Strategies to manage this
will be the focus for a future article. 


On Thu, Mar 5, 2009 at 3:58 AM, Claudiu Ursica  wrote:

Hi,
I'm using a module in my app. And I'm profiling the app to see if unloading 
cleans after itself... The thing is the first time I unload nothing happens all 
the instances are still there in the Profiler. Now if I load the module again, 
the memory increases and the insatnces no. doubles. However when I unload the 
second time, the cleaning happens and I'm getting the memory and instances no 
from before the load. Is this normal, it looks to me like I'm having a module 
in there all the time after the first load... I'm pretty sure I do my internal 
cleaning OK before unloading the module, fact proved by the second, third forth 
load/unload 

Has anyone bumped into this? 
How reliable is the Profiler on this?

Any input is appreciated.

TIA,
Claudiu





-- 

Cheers,
Nate
 - - - -
http://blog. natebeck. net






-- 

Cheers,
Nate
 - - - -
http://blog. natebeck. net



   


  

Re: [flexcoders] Module unload GC

2009-03-06 Thread claudiu ursica


10x Alex, it turns out it was an embedded CSS issue after all, I commented that 
out and now it cleans beautifully... And the GC actually comes in very quickly.
I;ll probably load the CSS at run time ...

Cheers,
Claudiu




From: Alex Harui 
To: "flexcoders@yahoogroups.com" 
Sent: Thursday, March 5, 2009 9:01:37 PM
Subject: RE: [flexcoders] Module unload GC


Modules will unload when there are no longer any references to
the classes or objects in a module.  There is a cache, but it uses weak
references and will release the module when using the gc button in the
profiler.  The browser caches module SWFs but that won’t affect this issue. 
Nate’s solution sounded like the solution to the problem where you update a
module on the server and want to load the new one.
 
If a module brings in a component that hasn’t been loaded
before, usually it brings in a CSSStyleDeclaration for it as well which gets
registered with the central StyleManager and pins the module.  You can check
the id in the id column to see if the module that is pinned is the first one
loaded.
 
Alex Harui
Flex SDK Developer
Adobe
Systems Inc.
Blog: http://blogs. adobe.com/ aharui
 
From:flexcod...@yahoogro ups.com [mailto:flexcoders@ yahoogroups. com] On 
Behalf Of claudiu
ursica
Sent: Thursday, March 05, 2009 10:26 AM
To: flexcod...@yahoogro ups.com
Subject: Re: [flexcoders] Module unload GC
 
I'll try that first thing in the morning...
For now I'm loading the same module, but in the future there will be more
modules, however since we only have one now and still working on it we have to
test with one module... The thing I fear the most if that the same thing will
happen for different modules, and then I'll have a serious memory leak. The
modules will be quite complex with lots of functionality and animations
(diffren games loaded on the same shell), that's why cleaning is so
important...

I was going to duplicate the module into another project to see if that still
happens... Right now I'm nullifying manually the url of the module when
unloading but whi knows what happens behind the scenes...




 


 
From:Nate Beck 
To: flexcod...@yahoogro ups.com
Sent: Thursday, March 5, 2009 8:16:52 PM
Subject: Re: [flexcoders] Module unload GC
Well if we're talking about modules...

If you're loading the same module over and over again that might be the
problem... A while back I had to modify ModuleLoader and while I was in the
code I seem to remember it has some caching built into it.  So it may be
possible that ModuleLoader is holding on to a reference of a module.

I got around the caching issue when loading the same module over and over again
by appending a random number to the loaded module.  (ex: myModule.swf?
uid=123456789) .

The ModuleLoader stuff I was working on was back in 2.0.1... so it might be
very different now.

Hope this helps.
On Thu, Mar 5, 2009 at 10:08 AM, claudiu ursica 
wrote:
I read this too,
however when watching in profiler the gc runs a removes a set of the instances,
the thing that bothers me is that after first load/unload the memory looks like
the module is there. After the second load looks like 2 modules are load I get
duplicate instances ... After the second unload and forcing running gc a few
times from profilet a set of instances is collected, but i still have the
memory looking like I have one module in there. I don't get it how come that on
set of instances are removed and one is there for good... It seems there is no 
way
to see if my cleaning is actually hapenning ... One could say is happening
since the second, third, forth load/unload are actually cleaned but there's
still a set of instances in the memory ... 


 


 
From:Nate Beck 
To: flexcod...@yahoogro
ups.com
Sent: Thursday, March 5, 2009 7:55:01 PM
Subject: Re: [flexcoders] Module unload GC
Garbage Collection happens
when it needs to happen.  You have no control over it.  This is from
Grant Skinner's blog:
Deferred GC and Indeterminacy
A *very* important thing to understand about the Garbage Collector in FP9 is
that it's operations are deferred. Your objects will not be removed immediately
when all active references are deleted, instead they will be removed at some
indeterminate time in the future (from a developer standpoint). The GC uses a
set of heuristics that look at RAM allocation and the size of the memory stack
(among other things) to determine when to run. As a developer, you must accept
that fact that you will have no way of knowing when (or even if) your inactive
objects will get deallocated. You must also be aware that inactive objects will
continue to execute indefinitely (until the GC deallocates it), so code will
keep running (ex. enterFrames) , sounds will keep playing, loads will keep
happening, events will keep firing, etc. 
It's very important to remember that you have n

Re: [flexcoders] Bindable Singleton is not propogating the changes of its proprties.

2009-03-09 Thread claudiu ursica
Can you post some code ...
Usually you have to bind on AC item if not using list or repeaters or grids ... 
Or listen to the collection change event manually ...

However for Boolean and other primitive types the bindings should fire right 
away...

Claudiu





From: alex 
To: flexcoders@yahoogroups.com
Sent: Monday, March 9, 2009 2:49:14 AM
Subject: [flexcoders] Bindable Singleton is not propogating the changes of its 
proprties.


I have a Bindable Singleton class were I access from diffrent components. The 
class has several properties ArrayCollection, Boolean.. . etc .
I assumed that any change in then properties will propogate to all the 
components that use the Singleton class , but from what I see it is not the 
case. 
Why so ? Should I use ChangeWatcher then ?

Thank you.


   


  

Re: [flexcoders] Flex Interview Questions

2009-03-09 Thread claudiu ursica
There was a topic like this a few moths ago, check the archives .. you'll find 
some nice stuff in there ...

Claudiu





From: Shyam Prasad 
To: flexcoders@yahoogroups.com
Sent: Sunday, March 8, 2009 5:47:27 PM
Subject: [flexcoders] Flex Interview Questions



Hi,

Can anyone provide any website for the Interview Questions  for Flex ?

Thanks

Prasad


   


  

Re: [flexcoders] Sprite doubleclick

2009-03-09 Thread claudiu ursica
In theory you should be able to child.addEventListener(MouseEvent.click, 
handler) after doing 

sprite.addChild(child), so you use the child for listening instead of the 
parent sprite...

He child should be able to handle the clicks ...

HTH,
Claudiu





From: flexaustin 
To: flexcoders@yahoogroups.com
Sent: Monday, March 9, 2009 8:03:18 AM
Subject: [flexcoders] Sprite doubleclick


So if you have a sprite, say a circle in shape, and assign a doubleclick event 
handler to it.  Then you add a child to the circle sprite, thus covering up the 
circle sprite. How do you get the the top sprite to allow the underneath 
(circle sprite) to hear the doubleclick?

I have set doubleclick enabled for both, but I think the issue is the top 
sprite is not letting the lower sprite hear anything?

TIA, J


   


  

Re: [flexcoders] Array of objects

2009-03-13 Thread claudiu ursica
[ArrayElementType("com.blah.blah.YourClassName")]
publica var ar:Array = new Array();

C





From: christophe_jacquelin 
To: flexcoders@yahoogroups.com
Sent: Friday, March 13, 2009 10:46:55 AM
Subject: [flexcoders] Array of objects


Hello,

How to declare an array of n Objects of the class myClass ? How did we 
indicates the type of the object to the array ?

Thank you,
Christophe, 


   


  

Re: [flexcoders] Item Rendererer Question

2009-03-17 Thread claudiu ursica
Can you be more specific? Generally speaking IR are reused so there is a high 
probability that you still have them in there. In theory you should be 
filtering the list data provider so that the list will display whatever the 
provider feeds..

Claudiu





From: djhatrick 
To: flexcoders@yahoogroups.com
Sent: Tuesday, March 17, 2009 3:18:20 PM
Subject: [flexcoders] Item Rendererer Question


I have custom ItemRenderers, after a filter Function, it looks like my 
itemRenderers are not being cleared out, I have double the items in my list.  
How do I make sure they are reset and their visual content is removed after I 
perform a refresh()

Thanks,
Patrick


   


  

Re: [flexcoders] round timer

2009-03-20 Thread claudiu ursica
Hi, unfortunately I cannot give you any code since is company property. However 
we have something similar. It was designed in flash (some circular paths and 
masks will do the trick) and exported as a flex asset. This is embedded in a 
flex component which update the timer via a binding. The animation goes for 100 
ticks an the input can be simulated with a timer or you can get input form 
server or wherever...   So every tick change (1,2,3 ...) triggers a 
goToAndStop(tickNo) inside the flash round timer and the animation updates 
smoothly...

HTH somehow,
Claudiu





From: makeflex 
To: flexcoders@yahoogroups.com
Sent: Friday, March 20, 2009 1:55:12 AM
Subject: [flexcoders] round timer


I'm looking for either a component or source code for a circle timer. something 
similar to this http://flashden. net/item/ adjustable- circle-timer- 
in-casinostyle/ 10304. That one won't work for me because it's simply to 
jagged. Can anyone point me in the right direction? 


   


  

Re: [flexcoders] Modules, Cairngorm and Garbage Collection

2009-03-24 Thread claudiu ursica
Hi, why do you bind module to the model locator?

If by any chance you have embedded CSS in the module it won't garbage collect 
...

Claudiu





From: "Battershall, Jeff" 
To: flexcoders@yahoogroups.com
Sent: Tuesday, March 24, 2009 5:37:58 PM
Subject: [flexcoders] Modules, Cairngorm and Garbage Collection


I've been working on optimizing an AIR application I'm currently working
on that utilizes modules. In the modules there are controls bound to
ModelLocator data items.

What I'm seeing during profiling that removing a module from the display
list doesn't seem to result in the module being GC'ed. I'm suspecting
binding between the ModelLocator and the module's controls are causing
the behavior. 

Has anyone seen this and can suggest approaches to address this?

Jeff Battershall
Application Architect
Dow Jones Indexes
jeff.battershall@ dowjones. com
(609) 520-5637 (p)
(484) 477-9900 (c)

   


  

Re: [flexcoders] Using cairngorm for "push" events

2009-03-24 Thread claudiu ursica
First thing first it depends how fast you want to poll your server for data. As 
you probably know the browser only allows you to have 2 connections ... You 
might run into issues if your polling again and again in seconds. We have 
something similar and decided to make our own ServiceManager class which uses 2 
HTTPService instances and manages  the concurrency for the 2 connections. So 
when you make a request the service manager schedules that request and when it 
has the service avalable is doing the request ... We are still using commands, 
but not delegates anymore. The HTTPService handles the results and parses the 
data through some unmarshaller classes into the model ... It is not the 
greatest separtion of concerns but since we are polling the hell out of the 
server we hit serveral tomeouts due to bad request schedulling ...

Traditionaly with cairngorm after you get the data dreom the server you 
populate the model and update the view through bindings. You can hav an message 
mechanism and trigger it directly form the model, or dispatching events handled 
by commands. As far as the indicator goes the same thing ... use a preloader 
with alternate set to true inside the message view or somewhere  show when 
make request, hide when result or fault ...

The topic is 2 large to tackle in 2 paragraphs but if you need further info 
senf a private msg ...

Cheers,
Claudiu



From: Osman Ullah 
To: flexcoders@yahoogroups.com
Sent: Tuesday, March 24, 2009 4:03:22 PM
Subject: [flexcoders] Using cairngorm for "push" events


I am using cairngorm on my current project and I have run into a couple issues 
which I am having trouble dealing with through Cairngorm. Hopefully someone can 
help.

1) I have an event loop which is polling my web service for events. Where would 
be the best place to run this event loop and what would be a good way of 
notifying the view to "do something"? There might be very little data, so it 
might be something like popping an alert or popping a toast notification. 
..it's not something I can do through databinding and cairngorm seems to throw 
out the whole concept of the model notifying the view through events (this 
design decision is something I don't really understand). 

2) I want to make a request, and show a loading indicator while the request is 
pending, and then show a confirmation with the result of hte request. Similar 
requests are being made in different parts of the application, but they all 
consist of making the request, showing a wait indicator, and then showing a 
confirmation. Again, some suggestions on how to handle this would be 
appreciated.

Thanks


   


  

Re: [flexcoders] Modules, Cairngorm and Garbage Collection

2009-03-24 Thread claudiu ursica
I'm loading module via a command, so that it can be loaded form various 
places... So far I have used a Module Loader... And I use interfaces foe 
communicating with the modules and the shell. I don't know how you work with 
module but you can inject your pieces of data from the mx:app in the loader and 
into module when the as soon as the ready event fires. U can also use 
BindingUtils to set bindings which in turn returns a change watcher. use that 
to call unwatch upon when module unloads and so you make sure you performed 
celanup and unbinding before unload ...

Claudiu





From: "Battershall, Jeff" 
To: flexcoders@yahoogroups.com
Sent: Tuesday, March 24, 2009 10:47:22 PM
Subject: RE: [flexcoders] Modules, Cairngorm and Garbage Collection


Thanks 
Pedro,
 
As I 
said in my previous post, I'm also wondering about the effect of a module's 
component consuming a dataprovider via binding to a singleton object and 
the possibility of that preventing GC.  I guess this touches on the whole 
issue of best practices of using ModelLocator with modules.  PureMVC has 
it's 'Pipes' utility to inject data objects into a module, but I'm using 
Cairngorm and I'm wondering how something similar could be achieved with that 
framework. 
 
Jeff
-Original Message-
From: flexcod...@yahoogro ups.com [mailto:flexcoders@ yahoogroups. com] On 
Behalf Of Pedro Sena
Sent: Tuesday, March 24, 2009 3:06 PM
To: flexcod...@yahoogro ups.com
Subject: Re: [flexcoders] Modules,  Cairngorm and Garbage Collection

The GC is not called when  the component is remove from the screen.

Most people think this occurs,  but it's not truth.

The GC is called when its required, but WHEN it is  required is another point.

If you are using just a small piece of your  available mamory, don't expect the 
GC to be  called.

Regards,

PS


On Tue, Mar 24, 2009 at 2:09 PM, claudiu ursica  wrote:

Hi, why do you bind module to the model locator?

If by any  chance you have embedded CSS in the module it won't garbage collect  
...

Claudiu





 From: "Battershall, Jeff"  
To: flexcod...@yahoogro ups.com
Sent: Tuesday, March 24, 2009 5:37:58  PM
Subject: [flexcoders]  Modules, Cairngorm and Garbage Collection
 


I've been working on optimizing an AIR application I'm currently  working
on that utilizes modules. In the modules there are controls bound  to
ModelLocator data items.

What I'm seeing during profiling that  removing a module from the display
list doesn't seem to result in the  module being GC'ed. I'm suspecting
binding between the ModelLocator and  the module's controls are causing
the behavior. 

Has anyone seen  this and can suggest approaches to address this?

Jeff  Battershall
Application Architect
Dow Jones Indexes
jeff.battershall@ dowjones. com
(609) 520-5637  (p)
(484) 477-9900 (c)




-- 
/**
* Pedro Sena
* Systems Architect
* Sun Certified Java  Programmer 
* Sun Certified Web Component Developer
*/

   


  

Re: [flexcoders] Korean characters in calendar control

2009-03-25 Thread claudiu ursica
It happened to me when I was playing with air but I didn't dig it out any 
further cause I was just doing some test example ... but if anyone knows some 
more about the topic I'd be interested to find out too ...

C





From: Steve Brownlee 
To: flexcoders@yahoogroups.com
Sent: Wednesday, March 25, 2009 5:33:27 PM
Subject: [flexcoders] Korean characters in calendar control


I've had a calendar control in a simple app for about 9 months now.  For some 
reason, unbeknownst to me, this morning it started rendering the day letter 
headers, month and year in Korean characters.

Has this happened to anyone before, and even if not, any hints on where I could 
look to find out why Flex thinks I live in Korea?

Thanks,
Steve


   


  

Re: [flexcoders] working with multiple httpservice requests

2009-03-25 Thread claudiu ursica
Make a class with 2 httpservice instances and use a scheduler (have to write 
logic for it though). You won't be able to run more than 2 parallel connections 
anyway, the browser won't let you... you have to implement result and fault 
functions for the calls in there also...

hth,
Claudiu





From: "Ramsey, Robert L" 
To: "flexcoders@yahoogroups.com" 
Sent: Wednesday, March 25, 2009 8:44:26 PM
Subject: [flexcoders] working with multiple httpservice requests


Hi,
 
I’ve been trying to find a better way to handle
working with multiple httpservice requests that all need to complete before I
run a function.
 
What I’ve been doing is something like this:
 





 
 
What I’d like to do is
have a function I can call as part of the applications creationComplete to run
through all of them.
 
function initializeApp( ):void
{
s1.send();
s2.send();
s3.send();
s4.send();
s5.send();
somefunction( );
}
 
I know that somefunction( ) would have to do a valid data
check to make sure that I had result data before manipulating it.  Is
there a best practices way of doing this?
 
Thanks,
 
Bob
   


  

[flexcoders] Get component width/height after resize?

2009-03-27 Thread Claudiu Ursica
Hi does anyone how to get a component's new height/width after it is being 
resized. I got as far as locating them inside the internal vars $height & 
$width. I have also seen somewhere that for images it works with contentHeight 
and contentWidth. But I have a tabnavgator component which is being resized ... 
and cannot get the new width/height

TIA,
Claudiu



Re: [flexcoders] Why SharedObject.flush so slowly

2009-03-31 Thread claudiu ursica
Runned into the same issue and we decided to write on the Flex Idle event 
instead immediately, that should help you with animation and all taht to make a 
smooth UE ...

C





From: iiley 
To: flexcoders@yahoogroups.com
Sent: Tuesday, March 31, 2009 1:30:59 PM
Subject: [flexcoders] Why SharedObject.flush so slowly


Hi folks,

We are making a online game and want to store some little data to local 
disk(although it is not very important data, but we don't hope it often be 
lost), but we found that SharedObject. flush is so slowly, whatever we write 
something, even a little String "test", it need almost 100ms, you know, 100ms 
blocked for a game, is deadly for feeling.

Well, maybe you'll say just don't call flush, the asdoc says it will be 
automatically written when GC or SWF is closed, but with my test, sadly it 
doesn't work every time. So, maybe you faced similar issue like me before and 
have a solution?

Thanks in advance.

-- 
iiley
AsWing http://www.aswing. org
Personal http://www.iiley. com

   


  

Re: [flexcoders] Eclipse Ganymede

2009-04-05 Thread claudiu ursica
I use ganymede for quite a while now and haven't ran into any issues...

C





From: Tim Rowe 
To: "flexcoders@yahoogroups.com" 
Sent: Monday, April 6, 2009 3:42:19 AM
Subject: RE: [flexcoders] Eclipse Ganymede


I recently installed Builder on a fresh system with 
Eclipse(Ganymede) , and had to do two things:
1.  Install the old Builder Plug-in to my Ganymede 
install.  You have to insist "yes, this is an eclipse 
dir"
2.  Get the absolute latest version of builder 
standalone, and then copy over the newer jars from that install to my plug-in 
environment.
 
Supposedly the plug-in version is available as the same 
version, but I couldn't find it.
 
Alternatively, try this:
http://www.tekool. net/blog/ 2008/06/28/ flex-builder- 3-plugin- dont-work- 
with-eclipse- 34/
 
Tim Rowe
Software 
Engineer
carsales.com Ltd
 


 From: flexcod...@yahoogro ups.com [mailto:flexcoders@ yahoogroups. com] On 
Behalf Of Albert 
Waltner
Sent: Monday, 6 April 2009 10:30 AM
To: flexcod...@yahoogro ups.com
Subject: [flexcoders] Eclipse 
Ganymede


Still using Windows XP and trying Eclipse Ganymede with Flex 3.
The 
messages going back to 9/08 discuss Ganymede problems but without 
a clear 
explanation. I have installed Eclipse 3.2.2 and Flex3 and 
that works but 
when installing Eclipse current version (Ganymede) 
it does not.
On Adobe.com an example posted says it uses Eclipse Ganymede so,
it would seem, 
the poster had NO problems with Ganymede. Why not?
Everyone OK with Ganymede? 
Or not using it? Thanks. 


   


  

Re: [flexcoders] CairngormEvent dispatch question

2009-04-06 Thread claudiu ursica
it is one and the same, the cairngormevent class has been modified to implement 
a dispatch() method which does exactly what your code doesCairngormEvent. 
getInstance( ).dispatchEvent( myEvent); so you can use any of the 2 forms you 
like ...

C





From: nathanpdaniel 
To: flexcoders@yahoogroups.com
Sent: Monday, April 6, 2009 7:21:32 PM
Subject: [flexcoders] CairngormEvent dispatch question


What is the difference between:
CairngormEvent. getInstance( ).dispatchEvent( myEvent);
and 
myEvent.dispatch( );

where myEvent extends the CairngormEvent class?

I've been using the 1st code to dispatch my events but, saw in a post the 2nd.  
All my event classes extend the CairngormEvent class so, what exactly is the 
difference between the two?
Thanks!


   


  

Re: [flexcoders] Cairngorm Question

2009-04-09 Thread claudiu ursica
You do have acess to the model. The combo 2 will be populated with some data. 
Put that into the model and bind combo 2 to the model I'm not sure what you 
actually want to do but it doesn't look like you need cairgorm to do that ...

C





From: skusunam 
To: flexcoders@yahoogroups.com
Sent: Thursday, April 9, 2009 7:53:48 PM
Subject: [flexcoders] Cairngorm Question





Hello Group,

This is my first question on this group and I have been referring to this group 
for all my technical challenges with Flex (started using 1 month back). Thanks 
for such a nice group and support.

I have a complex screen where I have 2 Combo boxes and by default Combo-2 is 
disabled and will be enabled only when user selects Combo-1 and Server returns 
any Objects for Combo-2 otherwise it will be still disabled.

I have defined an Event `LoadCombo2Event' which is dispatched when user selects 
an entry from Combo-1 and the results will be handled in `LoadComb2Command' . I 
do not have access to Combo2 in this command to Enable or Disable? 

How do we handle this case using Cairngorm?

Thanks,
Sre


   


  

Re: [flexcoders] Module Loading and Unloading

2009-04-13 Thread claudiu ursica
Make sure you do not use embedded css into modules and you perform proper 
cleaning before unloading ...
There is a good document from adobe modular.pdf google for it it shoul give you 
some hints ...

C





From: murali dharan 
To: flexcoders@yahoogroups.com
Sent: Monday, April 13, 2009 5:22:19 PM
Subject: [flexcoders] Module Loading and Unloading





Hi All,
   I am breaking my application into smaller modules.I am able to Load my 
Modules but not able to unload my modules so that i am not able reload my 
previous modules. Can any one give suggestions on the above?. Please suggest me 
some sites where i can get the sample project which is loading and unloading 
the modules.

Thanks and Regards
G.Muralidharan

   


  

Re: [flexcoders] Validation in Model (rather than in View)

2009-04-14 Thread claudiu ursica
Have a look a the presentaion model pattern maybe helps your cause...

C





From: Borek 
To: flexcoders@yahoogroups.com
Sent: Tuesday, April 14, 2009 6:16:56 PM
Subject: [flexcoders] Validation in Model (rather than in View)





Flex supports validation in the View layer quite well but the problem is that 
the validation rules should not be there at all. They belong to Model but I'm 
not sure how to implement that in Flex.

I would like to be able to do something like this:

[Required]
[String(minLength= "5")]
public var name : String;

and then just have the TextInput in the View validated automatically. 
Silverlight + .NET RIA Services can work like that but is that possible in Flex 
where we don't have 2-way data binding?

Thanks,
Borek


   


  

Re: [flexcoders] Re: Validation in Model (rather than in View)

2009-04-14 Thread claudiu ursica
Now the validation is triggered by the view but you can forward the actual 
validation to the presentationModel instance who actually does the validation 
... so the view only display the info that comes from the model and that's it...


C



From: Borek 
To: flexcoders@yahoogroups.com
Sent: Tuesday, April 14, 2009 7:25:47 PM
Subject: [flexcoders] Re: Validation in Model (rather than in View)





How does the Presentation Model pattern help?

--- In flexcod...@yahoogro ups.com, claudiu ursica  wrote:
>
> Have a look a the presentaion model pattern maybe helps your cause...
> 
> C
> 
> 
> 
> 
>  _ _ __
> From: Borek 
> To: flexcod...@yahoogro ups.com
> Sent: Tuesday, April 14, 2009 6:16:56 PM
> Subject: [flexcoders] Validation in Model (rather than in View)
> 
> 
> 
> 
> 
> Flex supports validation in the View layer quite well but the problem is that 
> the validation rules should not be there at all. They belong to Model but I'm 
> not sure how to implement that in Flex.
> 
> I would like to be able to do something like this:
> 
> [Required]
> [String(minLength= "5")]
> public var name : String;
> 
> and then just have the TextInput in the View validated automatically. 
> Silverlight + .NET RIA Services can work like that but is that possible in 
> Flex where we don't have 2-way data binding?
> 
> Thanks,
> Borek
>


   


  

Re: [flexcoders] List sizing - height="100%"

2009-04-23 Thread claudiu ursica
there is a rowCount property in the list...

tell you how many item should be displayed

http://blog.flexexamples.com/2007/10/28/resizing-a-flex-list-control-using-the-rowcount-property/

C





From: arieljake 
To: flexcoders@yahoogroups.com
Sent: Wednesday, April 22, 2009 10:03:10 PM
Subject: [flexcoders] List sizing - height="100%"





I am trying, in MXML, to size a list to 100% of its container, but when I do, 
it only shows 2 rows. It is using a custom item renderer. I tried setting a 
rowHeight as well but still doesn't size right. I also set an explicitHeight in 
the item renderer itself. Nothing.

In a fixed size layout, i can set the rowcount but I want it to be fluid in 
case the user resizes the window.

Anyone know why a list wouldn't size by percent to fill a parent container?


   


  

Re: [flexcoders] Pb with File Upload

2009-05-04 Thread claudiu ursica
There is s known bug for flex file upload on slow connections and it is flied 
on Adobe Jira give it a vote if this is your case too ...

http://bugs.adobe.com/jira/browse/FP-1946

C





From: christophe_jacquelin 
To: flexcoders@yahoogroups.com
Sent: Sunday, May 3, 2009 3:48:44 PM
Subject: [flexcoders] Pb with File Upload





Hello, 

I have tested several solutions on the web to upload a file with flex/php.
It is working on my computer with wamp but when I put online There is no file 
in the destination directory. 
I have all the php options right and the folder is 777. 
I don't find the solution.

Thank you,
Christophe, 


   


  

Re: [flexcoders] Generate XML file

2009-06-02 Thread claudiu ursica
the generation of the file is quite trivial, however for the email part it 
depends on how you want ot do it... it ionvolves some backend work if you want 
not to use the classic href="mailto" ...

http://www.tdotblog.info/?q=node/6

C





From: christophe_jacquelin 
To: flexcoders@yahoogroups.com
Sent: Tuesday, June 2, 2009 5:56:29 PM
Subject: [flexcoders] Generate XML file





Hello, 

How to generate an xml file from a flex application, and then send it by email 
? 

Thank you,
Christophe, 


   


  

Re: [flexcoders] any example of an application pre- and post- cairngorm or puremvc?

2009-06-10 Thread claudiu ursica
Go to puremvc.org and you'll find several example...


As for cairngorm google for the page and youll find several apps there ...

C





From: "daniel_kra...@rocketmail.com" 
To: flexcoders@yahoogroups.com
Sent: Wednesday, June 10, 2009 10:09:07 AM
Subject: [flexcoders] any example of an application pre- and post- cairngorm or 
puremvc?





Hello all.

I'm looking for a decent working example (with a possible walkthru) of an 
application using Cairngorm (besides David Tucker's) and most importantly, due 
to apparent rarity, PureMVC. 

Anyone have a URL to decent articles, videos, or source to examine? 

Simple, complex doesn't matter.

Thanks.


   


  

Re: [flexcoders] PureMVC

2009-06-18 Thread claudiu ursica
On pureMVC.org there are several samples in there.

check this for example:
http://trac.puremvc.org/PureMVC_AS3/

C





From: Ashish Verma 
To: flexcoders@yahoogroups.com
Sent: Friday, June 19, 2009 8:52:29 AM
Subject: [flexcoders] PureMVC





Hello All,
 
I am very new for PureMVC architecture. After reading about
Model, View and controller and their progressive actor proxy, mediator and
command I am looking for some big demo application in PureMVC. Please provide
me link, archive or something similar.
 
 
Best,
Ashish
 
   


  

Re: [flexcoders] need votes for adobe bugs

2009-06-23 Thread claudiu ursica
Probably to get them up in the fixing queue since many votes gain you attention 
... :)

C





From: Tom Chiverton 
To: flexcoders@yahoogroups.com
Sent: Tuesday, June 23, 2009 12:50:16 PM
Subject: Re: [flexcoders] need votes for adobe bugs





On Tuesday 23 Jun 2009, Kun Janos wrote:
> I need votes for the following adobe bugs:

Why :-)

-- 
Helping to challengingly entrench users as part of the IT team of the 
year, '09 and '08

 * * * *  

This email is sent for and on behalf of Halliwells LLP.

Halliwells LLP is a limited liability partnership registered in England and 
Wales under registered number OC307980 whose registered office address is at 
Halliwells LLP, 3 Hardman Square, Spinningfields, Manchester, M3 3EB. A list of 
members is available for inspection at theregistered office together with a 
list of those non members who are referred to as partners. We use the word 
?partner? to refer to a member of the LLP, or an employee or consultant with 
equivalent standing and qualifications. Regulated by the Solicitors Regulation 
Authority.

CONFIDENTIALITY

This email is intended only for the use of the addressee named above and may be 
confidential or legally privileged. If you are not the addressee you must not 
read it and must not use any information contained in nor copy it nor inform 
any person other than Halliwells LLP or the addressee of its existence or 
contents. If you have received this email in error please delete it and notify 
Halliwells LLP IT Department on 0870 365 2500.

For more information about Halliwells LLP visit www.halliwells. com.
   


  

Re: [flexcoders] Flex View Stack / Component Life Cycle Best practice

2009-06-26 Thread claudiu ursica
And you probably want to try to catch that change event on it's propagation 
phase instead of bubbling phase.

C





From: Jeffry Houser 
To: flexcoders@yahoogroups.com
Sent: Friday, June 26, 2009 12:08:56 AM
Subject: Re: [flexcoders] Flex View Stack / Component Life Cycle Best practice






You probably want to run code when the viewStack changes.  Look at the 
ViewStack, I bet there is a change event. 

martinosaint wrote:
> Hi there,
>
> I have built a multiplage application in Flex with different user roles. I 
> use a View Stack with a Menu Bar to navigate between the different pages.
>
> However - each time a page gets opened, I need to do some database calls, 
> apply User Role settings, etc. in an init() function. This init function may 
> reference some UI elements of this page.
>
> I tried to load it with the "creationComplete" event, but this one gets only 
> triggered once (since the page is not rebuilt each them the view stack shows 
> it).
>
> Now I have put it on the "show" event, but this seems not to get triggered 
> consistently, or before the page is fully created the first time.
>
> Whats the best practice for this case?
>  * I have to pass in data
>  * Call init functions (database calls)
>  * Manipulate components
>
> Ideally I would need a way to call init each time the page is loaded and 
> after all components are created.
>
> Thanks for your help,
> Martin
>
>
>
>  - - --
>
> --
> Flexcoders Mailing List
> FAQ: http://groups. yahoo.com/ group/flexcoders /files/flexcoder sFAQ.txt
> Alternative FAQ location: https://share. acrobat.com/ adc/document. do?docid= 
> 942dbdc8- e469-446f- b4cf-1e62079f684 7
> Search Archives: http://www.mail- archive.com/ flexcoders% 40yahoogroups. 
> comYahoo! Groups Links
>
>
>
>
> 

-- 
Jeffry Houser, Technical Entrepreneur
Adobe Community Expert: http://tinyurl. com/684b5h
http://www.twitter. com/reboog711 | Phone: 203-379-0773
--
Easy to use Interface Components for Flex Developers
http://www.flextras.com?c=104
--
http://www.theflexshow.com
http://www.jeffryhouser.com
--
Part of the DotComIt Brain Trust


   


  

Re: [flexcoders] Is there a good log application?

2009-06-27 Thread claudiu ursica
Try Thunderbolt maybe suits your needs...

C





From: guy.tomer 
To: flexcoders@yahoogroups.com
Sent: Saturday, June 27, 2009 9:24:35 PM
Subject: [flexcoders] Is there a good log application?





Hi,

I was wondering if anyone can point me to an easy to use logging application? 
Looks like Flex used to have one called MiniDebug but it's deprecated.

My problem is that my testers have many difficulties configuring the flash 
debugger and the flashlog.txt (permissions on vista and other issues), I think 
something that uses LocalConnection or some JavaScript Target could do the job. 
Note - I need something that is supported on multiple environments not just 
firebug on firefox.

Tnx
Guy


   


  

Re: [flexcoders] Re: Flex 3 Exam Cert Question

2009-06-29 Thread claudiu ursica
Check the lynda.com videos for LCDS.

TH,
C





From: ew6014 
To: flexcoders@yahoogroups.com
Sent: Monday, June 29, 2009 12:43:47 PM
Subject: [flexcoders] Re: Flex 3 Exam Cert Question





hi leds

thanks for much. i will look into the flex 3 developer guide but there doesnt 
seem to be a guide on using LCDS. lifecycle is using a lot in the guide but 
none of them does teach on how to implement lcds messaging and data management

wondering if reading the actual documentation of lifecycle data services will 
be a overkill.

how about you leds? .. how did you get "through" the lcds portion or better 
still the entire interacting data sources and servers portion of the exam?

--- In flexcod...@yahoogro ups.com, leds usop  wrote:
>
> hi,
> 
> i recentlly got my flex 3 with air cert and i'd say the questions on lcds are 
> more on interacting with lcds, so you should be able to get enough info from 
> livedocs or any good flex book that discusses lcds.
> 
> As for the local database connection, that would be pertaining to AIR's 
> interaction with SQL (or SQLite). 
> 
> someone correct me if im wrong. ^^
> cheers
> 
> can someone point me to a resource or book that i can find out more on 
> IMPLEMENTING LCDS MESSAGING AND DATA MANAGEMENT ?
> 
> 
> 
> in the exam guide it also mentions creating connecting to a local
> database. what does that mean? does it mean SQL database or oracle?<-- SQL as 
> 
> --- On Sun, 6/28/09, ew6014  wrote:
> 
> From: ew6014 
> Subject: [flexcoders] Flex 3 Exam Cert Question
> To: flexcod...@yahoogro ups.com
> Date: Sunday, June 28, 2009, 1:01 PM
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
>   hi guys,
> 
> 
> 
> i have a question on the interacting data source/servers portion of flex 3 
> exam.
> 
> 
> 
> can someone point me to a resource or book that i can find out more on 
> IMPLEMENTING LCDS MESSAGING AND DATA MANAGEMENT ?
> 
> 
> 
> in the exam guide it also mentions creating connecting to a local database. 
> what does that mean? does it mean SQL database or oracle?
> 
> 
> 
> appreciate the help
>


   


  

Re: [flexcoders] How to use modulemanger to load modules

2009-06-29 Thread claudiu ursica
There is this document issued by adobe where they explain with examples how to 
handles modules ...
http://blogs.adobe.com/flexdoc/pdfs/modular.pdf

TH,
C





From: j2me_soul 
To: flexcoders 
Sent: Monday, June 29, 2009 1:53:37 PM
Subject: [flexcoders] How to use modulemanger to load modules





How to load a module ?





 200万种商品,最低价格,疯狂诱惑你  
   


  

Re: Re: [flexcoders] How to use modulemanger to load modules

2009-06-29 Thread claudiu ursica
Your code looks fine to me... Are you sure the getModule() returns a valid 
instance??

C






From: j2me_soul 
To: flexcoders 
Sent: Monday, June 29, 2009 2:28:25 PM
Subject: Re:Re: [flexcoders] How to use modulemanger to load modules





If I declare a moduleloader object in mxml it works.

But I want to dynamically load a module, so I try to do this using 
modulemanager.
 
private var WorkAlert:Class;
protected function application_ initializeHandle r():void
  {
   module = ModuleManager. getModule( "modules/ workalert_ mod.swf") ;
/* the event never dispatch, Why ? */
/* I can't do angthing, because there is no error at runtime at all */
   module.addEventList ener(ModuleEvent .READY, moduleReadyHandler) ;
   module.load( ); 
  }
 
 

 
在2009-06-29,"claudiu ursica"  写道:




There is this document issued by adobe where they explain with examples how to 
handles modules ...
http://blogs. adobe.com/ flexdoc/pdfs/ modular.pdf

TH,
C





 From: j2me_soul 
To: flexcoders 
Sent: Monday, June 29, 2009 1:53:37 PM
Subject: [flexcoders] How to use modulemanger to load modules


How to load a module ?





 200万种商品,最低价格,疯狂诱惑你 




 200万种商品,最低价格,疯狂诱惑你  
   


  

Re: Re: Re: [flexcoders] How to use modulemanger to load modules

2009-06-29 Thread claudiu ursica
I dunno haven't switched to F4 yet, at least haven't developed any commercial 
stuff only played with it a little bit and haven;t touched the modules yet in 
F4.

check help file this http://livedocs.adobe.com/flex/gumbo/html/flex_4_help.pdf  
maybe they have something in there ... 

C





From: j2me_soul 
To: flexcoders 
Sent: Monday, June 29, 2009 2:55:26 PM
Subject: Re:Re: Re: [flexcoders] How to use modulemanger to load modules





I can sure. Because if getModule return a unvalid value the next sentence will 
be going wrong.
I use the Flex4 SDK. Is that make thing complexed?
 
  protected function application_ initializeHandle r():void
  {
   module = ModuleManager. getModule( "modules/ workalert_ mod.swf") ;
   module.addEventList ener(ModuleEvent .READY, moduleReadyHandler) ;
   module.load( ); 
  }
/* it doesn't run actually*/
  private function moduleReadyHandler(e:ModuleEvent) :void{
   switch(module. url){
case "module/workalert_ mod.swf":
 AllStaffLoader. removeAllChildre n();
 AllStaffLoader. addChild( module.factory. create() as DisplayObject) ;
 break;
   } 
  }
 
 写道:




Your code looks fine to me... Are you sure the getModule() returns a valid 
instance??

C






 From: j2me_soul 
To: flexcoders 
Sent: Monday, June 29, 2009 2:28:25 PM
Subject: Re:Re: [flexcoders] How to use modulemanger to load modules


If I declare a moduleloader object in mxml it works.

But I want to dynamically load a module, so I try to do this using 
modulemanager.
 
private var WorkAlert:Class;
protected function application_ initializeHandle r():void
  {
   module = ModuleManager. getModule( "modules/ workalert_ mod.swf") ;
/* the event never dispatch, Why ? */
/* I can't do angthing, because there is no error at runtime at all */
   module.addEventList ener(ModuleEvent .READY, moduleReadyHandler) ;
   module.load( ); 
  }
 
 

 
在2009-06-29,"claudiu ursica"  写道:




There is this document issued by adobe where they explain with examples how to 
handles modules ...
http://blogs. adobe.com/ flexdoc/pdfs/ modular.pdf

TH,
C





 From: j2me_soul 
To: flexcoders 
Sent: Monday, June 29, 2009 1:53:37 PM
Subject: [flexcoders] How to use modulemanger to load modules


How to load a module ?





 200万种商品,最低价格,疯狂诱惑你 




 200万种商品,最低价格,疯狂诱惑你 




 200万种商品,最低价格,疯狂诱惑你  
   


  

Re: [flexcoders] Compiling selected files in Flex

2009-06-29 Thread claudiu ursica
Since the app is very large you should be using ant or maven. Make a script for 
every module and another one for the shell ap. The you can make a script that 
runs the all or you can invoke the ant just on the module that has changed ...

C





From: Vaibhav Chauhan 
To: flexcoders@yahoogroups.com; flexcoders-dig...@yahoogroups.com
Sent: Monday, June 29, 2009 4:03:25 PM
Subject: [flexcoders] Compiling selected files in Flex





Hi All,

   My team is working on a large flex application. As required, most of the 
times we need to make very small change in the files[say some percentage change 
of a component]. For this, we need to compile whole module. I wanna know if 
there is a way so that I can compile some selected files only in respective 
modules.

Regards
Vaibhav Chauhan

   


  

Re: [flexcoders] Bring forward something in flex

2009-07-03 Thread claudiu ursica
It is related to the order that you declare component in your mxml ... The 
latter the better. 

C





From: j2me_soul 
To: flexcoders 
Sent: Friday, July 3, 2009 11:36:20 AM
Subject: [flexcoders] Bring forward something in flex





I have a lot titlewindow in the application. But the main panel which wrote by 
mxml is always covered by some titlewindow. How can I bring the main panel 
forward when I clicked it ?





 200万种商品,最低价格,疯狂诱惑你  
   


  

Re: [flexcoders] How to disable TitleWindow dragable

2009-07-06 Thread claudiu ursica
Do you mean that the Title window cannot be dragged anymore? 
C





From: j2me_soul 
To: flexcoders 
Sent: Monday, July 6, 2009 10:16:21 AM
Subject: [flexcoders] How to disable TitleWindow dragable





How can I stop dragable function?





 200万种商品,最低价格,疯狂诱惑你  
   


  

Re: [flexcoders] My itemrenderer is mercurial!!

2009-07-06 Thread claudiu ursica
Item renderers are reused instead of being recreated ... That is why your state 
is inconsistent...
C





From: leds usop 
To: flexcoders@yahoogroups.com
Sent: Monday, July 6, 2009 10:59:58 AM
Subject: Re: [flexcoders] My itemrenderer is mercurial!!





how are you setting the selection status of the checkbox? override the setter 
method for data, then place a default value (an if else perhaps) if the data is 
null, or is int's default state.

--- On Mon, 7/6/09, j2me_soul  wrote:


>From: j2me_soul 
>Subject: [flexcoders] My itemrenderer is mercurial!!
>To: "flexcoders" 
>Date: Monday, July 6, 2009, 7:59 AM
>
>
>The itemrenderer is a HBox. There is a check and a label in the HBox.
>When I selected any of the checkbox and scrolled the scrollbar of the List 
>which used the itemrenderer, the stange thing happened, the selected checkbox 
>is no longer the same checkbox !! Maybe the last one, maybe the second one ~~~ 
> How can I fix this ?
>
>
>
>

 200万种商品,最低价格,疯狂诱惑你  >
>  

   


  

Re: [flexcoders] Smooth Manual setProgress

2009-07-06 Thread claudiu ursica
Make a flash movie clip and animate it...
C





From: kenny14390 
To: flexcoders@yahoogroups.com
Sent: Monday, July 6, 2009 10:29:38 PM
Subject: [flexcoders] Smooth Manual setProgress





Hey. I'm using a manual ProgressBar to display progress towards a goal. As the 
amount increases or decreases, the setProgress method updates the progress 
accordingly but jumpy. Is there a way to smooth out the graphic of the progress 
transition?

Thanks!


   


  

Re: [flexcoders] TitleWindow closeButton Color

2009-07-06 Thread claudiu ursica
I use this with a swf and works perfectly

TitleWindow 
{
closeButtonDisabledSkin: 
Embed(source="custom_skins.swf",symbol="CloseButtonDisabled");
closeButtonDownSkin: 
Embed(source="custom_skins.swf",symbol="CloseButtonDown");
closeButtonOverSkin: 
Embed(source="custom_skins.swf",symbol="CloseButtonOver");
closeButtonUpSkin: Embed(source="custom_skins.swf",symbol="CloseButtonUp");
}

TH,
C





From: jmfillman 
To: flexcoders@yahoogroups.com
Sent: Tuesday, July 7, 2009 1:27:59 AM
Subject: [flexcoders] TitleWindow closeButton Color





Is there a style for the color of the closeButton in a TitleWindow? I can't 
seem to find it, but it seems odd to have black be the only option. Can't seem 
to embed an image for the closeButtonSkin either.

Setting a style in CSS doesn't work, or...??

TitleWindow {
closeButtonSkin: Embed("assets/ close.png" );
}


   


  

Re: [flexcoders] How to link effects so that one starts after one finishes?

2009-07-09 Thread claudiu ursica
You can play the first effect and listen to the effectEnd event ant in the 
handler start the second effect or you can go with putting the effects inside a 
Sequence.

C





From: Chet Haase 
To: "flexcoders@yahoogroups.com" 
Sent: Thursday, July 9, 2009 5:50:27 PM
Subject: RE: [flexcoders] How to link effects so that one starts after one 
finishes?





 
There
are a couple of ways you could make this work:
 
1)  Simplest: make your triggered effects do the right thing (the
appearing one waits for the disappearing one to finish, via a startDelay):
 


 
This
would ensure that the wipeUp effect (which always runs on the component coming
into view, in your example) will not run until the duration of the wipeDown
(used for the disappearing component) is finished.
 
2)  More involved: Use transitions
Instead
of triggers for these one-off effects, you could set up your application to use
states for your components. in one state, the DataGrid would be there anre the
List would not, in the other state the List would be there and the DataGrid
would not. Then you could set up transitions for these states. It’s a bit
more involved, but might scale better than just running individual effects on
the components.
 
Chet.
 
From:flexcod...@yahoogro ups.com [mailto:flexcoders@ yahoogroups. com] On 
Behalf Of gmoniey22
Sent: Wednesday, July 08, 2009 6:29 PM
To: flexcod...@yahoogro ups.com
Subject: [flexcoders] How to link effects so that one starts after one
finishes?
 




I have two components, and I want to swap
between them using wipe down/up. i.e. click a button, the visible panel slides
down, and after that panel is no longer visible, the other panel slides up and
takes its place.

I have tried something like the following (please excuse the crude example),
but the effects occur at the same time, and it doesn't look that good.


http://www.adobe. com/2006/ mxml"
layout="absolute">














   


  

Re: [flexcoders] Re: better option than repeater?

2009-07-20 Thread claudiu ursica
I'd use lists with custom item renderers. Repeaters are killers for perormance 
even when you tell them to cache children 

C





From: valdhor 
To: flexcoders@yahoogroups.com
Sent: Monday, July 20, 2009 9:45:44 PM
Subject: [flexcoders] Re: better option than repeater?

  
I use repeaters quite a lot and like them.

What I do is to create a component (Which sometimes contains other components) 
and the repeat that.

In your situation, I would create a component with all of your check boxes and 
save button. This component would have all of the functionality to display 
which check boxes are selected as well as the save button click handler. It 
would also have a public property that would take a data object. On creation 
complete of this component, it would check the values of the data object and 
set the check boxes appropriately.

Then, I would repeat this component passing in the data objects returned from 
the remote object call...





HTH

Steve

--- In flexcod...@yahoogro ups.com, "postwick"  wrote:
>
> I don't like repeaters.  They are too clumsy.  The biggest drawback is an 
> inability to access values after the repeater has finish executing.  It's not 
> the same as, for example, looping over values and generating static HTML 
> using ColdFusion.  I seem to always end up having to navigate up and down 
> through the parents/children of the objects and storing values I need in 
> properties like name, automationName, etc.  This is clumsy and messy.
> 
> As an example, I have a section of my application where I want to list the 
> names of people from a table, and for each person generate a set of 
> checkboxes that designate access to certain areas of the application.  For 
> example: http://www.ubeek. com/images/ staffrepeater. jpg
> 
> That is one main repeater that loops through the staff (records returned from 
> remoteObject) and inside that repeater two other repeaters (also from 
> remoteObjects) that generate the checkboxes.
> 
> I can't simply pass the primary key of the staff for which the Save button 
> was clicked, by putting click="saveClick( {staffRepeater. currentItem. SEQ})" 
> into the button object.  When I do that and click it I get an error about 
> "repeater is not currently executing" or something like that.
> 
> I don't want to resort to a datagrid and then "click to edit" then bring up a 
> form kind of process.  I want it as few clicks as possible.
> 
> Is there a better way to display data in a custom way like this, without 
> using repeaters, so that I can more easily access the child objects and their 
> properties?
> 
> Thanks,
> Paul
>


   


  

Re: [flexcoders] Re: better option than repeater?

2009-07-20 Thread claudiu ursica
I'm talking in theory right now cause its late here ... you should have all 
your data structured in the model. As you have nested repeaters you can use 
nested lists Both of the are fed via data providers. Inside the first list 
you override the data setter and you there you can feed the second list 
dynamically.Keep in mind that you can inject data into the renderer where you 
have the nested list. Use binding also if you can (bind the list to the model 
data)... If you cannot manage it give me a private message or a reply to this 
tomorrow and I'll try to sketch something maybe you can send me your data 
structure and I'll mock something on that ...

C





From: postwick 
To: flexcoders@yahoogroups.com
Sent: Monday, July 20, 2009 9:54:46 PM
Subject: [flexcoders] Re: better option than repeater?

  
Can you give me a brief example of how you would convert a single repeater with 
two nested repeaters into a List with custom item renderers?

Thanks,
Paul

--- In flexcod...@yahoogro ups.com, claudiu ursica  wrote:
>
> I'd use lists with custom item renderers. Repeaters are killers for 
> perormance even when you tell them to cache children 
> 
> C
> 
> 
> 
> 
>  _ _ __
> From: valdhor 
> To: flexcod...@yahoogro ups.com
> Sent: Monday, July 20, 2009 9:45:44 PM
> Subject: [flexcoders] Re: better option than repeater?
> 
> 
> I use repeaters quite a lot and like them.
> 
> What I do is to create a component (Which sometimes contains other 
> components) and the repeat that.
> 
> In your situation, I would create a component with all of your check boxes 
> and save button. This component would have all of the functionality to 
> display which check boxes are selected as well as the save button click 
> handler. It would also have a public property that would take a data object. 
> On creation complete of this component, it would check the values of the data 
> object and set the check boxes appropriately.
> 
> Then, I would repeat this component passing in the data objects returned from 
> the remote object call...
> 
> 
> 
> 
> 
> HTH
> 
> Steve
> 
> --- In flexcod...@yahoogro ups.com, "postwick"  wrote:
> >
> > I don't like repeaters.  They are too clumsy.  The biggest drawback is an 
> > inability to access values after the repeater has finish executing.  It's 
> > not the same as, for example, looping over values and generating static 
> > HTML using ColdFusion.  I seem to always end up having to navigate up and 
> > down through the parents/children of the objects and storing values I need 
> > in properties like name, automationName, etc.  This is clumsy and messy.
> > 
> > As an example, I have a section of my application where I want to list the 
> > names of people from a table, and for each person generate a set of 
> > checkboxes that designate access to certain areas of the application.  For 
> > example: http://www.ubeek. com/images/ staffrepeater. jpg
> > 
> > That is one main repeater that loops through the staff (records returned 
> > from remoteObject) and inside that repeater two other repeaters (also from 
> > remoteObjects) that generate the checkboxes.
> > 
> > I can't simply pass the primary key of the staff for which the Save button 
> > was clicked, by putting click="saveClick( {staffRepeater. currentItem. 
> > SEQ})" into the button object.  When I do that and click it I get an error 
> > about "repeater is not currently executing" or something like that.
> > 
> > I don't want to resort to a datagrid and then "click to edit" then bring up 
> > a form kind of process.  I want it as few clicks as possible.
> > 
> > Is there a better way to display data in a custom way like this, without 
> > using repeaters, so that I can more easily access the child objects and 
> > their properties?
> > 
> > Thanks,
> > Paul
> >
>


   


  

Re: [flexcoders] creation timing on panel component

2009-08-01 Thread claudiu ursica
Quick and really dirty...
wrap them inside a try catch block... but then I can't believe I just said 
that... Share some more code and I'll come up with something more engineering 
like...

C





From: Jason B 
To: flexcoders@yahoogroups.com
Sent: Saturday, August 1, 2009 5:25:33 PM
Subject: [flexcoders] creation timing on panel component

  

I'm calling a httpservice which I populate into this nutritionData
variable, I'm using a panel component to reuse it, and when I call the
#SETTER below it throws a 1009 error, I was wondering if the panel is
not yet created, if thats the case how can i wait until the panel is
created?

[Bindable]
private var nutritionData: XML;

#SETTER
pnlCreateBreakfast. meal = nutritionData. breakfast;


   


  

Re: [flexcoders] Re: creation timing on panel component

2009-08-01 Thread claudiu ursica
when are you calling the service?

C





From: Jason B 
To: flexcoders@yahoogroups.com
Sent: Saturday, August 1, 2009 5:51:26 PM
Subject: [flexcoders] Re: creation timing on panel component

  
Just so you know if I use this on the component it works fine






--- In flexcod...@yahoogro ups.com, "Jason B"  wrote:
>
> Main.mxml
>  --
> 
>   [Bindable]
>   private var nutritionData: XML;
> 
> 
>   //  create breakfast
>   private function createBreakfast( ):void
>   {
>   vsMain.selectedInde x = 1;
>   vsCreateMeals. selectedIndex = 0;
>   plantype = 'Breakfast';
> 
> #1009 ERROR HERE BELOW !
>   pnlCreateBreakfast. meal = nutritionData. 
> breakfast;
> 
>   }
> 
> 
>result="nutritionRe sultHandler( event)"
>   fault="nutritionFau ltHandler( event)" resultFormat= "e4x"/>
> 
> 
>   
>borderStyle= "inset" borderThickness= "2" id="vsCreateMeals" >
> 
>   
> id="pnlCreateBreakf ast" />
>   
> 
> 
>  - - - - -
> panelcreatemeal. mxml
>  -
> 
> http://www.adobe. com/2006/ mxml" width="100%" 
> height="390" 
>   borderThicknessLeft ="0" borderThicknessRigh t="0" borderThicknessBott 
> om="0"
>   dropShadowEnabled= "false"
>horizontalAlign= "center" xmlns:containers= "com.dougmccune. 
> containers. *" title="Select An Item from below" creationPolicy= "all">
> 
>   
>   
>   
> 
>height="100% " 
>   horizontalGap= "1" borderStyle= "inset" backgroundColor= 
> "0xFF" 
>   segments="9" reflectionEnabled= "true"/>
> 
>
>   
>click="parentApplic ation.vsCreateMe als.selectedInde x=1;"/>
>   
> 
> 
> 
> 
>  -
> panelcreatemealitem .mxml
> -
> 
> http://www.adobe. com/2006/ mxml" width="310" 
> height="320" 
>title="{mealDetails .title}" horizontalAlign= "center" creationPolicy= 
> "all">
> 
> 
>   
>   [Event(name= "addToMeal" )] 
>   [Event(name= "learnAboutThis" )] 
>   
> 
>   
>   
>   
> 
>   
> 
>   
> 
>
> 
>   
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> 
> --- In flexcod...@yahoogro ups.com, claudiu ursica  wrote:
> >
> > Quick and really dirty...
> > wrap them inside a try catch block... but then I can't believe I just said 
> > that... Share some more code and I'll come up with something more 
> > engineering like...
> > 
> > C
> > 
> > 
> > 
> > 
> >  _ _ __
> > From: Jason B 
> > To: flexcod...@yahoogro ups.com
> > Sent: Saturday, August 1, 2009 5:25:33 PM
> > Subject: [flexcoders] creation timing on panel component
> > 
> > 
> > 
> > I'm calling a httpservice which I populate into this nutritionData
> > variable, I'm using a panel component to reuse it, and when I call the
> > #SETTER below it throws a 1009 error, I was wondering if the panel is
> > not yet created, if thats the case how can i wait until the panel is
> > created?
> > 
> > [Bindable]
> > private var nutritionData: XML;
> > 
> > #SETTER
> > pnlCreateBreakfast. meal = nutritionData. breakfast;
> >
>


   


  

Re: [flexcoders] Re: creation timing on panel component

2009-08-01 Thread claudiu ursica
>From what I see here the button click does not make the call to the http 
>service.

The general rule of the thumb is aftter the service call you push the data into 
a model which usually updates the view via binding. I always parse data into 
array collections or other strong typed objects. Having the items into an array 
collection enables you to bind to it if you're using List based components in 
the view. However in your case yuou could listed to the collection change event 
and do your thing manually. Send me the code via email and I'll try to debug 
it. I cannot figure it out from what I see. I guess you make the call for the 
data and the result gets back before the creation complete venet fopr the panel 
fires.

C





From: Jason B 
To: flexcoders@yahoogroups.com
Sent: Saturday, August 1, 2009 9:14:34 PM
Subject: [flexcoders] Re: creation timing on panel component

  

 
is in the main.mxml

--- In flexcod...@yahoogro ups.com, claudiu ursica  wrote:
>
> when are you calling the service?
> 
> C
> 
> 
> 
> 
>  _ _ __
> From: Jason B 
> To: flexcod...@yahoogro ups.com
> Sent: Saturday, August 1, 2009 5:51:26 PM
> Subject: [flexcoders] Re: creation timing on panel component
> 
> 
> Just so you know if I use this on the component it works fine
> 
> 
> 
> 
> 
> 
> --- In flexcod...@yahoogro ups.com, "Jason B"  wrote:
> >
> > Main.mxml
> >  --
> > 
> > [Bindable]
> > private var nutritionData: XML;
> > 
> > 
> > //  create breakfast
> > private function createBreakfast( ):void
> > {
> > vsMain.selectedInde x = 1;
> > vsCreateMeals. selectedIndex = 0;
> > plantype = 'Breakfast';
> > 
> > #1009 ERROR HERE BELOW !
> > pnlCreateBreakfast. meal = nutritionData. 
> > breakfast;
> > 
> > }
> > 
> > 
> >  > result="nutritionRe sultHandler( event)"
> > fault="nutritionFau ltHandler( event)" resultFormat= "e4x"/>
> > 
> > 
> > 
> >  > borderStyle= "inset" borderThickness= "2" id="vsCreateMeals" >
> > 
> > 
> >   > id="pnlCreateBreakf ast" />
> > 
> > 
> > 
> >  - - - - -
> > panelcreatemeal. mxml
> >  -
> > 
> > 
> > borderThicknessLeft ="0" borderThicknessRigh t="0" borderThicknessBott 
> > om="0"
> > dropShadowEnabled= "false"
> >  horizontalAlign= "center" xmlns:containers= "com.dougmccune. 
> > containers. *" title="Select An Item from below" creationPolicy= "all">
> > 
> > 
> > 
> > 
> > 
> >  > height="100% " 
> > horizontalGap= "1" borderStyle= "inset" backgroundColor= 
> > "0xFF" 
> > segments="9" reflectionEnabled= "true"/>
> > 
> >  
> > 
> >  > click="parentApplic ation.vsCreateMe als.selectedInde x=1;"/>
> > 
> >   
> > 
> > 
> > 
> >  -
> > panelcreatemealitem .mxml
> > -
> > 
> > http://www.adobe. com/2006/ mxml" width="310" 
> > height="320" 
> >  title="{mealDetails .title}" horizontalAlign= "center" creationPolicy= 
> > "all">
> > 
> > 
> > 
> > [Event(name= "addToMeal" )] 
> > [Event(name= "learnAboutThis" )] 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> >  
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > --- In flexcod...@yahoogro ups.com, claudiu ursica  wrote:
> > >
> > > Quick and really dirty...
> > > wrap them inside a try catch block... but then I can't believe I just 
> > > said that... Share some more code and I'll come up with something more 
> > > engineering like...
> > > 
> > > C
> > > 
> > > 
> > > 
> > > 
> > >  _ _ __
> > > From: Jason B 
> > > To: flexcod...@yahoogro ups.com
> > > Sent: Saturday, August 1, 2009 5:25:33 PM
> > > Subject: [flexcoders] creation timing on panel component
> > > 
> > > 
> > > 
> > > I'm calling a httpservice which I populate into this nutritionData
> > > variable, I'm using a panel component to reuse it, and when I call the
> > > #SETTER below it throws a 1009 error, I was wondering if the panel is
> > > not yet created, if thats the case how can i wait until the panel is
> > > created?
> > > 
> > > [Bindable]
> > > private var nutritionData: XML;
> > > 
> > > #SETTER
> > > pnlCreateBreakfast. meal = nutritionData. breakfast;
> > >
> >
>


   


  

Re: [flexcoders] Re: creation timing on panel component

2009-08-02 Thread claudiu ursica
Hi did not go throgh your code but the problem is that you get your data on app 
creationComplete. By the time you have the data the poanel is not created yet. 
That is why you get the error. I don't know what are you trying to accomplish 
and why are you loading another swf in the main app. My suggestion is to 
restructure you code a little bit MVC style. Get the data into a model, put a 
variable currentPlanType and wit respect to that bind to you current selected 
plan. It will work with binding as you already said, because the bindings fire 
first when null and secionnd time after you get your data and have the 
component created.
You keep duplicated code in createBreakfast , Luynch and dinner which is not 
OK. 

HTH,
C





From: Jason B 
To: flexcoders@yahoogroups.com
Sent: Saturday, August 1, 2009 10:07:02 PM
Subject: [flexcoders] Re: creation timing on panel component

  
I didnt include all the code I'll zip it up and email it to you.

--- In flexcod...@yahoogro ups.com, claudiu ursica  wrote:
>
> From what I see here the button click does not make the call to the http 
> service.
> 
> The general rule of the thumb is aftter the service call you push the data 
> into a model which usually updates the view via binding. I always parse data 
> into array collections or other strong typed objects. Having the items into 
> an array collection enables you to bind to it if you're using List based 
> components in the view. However in your case yuou could listed to the 
> collection change event and do your thing manually. Send me the code via 
> email and I'll try to debug it. I cannot figure it out from what I see. I 
> guess you make the call for the data and the result gets back before the 
> creation complete venet fopr the panel fires.
> 
> C
> 
> 
> 
> 
>  _ _ __
> From: Jason B 
> To: flexcod...@yahoogro ups.com
> Sent: Saturday, August 1, 2009 9:14:34 PM
> Subject: [flexcoders] Re: creation timing on panel component
> 
> 
> 
>  
> is in the main.mxml
> 
> --- In flexcod...@yahoogro ups.com, claudiu ursica  wrote:
> >
> > when are you calling the service?
> > 
> > C
> > 
> > 
> > 
> > 
> >  _ _ __
> > From: Jason B 
> > To: flexcod...@yahoogro ups.com
> > Sent: Saturday, August 1, 2009 5:51:26 PM
> > Subject: [flexcoders] Re: creation timing on panel component
> > 
> > 
> > Just so you know if I use this on the component it works fine
> > 
> > 
> > 
> > 
> > 
> > 
> > --- In flexcod...@yahoogro ups.com, "Jason B"  wrote:
> > >
> > > Main.mxml
> > >  --
> > > 
> > >   [Bindable]
> > >   private var nutritionData: XML;
> > > 
> > > 
> > >   //  create breakfast
> > >   private function createBreakfast( ):void
> > >   {
> > >   vsMain.selectedInde x = 1;
> > >   vsCreateMeals. selectedIndex = 0;
> > >   plantype = 'Breakfast';
> > > 
> > > #1009 ERROR HERE BELOW !
> > >   pnlCreateBreakfast. meal = nutritionData. 
> > > breakfast;
> > > 
> > >   }
> > > 
> > > 
> > >  > >   result="nutritionRe sultHandler( event)"
> > >   fault="nutritionFau ltHandler( event)" resultFormat= "e4x"/>
> > > 
> > > 
> > >   
> > >> > borderStyle= "inset" borderThickness= "2" id="vsCreateMeals" >
> > > 
> > >   
> > > > > id="pnlCreateBreakf ast" />
> > >   
> > > 
> > > 
> > >  - - - - -
> > > panelcreatemeal. mxml
> > >  -
> > > 
> > > 
> > >   borderThicknessLeft ="0" borderThicknessRigh t="0" borderThicknessBott 
> > > om="0"
> > >   dropShadowEnabled= "false"
> > >horizontalAlign= "center" xmlns:containers= "com.dougmccune. 
> > > containers. *" title="Select An Item from below" creationPolicy= "all">
> > > 
> > >   
> > >   
> > >   
> > > 
> > >> > height="100%

  1   2   3   >