[flexcoders] IE6 RemoteObject calls fail under HTTPS

2009-03-16 Thread Rafael Faria
We have tried many many things, and seem to have narrowed it down to the 
session headers and the cache control. However all most all of the posts and 
notes around the web seem to get this issue arising with HTTPService calls that 
spawn a #2032 streaming error and not what we are seeing. Tracking the calls 
with Charles for instance seems to indicate that the call to the gateway is 
never actually being made. We discounted any crossdomain issues (the webroot 
and the gateway are on different servers) as the sandbox violation errors did 
not appear at all.

So if anyone out there can shed some light on this we would be most 
appreciative. Or conversely if you can get every person in the world to upgrade 
their browsers beyond IE6 that would be awesome too.

mx.rpc.events::FaultEvent)#0
 bubbles = false
 cancelable = true
 currentTarget = (null)
 eventPhase = 2
 fault = (mx.rpc::Fault)#1
   content = (Object)#2
   errorID = 0
   faultCode = "Client.Error.MessageSend"
   faultDetail = "Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: 
Failed: url: 'https://mydomain.com/amfphp/gateway.php'"
   faultString = "Send failed"
   message = "faultCode:Client.Error.MessageSend faultString:'Send failed' 
faultDetail:'Channel.Connect.Failed error NetConnection.Call.Failed: HTTP: 
Failed: url: 'https://mydomain.com/amfphp/gateway.php''"
   name = "Error"
   rootCause = (mx.messaging.events::ChannelFaultEvent)#3
 bubbles = false
 cancelable = false
 channel = (mx.messaging.channels::SecureAMFChannel)#4


PLEASE, help me... the whole application i'm working on depend on that.

Thanks
Rafael
 



[flexcoders] Re: float-safe bitwise AND comparison

2009-01-19 Thread Rafael Faria
Thanks Josh.

I kinda managed to get it working.
so for the records if someone else need it, it seems to work fine.


private function 
safeBitCheck(num:Number,comparison:Number):Boolean
{
  if(num < 2147483647 ) {
  return (num & comparison)==comparison;
  } else {
  var binNumber:String = strrev(base_convert(num,10,2));
  var binComparison:String = 
strrev(base_convert(comparison,10,2));
  for(var i:uint=0; i wrote:
>
> Does "result = (uint(number) & uint(comparison))" work?
> 
> -Josh
> 
> 2009/1/20 Rafael Faria 
> 
> >
> > Please,
> >
> > anyone with skills to convert the following php function to flex? i'm
> > killing myself trying...
> >
> > please... anyone?
> >
> > thanks
> > rafael
> >
> > -
> >
> > /**
> > * Perform a float-safe bitwise AND comparison
> > *
> > * @param int/float $number  The number to which to perform a
bitwise AND
> > * @param int/float $comparison  The number with which to perform a
> > bitwise AND
> > * @return bool
> > */
> > function safeBitCheck($number,$comparison) {
> >   if( $number < 2147483647 ) {
> >   return ($number & $comparison)==$comparison;
> >   } else {
> >   $binNumber = strrev(base_convert($number,10,2));
> >   $binComparison = strrev(base_convert($comparison,10,2));
> >   for( $i=0; $i >   if( strlen($binNumber)<$i || ($binComparison{$i}==="1" &&
> > $binNumber{$i}==="0") ) {
> >   return false;
> >   }
> >   }
> >   return true;
> >   }
> > }
> >
> > safeBitCheck(17,16); // true
> > safeBitCheck(17,2); // false
> > safeBitCheck((4294967296+8589934592),4294967296); // true
> > safeBitCheck(2,8589934592); // false
> >
> >
> > 
> >
> > --
> > Flexcoders Mailing List
> > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > Alternative FAQ location:
> >
https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
> > Search Archives:
> > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
> > Links
> >
> >
> >
> >
> 
> 
> -- 
> "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> 
> Like the cut of my jib? Check out my Flex blog!
> 
> :: Josh 'G-Funk' McDonald
> :: 0437 221 380 :: j...@...
> :: http://flex.joshmcdonald.info/
> :: http://twitter.com/sophistifunk
>




[flexcoders] float-safe bitwise AND comparison

2009-01-19 Thread Rafael Faria

Please,

anyone with skills to convert the following php function to flex? i'm
killing myself trying... 

please... anyone?

thanks
rafael

-

/**
* Perform a float-safe bitwise AND comparison
*
* @param int/float $number  The number to which to perform a bitwise AND
* @param int/float $comparison  The number with which to perform a
bitwise AND
* @return bool
*/
function safeBitCheck($number,$comparison) {
   if( $number < 2147483647 ) {
   return ($number & $comparison)==$comparison;
   } else {
   $binNumber = strrev(base_convert($number,10,2));
   $binComparison = strrev(base_convert($comparison,10,2));
   for( $i=0; $i

[flexcoders] Re: Rendering Problem

2008-12-21 Thread Rafael Faria
Any other idea why the rendering problem is happening? I have heaps of
components running at the same time and i have no clue how to debug
what could be wrong that makes the screen flicks.

anyone had problems like that and found a workaround!?

thanks
rafael

--- In flexcoders@yahoogroups.com, "valdhor"  wrote:
>
> Check out this video from Chet Haase:
> 
> http://graphics-geek.blogspot.com/2008/09/video-sorted-details.html
> 
> He talks about turning off autoLayout which can cause flickering.
> 
> --- In flexcoders@yahoogroups.com, "Rafael Faria"
>  wrote:
> >
> > Hello All,
> > 
> > I have a very important question.
> > 
> > What could be causing problems with rendering?! I have this
> > application that every now and than flicks, the background goes white
> > for a second than get back to normal. Its not really something in
> > particular because that happens in a couple of components i create.
> > 
> > One in particular that do pretty much the same as the date, opening a
> > popup on the side, but everytime i open that i get this flickering
> > problem.
> > 
> > Any clue what could be causing that? i know its a very "empty" qustion
> > but maybe someone might give me an idea what often causes flex to
flick.
> > 
> > thanks
> > raf
> >
>




[flexcoders] Rendering Problem

2008-11-30 Thread Rafael Faria
Hello All,

I have a very important question.

What could be causing problems with rendering?! I have this
application that every now and than flicks, the background goes white
for a second than get back to normal. Its not really something in
particular because that happens in a couple of components i create.

One in particular that do pretty much the same as the date, opening a
popup on the side, but everytime i open that i get this flickering
problem.

Any clue what could be causing that? i know its a very "empty" qustion
but maybe someone might give me an idea what often causes flex to flick.

thanks
raf




[flexcoders] Tooltip Errors

2008-11-20 Thread Rafael Faria
Hey all,

There is one thing that is really annoying me for a while.

I have this app that runs a lot of viewstacks, and i have a bunch of
forms and validations applied to them. I use to validate "ON FOCUS
OUT", and the thing is, sometimes i change the views and suddenly the
error tooltip shows up in random places and stays there. 

Is there something to set to do not show the error tooltip when i
change views or is this a bug? 

any ideias? suggestions?!!

Thanks
Rafael




[flexcoders] Re: Binding programmatically

2008-09-24 Thread Rafael Faria
Now i have another problem.

What if the enabled depends on the action of 2 different "hosts"? like
i need to check if myLabel1 == '' and myLabel2 == ''.

i tried to duplicate the same function twice for the same object but
different sources but i dont think that works like this.

anyone has any idea?!

raf

--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> Actually 
> this helped  me
> 
>   BindingUtils.bindProperty(myButton, 
> "enabled", myLabel,
> {name:"text",getter:function(host) { if (host.text == '') { return
> false; } else { return true; } } });
> 
> thanks :)
> 



[flexcoders] Re: Binding programmatically

2008-09-24 Thread Rafael Faria
Actually 
this helped  me

BindingUtils.bindProperty(myButton, 
"enabled", myLabel,
{name:"text",getter:function(host) { if (host.text == '') { return
false; } else { return true; } } });

thanks :)





--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> Sorry, I thought you were trying to update the textcontrols, not the
button
> I misread your first post.
> 
> [Bindable("textBoxUpdated")]
> function get buttonEnabled() : Boolean
> {
>   //
> }
> 
> private var allTextInputs : Array = [];
> 
> //(inside create loop...
> 
>   ti = new TextInput();
>   allTextInputs.push(ti); //Can now look at them from buttonEnabled()
>   ti.addEventListener(ChangeEvent.CHANGE, inputChanged);
> 
> //...)
> 
> private function inputChanged() : void
> {
>   dispatchEvent(new Event("textBoxUpdated"));
> }
> 
> 
> 
> -Josh
> 
> On Thu, Sep 25, 2008 at 12:47 PM, Paul Andrews <[EMAIL PROTECTED]> wrote:
> 
> >  - Original Message -
> >
> > *From:* Aaron Miller <[EMAIL PROTECTED]>
> > *To:* flexcoders@yahoogroups.com
> > *Sent:* Thursday, September 25, 2008 3:45 AM
> > *Subject:* Re: [flexcoders] Re: Binding programmatically
> >
> > But then how would this execute the binding when the text is updated?
> >
> >
> > Yes, you're right. Time to get some sleep!
> >
> >
> > What I would do is use BindingUtils.bindProperty on each TextInput
to set
> > up the bindings in Actionscript.
> >
> >
> > Best Regards,
> > ~Aaron
> >
> > On Wed, Sep 24, 2008 at 7:15 PM, Paul Andrews <[EMAIL PROTECTED]> wrote:
> >>
> >>
> >> Yes, write a function:
> >>
> >> function allNonBlank():Boolean {
> >> for (var i:uint=0; i< this.numChildren; i++) {
> >> if (this.getChildAt(i).text != "") return false;
> >> }
> >> return true;
> >> }
> >>
> >> Then
> >> 
> >>
> >> Haven't tested it - something like that.
> >>
> >> Paul
> >>
> >> > raf
> >>
> >>
> >
> >
> > --
> > Aaron Miller
> > Chief Technology Officer
> > Open Base Interactive, LLC.
> > [EMAIL PROTECTED]
> > http://www.openbaseinteractive.com
> >
> > 
> >
> 
> 
> 
> -- 
> "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> 
> http://flex.joshmcdonald.info/
> 
> :: Josh 'G-Funk' McDonald
> :: 0437 221 380 :: [EMAIL PROTECTED]
>




[flexcoders] Re: Binding programmatically

2008-09-24 Thread Rafael Faria
--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> BindingUtils.bindProperty(ti, "text", sourceObject, "sourceProperty");
> 

How i would add a function to tell what i need to set?

like in my example i want to set the sourceObject.enabled according to
the content of the ti.text.


i tried
BindingUtils.bindProperty(ti,"text",sourceObject,{name:'text',access:function(host){
if (host.text == '') ti.enabled = false; }})

no success.

any ideas?




[flexcoders] Re: Binding programmatically

2008-09-24 Thread Rafael Faria
Wow Josh, i think that's exaclty what i need.

How i would apply the function to this example?

says sourceObject.text != ''

how would i do it? im reading the doc but i didnt quit understood how
it work.

thakns man

raf


--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> BindingUtils.bindProperty(ti, "text", sourceObject, "sourceProperty");
> 
> -Josh
> 



[flexcoders] Re: Binding programmatically

2008-09-24 Thread Rafael Faria
Paul,

thanks for your message but i might not explain it right.

i will have something like this inside my class

var el:Array = new Array('label1','label2','label3');

for(var i:uint = 0;i wrote:
>
> 
> - Original Message - 
> From: "Rafael Faria" <[EMAIL PROTECTED]>
> To: 
> Sent: Thursday, September 25, 2008 2:46 AM
> Subject: [flexcoders] Binding programmatically
> 
> 
> > Hi folks
> >
> > I have a big question.
> >
> > for instance, if i have
> >
> > 
> >
> > 
> >
> >
> > this would mean that if myLabel equals "" my button wil be disabled.
> >
> > What comes to my question.
> >
> > What if myLabel was added programmatically. I mean, what if i create
> > that as myLabel = new Label() but inside a class, so on the mxml side
> > i cant really know what is the instance "myLabel".
> >
> > This is a simple example, but what i have is a lot of TextInput
> > created dynamically and i need to bind some of them to some buttons.
> >
> > how one would do that?
> 
>  label="submit" />
>




[flexcoders] Binding programmatically

2008-09-24 Thread Rafael Faria
Hi folks

I have a big question.

for instance, if i have






this would mean that if myLabel equals "" my button wil be disabled.

What comes to my question.

What if myLabel was added programmatically. I mean, what if i create
that as myLabel = new Label() but inside a class, so on the mxml side
i cant really know what is the instance "myLabel".

This is a simple example, but what i have is a lot of TextInput
created dynamically and i need to bind some of them to some buttons.

how one would do that?




[flexcoders] Re: Changing Root Node attributes

2008-09-08 Thread Rafael Faria
LEGEND! :P

It actually works using .copy() :P

not sure if the right way thou, but look what i've done and let me
know if there is another way to do that.

var rootNode:XML = XML(tree.dataProvider);
var cloneXML:XML =  rootNode.copy();
[EMAIL PROTECTED] = Number(rootNode.attribute('sid').toXMLString())+1;
tree.dataProvider = cloneXML;


working like a charm now :)

raf


--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> Can you change other nodes? It could be something to do with the
source of
> your XML... Perhaps you can .copy() it first?
> 
> -Josh
> 
> On Tue, Sep 9, 2008 at 9:38 AM, Rafael Faria
> <[EMAIL PROTECTED]>wrote:
> 
> > That's the thing. I thought it would but it doesnt.
> >
> > No idea why i can't change the root node of the xml.
> >
> > Any other suggestion?!
> >
> > raf
> >
> >
> > --- In flexcoders@yahoogroups.com, "Josh McDonald"  wrote:
> > >
> > > Have you tried:
> > >
> > > [EMAIL PROTECTED] = "59";
> > >
> > > And it didn't work?
> > >
> > > -Josh
> > >
> > > On Mon, Sep 8, 2008 at 3:46 PM, Rafael Faria
> > > wrote:
> > >
> > > > Hello All,
> > > >
> > > > I need your help again.
> > > >
> > > > I make a call and get in return a XML. With this XML, i feed
my tree's
> > > > dataprovider. It is something like this:
> > > >
> > > > 
> > > >  
> > > >  
> > > >  
> > > >  
> > > >  
> > > >  
> > > > 
> > > >
> > > > The thing is, at some point i need to get the "sids" from the root
> > > > node (so far no problem, i'm using
> > > > XML(tree.dataProvider).attribute('sids').toXMLString() and it
works)
> > > > but the catch is that i need to change it to 59 and i can't
manage to
> > > > change it no matter what.
> > > >
> > > > Any one could throw some ideas so i can solve my problem ?
please? :P
> > > >
> > > > thanks
> > > > Raf
> > > >
> > > >
> > > >
> > > > 
> > > >
> > > > --
> > > > Flexcoders Mailing List
> > > > FAQ:
http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > > > Search Archives:
> > > > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo!
Groups
> > > > Links
> > > >
> > > >
> > > >
> > > >
> > >
> > >
> > > --
> > > "Therefore, send not to know For whom the bell tolls. It tolls for
> > thee."
> > >
> > > http://flex.joshmcdonald.info/
> > >
> > > :: Josh 'G-Funk' McDonald
> > > :: 0437 221 380 :: josh@
> > >
> >
> >
> >
> > 
> >
> > --
> > Flexcoders Mailing List
> > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > Search Archives:
> > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
> > Links
> >
> >
> >
> >
> 
> 
> -- 
> "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> 
> http://flex.joshmcdonald.info/
> 
> :: Josh 'G-Funk' McDonald
> :: 0437 221 380 :: [EMAIL PROTECTED]
>




[flexcoders] Re: Changing Root Node attributes

2008-09-08 Thread Rafael Faria
That's the thing. I thought it would but it doesnt.

No idea why i can't change the root node of the xml.

Any other suggestion?!

raf


--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> Have you tried:
> 
> [EMAIL PROTECTED] = "59";
> 
> And it didn't work?
> 
> -Josh
> 
> On Mon, Sep 8, 2008 at 3:46 PM, Rafael Faria
> <[EMAIL PROTECTED]>wrote:
> 
> > Hello All,
> >
> > I need your help again.
> >
> > I make a call and get in return a XML. With this XML, i feed my tree's
> > dataprovider. It is something like this:
> >
> > 
> >  
> >  
> >  
> >  
> >  
> >  
> > 
> >
> > The thing is, at some point i need to get the "sids" from the root
> > node (so far no problem, i'm using
> > XML(tree.dataProvider).attribute('sids').toXMLString() and it works)
> > but the catch is that i need to change it to 59 and i can't manage to
> > change it no matter what.
> >
> > Any one could throw some ideas so i can solve my problem ? please? :P
> >
> > thanks
> > Raf
> >
> >
> >
> > 
> >
> > --
> > Flexcoders Mailing List
> > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > Search Archives:
> > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
> > Links
> >
> >
> >
> >
> 
> 
> -- 
> "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> 
> http://flex.joshmcdonald.info/
> 
> :: Josh 'G-Funk' McDonald
> :: 0437 221 380 :: [EMAIL PROTECTED]
>




[flexcoders] Changing Root Node attributes

2008-09-07 Thread Rafael Faria
Hello All,

I need your help again.

I make a call and get in return a XML. With this XML, i feed my tree's
dataprovider. It is something like this:


  
  
  
  
  
  


The thing is, at some point i need to get the "sids" from the root
node (so far no problem, i'm using
XML(tree.dataProvider).attribute('sids').toXMLString() and it works) 
but the catch is that i need to change it to 59 and i can't manage to
change it no matter what.

Any one could throw some ideas so i can solve my problem ? please? :P

thanks
Raf




[flexcoders] AdvancedDataGrid - Grouping Question

2008-08-19 Thread Rafael Faria
Ok, sorry about my last post, it was really my fault. But i hope that
someone help me with this.

I have the following Array Collection 

ArrayCollection
- ITEM 1
   - field1 = "laljlajdk";
   - field2 = "kaskljsad";
   - field3 = "jaskjdlkaskld"
   - field4 = (Object)
- object1 
  - field1 = "akjkd"
  - field2 = "akjkd"
  - field3 = "akjkd"
- object2 
  - field1 = "akjkd"
  - field2 = "akjkd"
  - field3 = "akjkd"
   
   - field5 = "jaskjdlkaskld"
   - field6 = "jaskjdlkaskld"
   - field7 = (Object)
  - field1 = "akjkd"
  - field2 = "akjkd"
  - field3 = "akjkd"
   - field8 = "aksjkldas"
   - field9 = "akjdlkasj"
- ITEM 2
   - field1 = "laljlajdk";
   - field2 = "kaskljsad";
   - field3 = "jaskjdlkaskld"
   - field4 = (Object)
- object1 
  - field1 = "akjkd"
  - field2 = "akjkd"
  - field3 = "akjkd"
- object2 
  - field1 = "akjkd"
  - field2 = "akjkd"
  - field3 = "akjkd"
   
   - field5 = "jaskjdlkaskld"
   - field6 = "jaskjdlkaskld"
   - field7 = (Object)
  - field1 = "akjkd"
  - field2 = "akjkd"
  - field3 = "akjkd"
   - field8 = "aksjkldas"
   - field9 = "akjdlkasj"

 and so on...
first question is, 

how can i display this data grouped exactly the way it is on an
advanced datagrid?

secondly, if i set the advancedcolumns to be

|ITEM 1 |field4  |
field1 | field2 |field3 |   field1   | field2 |  field3 |   
 

How do i associate the the fields that are under field4 to their columns?

I know it might sounds confusing, but believe me, advanced datagrids
is giving me headaches.

;P

Any ideas?
raf



[flexcoders] SOLVED Re: AdvancedDataGridColumn labelFunction

2008-08-19 Thread Rafael Faria
Sorry about this post. I have solved this problem.

Raf


--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> Hey guys,
> 
> me again :)
> 
> I'm building an advanceddatagrid and i got to a problem.
> 
> my dataprovider is an arraycollection of objects with objects inside
> objects.
> ok let me simplify.
> 
> its something like
> 
> ArrayCollection
>   - Array
>  - Object 1
> - field 1
> - field 2
> - field 3 (object)
>- field 1
>- field 2
> - field 4
> 
>  - Object 2
> - field 1
> - field 2
> - field 3 (object)
>- field 1
>- field 2
> - field 4
> 
> 
> and so on...
> 
> when i try to test it, using the labelFunction like the following code
> 
> advColumn.labelFunction = function(item:Object,
> column:AdvancedDataGridColumn):String {
>   trace(ObjectUtil.toString(item));
>   return null;
> }
> 
> my trace comes something like
> Object
>- field 1 = "bla bla";
>- field 2 = "foo foo";
>- field 3 = "[Object Object]";
>- field 4 = "boo boo";
> 
> 
> My question is, why flex convert my object on field 3 to "string"?
> shouldnt it just preserve the value?
> 
> how can i get that object.field3 as an object inside the labelFunction?
> 
> thanks
> 
> raf
>




[flexcoders] AdvancedDataGridColumn labelFunction

2008-08-19 Thread Rafael Faria
Hey guys,

me again :)

I'm building an advanceddatagrid and i got to a problem.

my dataprovider is an arraycollection of objects with objects inside
objects.
ok let me simplify.

its something like

ArrayCollection
  - Array
 - Object 1
- field 1
- field 2
- field 3 (object)
   - field 1
   - field 2
- field 4

 - Object 2
- field 1
- field 2
- field 3 (object)
   - field 1
   - field 2
- field 4


and so on...

when i try to test it, using the labelFunction like the following code

advColumn.labelFunction = function(item:Object,
column:AdvancedDataGridColumn):String {
trace(ObjectUtil.toString(item));
return null;
}

my trace comes something like
Object
   - field 1 = "bla bla";
   - field 2 = "foo foo";
   - field 3 = "[Object Object]";
   - field 4 = "boo boo";


My question is, why flex convert my object on field 3 to "string"?
shouldnt it just preserve the value?

how can i get that object.field3 as an object inside the labelFunction?

thanks

raf



[flexcoders] Re: Advise - List

2008-08-07 Thread Rafael Faria
I do want the html in a redender. This was just an example that i was
trying to play. That would be my item renderer. anyway, somehow i get
it working... :p


--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> I thought you wanted html in a renderer.  If so, copy ListItemRenderer
> and modify to set the htmlText instead of text.
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Thursday, August 07, 2008 12:22 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Advise - List
> 
> 
> 
> Yeah...
> 
> It would be something like this. If you run it you will see that the
> measure is wrong. It just gets right when you start typing.
> 
> 
> http://www.adobe.com/2006/mxml
> <http://www.adobe.com/2006/mxml> "
> creationComplete="update();">
> 
> 
> 
>  width="75%" paddingTop="10" paddingLeft="10">
> 
> 
> 
> 
> 
> 
> 
> 
>  
> 
> --- In flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> , "Josh McDonald"  wrote:
> >
> > Rafael - do you have an example small enough to post here so we can
> have a
> > look-see?
> > 
> > -Josh
> >
>




[flexcoders] Re: Advise - List

2008-08-07 Thread Rafael Faria
Yeah...

It would be something like this. If you run it you will see that the
measure is wrong. It just gets right when you start typing.


http://www.adobe.com/2006/mxml";
creationComplete="update();">

   
   









 

--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> Rafael - do you have an example small enough to post here so we can
have a
> look-see?
> 
> -Josh
> 





[flexcoders] Re: Advise - List

2008-08-06 Thread Rafael Faria
I need it to be 100%... its on a component that goes in different
places on my application. I can't set it =/

Any other idea?

I'm trying to set the textarea's height when i load it but it doesnt
seem to be getting the right height.

I tested a simple example like the following one and if you run it you
will see that when you open its bigger than the text but when you
start typing it gets back to the right size.


http://www.adobe.com/2006/mxml";
creationComplete="update();">

   
   









 



--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> Text will wrap, but only if you tell it how wide it should be.
> 
> -Josh
> 
> On Thu, Aug 7, 2008 at 12:59 PM, Rafael Faria
> <[EMAIL PROTECTED]>wrote:
> 
> > Hey guys,
> >
> > I need some advise.
> >
> > I'm creating a list and i need to insert some HTML text (i need to use
> > bold) and it needs to wordwrap it.
> >
> > I tried Text but it doesnt seem to have wordwrap capability. The only
> > reason i found so far is use a Textarea and take off the borders and
> > background and not let it be editable. It works how i want but with a
> > little problem, the variable row doesnt seem to be working. My guess
> > would be that my textarea is not increasing according the size of the
> > text in the textarea.
> >
> > Is there anyway to set the textarea height according to the content it
> > has or anyother suggestion to make this html wordwrap itemrenderer
> > inside the list work?1
> >
> > Please, enlight me. :p
> >
> > raf
> >
> >
> >
> > 
> >
> > --
> > Flexcoders Mailing List
> > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > Search Archives:
> > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
> > Links
> >
> >
> >
> >
> 
> 
> -- 
> "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> 
> :: Josh 'G-Funk' McDonald
> :: 0437 221 380 :: [EMAIL PROTECTED]
>




[flexcoders] Advise - List

2008-08-06 Thread Rafael Faria
Hey guys,

I need some advise.

I'm creating a list and i need to insert some HTML text (i need to use
bold) and it needs to wordwrap it.

I tried Text but it doesnt seem to have wordwrap capability. The only
reason i found so far is use a Textarea and take off the borders and
background and not let it be editable. It works how i want but with a
little problem, the variable row doesnt seem to be working. My guess
would be that my textarea is not increasing according the size of the
text in the textarea.

Is there anyway to set the textarea height according to the content it
has or anyother suggestion to make this html wordwrap itemrenderer
inside the list work?1

Please, enlight me. :p

raf




[flexcoders] Re: Multiple Lists

2008-08-03 Thread Rafael Faria
Ok... got it working the way i wanted. Maybe it's useful to someone else.


var dumm:ArrayCollection = new ArrayCollection(['Test1','Test2','Test3']);
var hhbox:HBox = new HBox();
hhbox.percentWidth = 100;

var list1:List = new List();
list1.percentWidth = 50;
list1.dataProvider = dumm;
list1.allowMultipleSelection = true;
list1.dropEnabled = true;
list1.dragEnabled = true;
list1.dragMoveEnabled = true;
list1.setStyle("alternatingItemColors",["#FF", "#EE"]);
list1.name = value.fieldname + '_source';
list1.id = value.fieldname + '_source';

list1.addEventListener(DragEvent.DRAG_DROP,function(e:DragEvent):void 
{
e.currentTarget.hideDropFeedback(e);
});

list1.addEventListener(DragEvent.DRAG_OVER,function(e:DragEvent):void 
{
if (e.target.id.replace('_source','') ==
List(e.dragInitiator).id.replace('_source','')) 
{
e.currentTarget.showDropFeedback(e);
DragManager.showFeedback(DragManager.MOVE);
} 
else 
{
e.currentTarget.hideDropFeedback(e);
e.preventDefault();
}
});

list1.addEventListener(DragEvent.DRAG_EXIT,function(e:DragEvent):void {
e.currentTarget.hideDropFeedback(e);
});


var list2:List = new List();
list2.percentWidth = 50;
list2.dataProvider = new ArrayCollection();
list2.allowMultipleSelection = true;
list2.dropEnabled = true;
list2.dragEnabled = true;
list2.dragMoveEnabled = true;
list2.setStyle("alternatingItemColors",["#FF", "#EE"]);
list2.name = value.fieldname;
list2.id = value.fieldname;
list2.addEventListener(DragEvent.DRAG_DROP,function(e:DragEvent):void 
{
e.currentTarget.hideDropFeedback(e);
});

list2.addEventListener(DragEvent.DRAG_OVER,function(e:DragEvent):void 
{


if (e.target.id == List(e.dragInitiator).id.replace('_source','')) 
{
e.currentTarget.showDropFeedback(e);
DragManager.showFeedback(DragManager.MOVE);
} 
else 
{
e.currentTarget.hideDropFeedback(e);
e.preventDefault();
}
});

list2.addEventListener(DragEvent.DRAG_EXIT,function(e:DragEvent):void {
e.currentTarget.hideDropFeedback(e);
});

hhbox.addChild(list1);
hhbox.addChild(list2);

addChild(hhbox);

--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> I got this working, but if it doesnt use the builtin events when i
> drop it. I just disapear with the items i'm dragging. 
> 
> I don't want to create new function to the drop event, i want to use
> the builtin one. Any idea why?!
> 
> Alex, anything you can help me with this code so i can keep using the
> builtin dragdrop events and just specify the list i want to interact?
> 
> DragManager.showFeedback(DragManager.MOVE) doesn't seem to be working
> if you don't put the DragManager in the Enter event. 
> 
> =/
> 
> 
> var dumm:ArrayCollection = new
ArrayCollection(['Test1','Test2','Test3']);
> var hhbox:HBox = new HBox();
> hhbox.percentWidth = 100;
> 
> var list1:List = new List();
> list1.percentWidth = 50;
> list1.dataProvider = dumm;
> list1.allowMultipleSelection = true;
> list1.dropEnabled = false;
> list1.dragEnabled = true;
> list1.dragMoveEnabled = true;
> list1.setStyle("alternatingItemColors",["#FF", "#EE"]);
> list1.name = value.fieldname + '_source';
> list1.id = value.fieldname + '_source';
> list1.addEventListener(DragEvent.DRAG_ENTER,function(e:DragEvent):void {
>   DragManager.acceptDragDrop(UIComponent(e.currentTarget));
> });
> 
> list1.addEventListener(DragEvent.DRAG_OVER,function(e:DragEvent):void 
> {
>   if (e.target.id == List(e.dragInitiator).id + '_source') {
>   DragManager.showFeedback(DragManager.MOVE);
>   } else {
>   DragManager.showFeedback(DragManager.NONE);
>   return;
>   }
> });
> 
> 
> var list2:List = new List();
> list2.percentWidth = 50;
> list2.dataProvider = new ArrayCollection();
> list2.allowMultipleSelection = true;
> list2.dropEnabled = false;
> list2.dragEnabled = true;
> list2.dragMoveEnabled = true;
> list2.setStyle("alternatingItemColors",["#FF", "#EE"]);
> list2.name = value.fieldname;
> list2.id = value.fieldname;
> list2.addEventListener(DragEvent.DRAG_ENTER,function(e:DragEvent):void {
>   DragManager.acceptDragDrop(UIComponent(e.currentTarget));
> });
> 
> list2.addEventListener(DragEvent.DRAG_OVER,function(e:DragEvent):void

[flexcoders] Re: Multiple Lists

2008-08-03 Thread Rafael Faria
I got this working, but if it doesnt use the builtin events when i
drop it. I just disapear with the items i'm dragging. 

I don't want to create new function to the drop event, i want to use
the builtin one. Any idea why?!

Alex, anything you can help me with this code so i can keep using the
builtin dragdrop events and just specify the list i want to interact?

DragManager.showFeedback(DragManager.MOVE) doesn't seem to be working
if you don't put the DragManager in the Enter event. 

=/


var dumm:ArrayCollection = new ArrayCollection(['Test1','Test2','Test3']);
var hhbox:HBox = new HBox();
hhbox.percentWidth = 100;

var list1:List = new List();
list1.percentWidth = 50;
list1.dataProvider = dumm;
list1.allowMultipleSelection = true;
list1.dropEnabled = false;
list1.dragEnabled = true;
list1.dragMoveEnabled = true;
list1.setStyle("alternatingItemColors",["#FF", "#EE"]);
list1.name = value.fieldname + '_source';
list1.id = value.fieldname + '_source';
list1.addEventListener(DragEvent.DRAG_ENTER,function(e:DragEvent):void {
DragManager.acceptDragDrop(UIComponent(e.currentTarget));
});

list1.addEventListener(DragEvent.DRAG_OVER,function(e:DragEvent):void 
{
if (e.target.id == List(e.dragInitiator).id + '_source') {
DragManager.showFeedback(DragManager.MOVE);
} else {
DragManager.showFeedback(DragManager.NONE);
return;
}
});


var list2:List = new List();
list2.percentWidth = 50;
list2.dataProvider = new ArrayCollection();
list2.allowMultipleSelection = true;
list2.dropEnabled = false;
list2.dragEnabled = true;
list2.dragMoveEnabled = true;
list2.setStyle("alternatingItemColors",["#FF", "#EE"]);
list2.name = value.fieldname;
list2.id = value.fieldname;
list2.addEventListener(DragEvent.DRAG_ENTER,function(e:DragEvent):void {
DragManager.acceptDragDrop(UIComponent(e.currentTarget));
});

list2.addEventListener(DragEvent.DRAG_OVER,function(e:DragEvent):void 
{

if (e.target.id == List(e.dragInitiator).id.replace('_source','')) {
DragManager.showFeedback(DragManager.MOVE);
} else {
DragManager.showFeedback(DragManager.NONE);
return;
}
});

hhbox.addChild(list1);
hhbox.addChild(list2);



--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> dragInitiator in the dragEvent
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Sunday, August 03, 2008 7:57 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Multiple Lists
> 
> 
> 
> I have multiple lists and i want one drag to another.
> 
> The drag and drop is already working. My problem is that i have like
> 10 lists and any of them can drag to any other.
> 
> Is there an easy way to set what list it can come from?
> 
> like
> 
> list1 can just receive dragable item from list2 and vice-versa. 
> 
> list3 can jusst receive from list4 and vice-versa.
> 
> list5 from list6. 
> 
> and so on.
> 
> What is the best way to work with drag and drop between lists? the
> native one or using the dragmanager?
> 
> Thanks :p
>




[flexcoders] Multiple Lists

2008-08-03 Thread Rafael Faria
I have multiple lists and i want one drag to another.

The drag and drop is already working. My problem is that i have like
10 lists and any of them can drag to any other.

Is there an easy way to set what list it can come from?

like

list1 can just receive dragable item from list2 and vice-versa. 

list3 can jusst receive from list4 and vice-versa.

list5 from list6. 

and so on.



What is the best way to work with drag and drop between lists? the
native one or using the dragmanager?

Thanks :p




[flexcoders] Re: rendering problem

2008-07-31 Thread Rafael Faria
I can't post the app sorry but any reason why the UI could be
deforming while you scroll?! anyone else had this problem before?

raf


--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> Can you post the app?  I probably won't be able to look until tomorrow
> (for me).  Add "view source" if you can.  It isn't clear what you are
> scrolling or how you've set up the UI.
> 
>  
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Wednesday, July 23, 2008 9:50 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: rendering problem
> 
>  
> 
> Well.. in the first one it's easy to see the difference. There is a
> separator between 2 screens, one is when i load it, the second is when
> i scroll down the page and than come back to the document. It repeats
> the dropdowns, some times textinputs gets crazy and disapear but when
> you mouse over them it back up.
> 
> The second one its the datagrids.
> 
> http://www.enilsson.com/assets/examples/rendering2.png
> <http://www.enilsson.com/assets/examples/rendering2.png> 
> 
> i circled this time so you can notice.
> 
> It happens when i have a big scroll and scroll up and down.
> 
> Any idea?
> 
> Rafael
> 
> --- In flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> , "Alex Harui"  wrote:
> >
> > I can't tell from the pictures what is wrong.
> > 
> > 
> > 
> > 
> > 
> > From: flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> [mailto:flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> ] On
> > Behalf Of Rafael Faria
> > Sent: Wednesday, July 23, 2008 5:37 PM
> > To: flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com> 
> > Subject: [flexcoders] Re: rendering problem
> > 
> > 
> > 
> > Alex,
> > 
> > Because i knew you would say to check your blog i had done this before
> > write it here. I couldn't find anything about rendering problems. The
> > only thing i found there was about item renderered and i don't use any
> > on this case.
> > 
> > Any other suggestion?
> > 
> > Rafael
> > 
> > --- In flexcoders@yahoogroups.com
> <mailto:flexcoders%40yahoogroups.com>
> <mailto:flexcoders%40yahoogroups.com>
> > , "Alex Harui"  wrote:
> > >
> > > I don't have time to look, but usually, there are issues with
> renderer
> > > recycling and/or rendering measurement. Have you read through the
> > posts
> > > on my blog?
> > > 
> > > 
> > > 
> > > 
> > > 
> > > From: flexcoders@yahoogroups.com
> <mailto:flexcoders%40yahoogroups.com>
> <mailto:flexcoders%40yahoogroups.com>
> > [mailto:flexcoders@yahoogroups.com
> <mailto:flexcoders%40yahoogroups.com>
> <mailto:flexcoders%40yahoogroups.com>
> > ] On
> > > Behalf Of Rafael Faria
> > > Sent: Tuesday, July 22, 2008 8:35 PM
> > > To: flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> <mailto:flexcoders%40yahoogroups.com> 
> > > Subject: [flexcoders] rendering problem
> > > 
> > > 
> > > 
> > > I'm not sure how many of you guys had this problem before but for
> some
> > > reason im getting a rendering problem with forms and datagrid and i
> > > have no ideia how to solve it.
> > > 
> > > Check this example
> > > the first part is the right one, after i scroll up and down, it gets
> > > all mess up.
> > > http://www.enilsson.com/assets/examples/rendering.png
> <http://www.enilsson.com/assets/examples/rendering.png> 
> > <http://www.enilsson.com/assets/examples/rendering.png
> <http://www.enilsson.com/assets/examples/rendering.png> > 
> > > <http://www.enilsson.com/assets/examples/rendering.png
> <http://www.enilsson.com/assets/examples/rendering.png> 
> > <http://www.enilsson.com/assets/examples/rendering.png
> <http://www.enilsson.com/assets/examples/rendering.png> > > 
> > > 
> > > This one is how it deformed the datagrids.
> > > http://www.enilsson.com/assets/examples/rendering2.png
> <http://www.enilsson.com/assets/examples/rendering2.png> 
> > <http://www.enilsson.com/assets/examples/rendering2.png
> <http://www.enilsson.com/assets/examples/rendering2.png> > 
> > > <http://www.enilsson.com/assets/examples/rendering2.png
> <http://www.enilsson.com/assets/examples/rendering2.png> 
> > <http://www.enilsson.com/assets/examples/rendering2.png
> <http://www.enilsson.com/assets/examples/rendering2.png> > > 
> > > 
> > > Any idea how to fix that?
> > > it's killing me.
> > > 
> > > raf
> > >
> >
>




[flexcoders] Re: Checking if an object exists

2008-07-29 Thread Rafael Faria
For instance

parentApplication.appData['moduleParams'].table_name


'moduleParams' is an object as well. it might not exist, and
table_name might not exist... i need to test if table_name exists...

anything i put it returns

Error: Error #1009: Cannot access a property or method of a null
object reference.
at...


i tried
if ((parentApplication.appData['moduleParams'] == null) ||
(!parentApplication.appData['moduleParams'].moduleFrom)) {
}

i tried

if ((!parentApplication.appData.hasOwnProperty('moduleParams')) ||
(!parentApplication.appData.hasOwnProperty('moduleParams').moduleFrom)) {
}

or

if ((!('moduleParams' in parentApplication.appData)) ||
(!('moduleFrom' in parentApplication.appData['moduleParams']))) {
}

same error...

anyone can help me how i would test if 

parentApplication.appData['moduleParams'].table_name
exists?


rafael




--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> If it's an array, then you want:
> 
> if(archive[record_id].length > 1)
> {
> //do stuff
> }
> 
> -Josh
> 
> On Tue, Jul 29, 2008 at 2:05 PM, Rafael Faria
> <[EMAIL PROTECTED]>wrote:
> 
> > Hello all,
> >
> > I'm here for one of my questions again :P
> >
> > I need to make a  comparison  like this
> >
> > if (archive[record_id][1].deleted_id == deleted_id) {
> >
> > }
> > My problem is that [1].deleted_id might not exist at this point.
> >
> > I know that archive[record_id] exists so how can i make this
> > comparison above?
> >
> > [1] might not exists and i can't use hasOwnProperty("1") because it
> > throws an error as well.
> >
> > can someone help me?! :P
> >
> > raf
> >
> >
> >
> > 
> >
> > --
> > Flexcoders Mailing List
> > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > Search Archives:
> > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
> > Links
> >
> >
> >
> >
> 
> 
> -- 
> "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> 
> :: Josh 'G-Funk' McDonald
> :: 0437 221 380 :: [EMAIL PROTECTED]
>




[flexcoders] Checking if an object exists

2008-07-28 Thread Rafael Faria
Hello all,

I'm here for one of my questions again :P

I need to make a  comparison  like this

if (archive[record_id][1].deleted_id == deleted_id) {

}
My problem is that [1].deleted_id might not exist at this point.

I know that archive[record_id] exists so how can i make this
comparison above?

[1] might not exists and i can't use hasOwnProperty("1") because it
throws an error as well.

can someone help me?! :P

raf




[flexcoders] Re: new Component() ?

2008-07-24 Thread Rafael Faria
I found this class

package modules.renderers
{
import mx.core.ClassFactory;

import org.osflash.thunderbolt.Logger;

public class InitFactory extends ClassFactory
{
private var initObject:Object;

public function InitFactory(generator:Class, initObject:Object)
{
super(generator);
this.initObject = initObject;
}

public override function newInstance():*
{
var result:* = super.newInstance();

for(var propertyName:String in initObject)
{
try
{
result[propertyName] = 
initObject[propertyName];
}catch (e:Error)
{
trace(e.message);
}
}
return result;
}
}
}


and i'm able to add a new class on the fly doing


dgc.itemRenderer = new InitFactory(TextInput, {text:'Value inside the
text input'});


now i'm struggling to make the textinput, to get values from the
"data" variable coming from the dataProvider. You know, when inside
the itemrender you can use {data.firstname + ' ' + data.lastname}
like: 

With the example i gave above, how i would do that?

Raf



Any idea how i would pass this data to the checkbox label 




--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> You can't add to the class definition of the Canvas at runtime.
> ClassFactory has a properties bag where you can have properties slapped
> on the new instance, but that's not really a new class definition.
> 
>  
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Amy
> Sent: Thursday, July 24, 2008 7:36 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: new Component() ?
> 
>  
> 
> --- In flexcoders@yahoogroups.com 
> , "Alex Harui"  wrote:
> >
> > If you've defined a component via , the name is
> > auto-generated as Josh says, but it generates an IFactory, so you 
> can
> > use the factory to get new instances
> > 
> > 
> > 
> >  for anything other than setting global properties on a class I 
> created in AS3 or MXML.
> 
> Is this a correct interpretation of how AS3 works?
> 
> Thanks;
> 
> Amy
>




[flexcoders] Re: new Component() ?

2008-07-24 Thread Rafael Faria
Amy,
and how would you add elements to the canvas?! or to the itemrender
itself? because the myRenderer wont have addChild so i can add new
elements. And how do you change the properties of the Canvas? You
adding the Class but you aint adding the whole component i was talking
about. 

Suppose that i want to create for instance



   

  
   



How i would create this on the fly and add to the itemrenderer?

this is just to ilustrate what i want. I will need to create different
components according to the parameters of my variables that's the
reason i'm struggling to do it dynamically.

If i only knew how to do this from AS3 it would help me a lot.

Thanks


> This makes it sound like the equivalent to new Component() in AS 
> might be
> 
> myRenderer:ClassFactory = new ClassFactory(mx.containers.Canvas);
> 
> Presumably from there you can add stuff to myRenderer before using it 
> as your "rubber stamp", but I've never personally used ClassFactory 
> for anything other than setting global properties on a class I 
> created in AS3 or MXML.
> 
> Is this a correct interpretation of how AS3 works?
> 
> Thanks;
> 
> Amy
>





[flexcoders] Re: rendering problem

2008-07-23 Thread Rafael Faria
Well.. in the first one it's easy to see the difference. There is a
separator between 2 screens, one is when i load it, the second is when
i scroll down the page and than come back to the document. It repeats
the dropdowns, some times textinputs gets crazy and disapear but when
you mouse over them it back up.

The second one its the datagrids.

http://www.enilsson.com/assets/examples/rendering2.png

i circled this time so you can notice.

It happens when i have a big scroll and scroll up and down.


Any idea?


Rafael


--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> I can't tell from the pictures what is wrong.
> 
>  
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Wednesday, July 23, 2008 5:37 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: rendering problem
> 
>  
> 
> Alex,
> 
> Because i knew you would say to check your blog i had done this before
> write it here. I couldn't find anything about rendering problems. The
> only thing i found there was about item renderered and i don't use any
> on this case.
> 
> Any other suggestion?
> 
> Rafael
> 
> --- In flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> , "Alex Harui"  wrote:
> >
> > I don't have time to look, but usually, there are issues with renderer
> > recycling and/or rendering measurement. Have you read through the
> posts
> > on my blog?
> > 
> > 
> > 
> > ________
> > 
> > From: flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> [mailto:flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> ] On
> > Behalf Of Rafael Faria
> > Sent: Tuesday, July 22, 2008 8:35 PM
> > To: flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com> 
> > Subject: [flexcoders] rendering problem
> > 
> > 
> > 
> > I'm not sure how many of you guys had this problem before but for some
> > reason im getting a rendering problem with forms and datagrid and i
> > have no ideia how to solve it.
> > 
> > Check this example
> > the first part is the right one, after i scroll up and down, it gets
> > all mess up.
> > http://www.enilsson.com/assets/examples/rendering.png
> <http://www.enilsson.com/assets/examples/rendering.png> 
> > <http://www.enilsson.com/assets/examples/rendering.png
> <http://www.enilsson.com/assets/examples/rendering.png> > 
> > 
> > This one is how it deformed the datagrids.
> > http://www.enilsson.com/assets/examples/rendering2.png
> <http://www.enilsson.com/assets/examples/rendering2.png> 
> > <http://www.enilsson.com/assets/examples/rendering2.png
> <http://www.enilsson.com/assets/examples/rendering2.png> > 
> > 
> > Any idea how to fix that?
> > it's killing me.
> > 
> > raf
> >
>




[flexcoders] Re: rendering problem

2008-07-23 Thread Rafael Faria
Alex,

Because i knew you would say to check your blog i had done this before
write it here. I couldn't find anything about rendering problems. The
only thing i found there was about item renderered and i don't use any
on this case.

Any other suggestion?

Rafael


--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> I don't have time to look, but usually, there are issues with renderer
> recycling and/or rendering measurement.  Have you read through the posts
> on my blog?
> 
>  
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Tuesday, July 22, 2008 8:35 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] rendering problem
> 
>  
> 
> I'm not sure how many of you guys had this problem before but for some
> reason im getting a rendering problem with forms and datagrid and i
> have no ideia how to solve it.
> 
> Check this example
> the first part is the right one, after i scroll up and down, it gets
> all mess up.
> http://www.enilsson.com/assets/examples/rendering.png
> <http://www.enilsson.com/assets/examples/rendering.png> 
> 
> This one is how it deformed the datagrids.
> http://www.enilsson.com/assets/examples/rendering2.png
> <http://www.enilsson.com/assets/examples/rendering2.png> 
> 
> Any idea how to fix that?
> it's killing me.
> 
> raf
>




[flexcoders] Re: new Component() ?

2008-07-23 Thread Rafael Faria
Hi Pedro,

How do you mean about putting some getters? Can you give me an example?

Thanks
Raf


--- In flexcoders@yahoogroups.com, "Pedro Sena" <[EMAIL PROTECTED]> wrote:
>
> Hi Rafael,
> 
> What do u think of put some getters in your object instead of create
various
> item renderers that just have little funcionality ?
> 
> Just my 2 cents
> 



[flexcoders] Re: new Component() ?

2008-07-23 Thread Rafael Faria
I would but i wan't to do it FROM actionscript and not from the mxml.
Like i said i want it being created on the fly.

How would you do that from actionscript?

Rafael


--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> I don't see why you don't just use  like in your first
> example? You don't need to make any extra files. Or are you building
your
> entire datagrid programatically?
> 
> -Josh
> 
> On Thu, Jul 24, 2008 at 9:16 AM, Rafael Faria <[EMAIL PROTECTED]>
> wrote:
> 
> > Hi Johannes,
> >
> > Thanks for your reply but my question isn't really about how to put
> > the columns into the datagrid. It's actually how to create dynamically
> > components to put inside the columns.
> >
> > See i don't want to create 4,5,6,7 different itemrenderes files so i
> > can insert into the columns i would create them on the fly,
> > programmatically  .  Does it make sense?
> >
> > Anyone have some idea about it?!
> >
> > Thanks
> > Raf
> >
> >
> > --- In flexcoders@yahoogroups.com, "Johannes Nel" 
> > wrote:
> > >
> > > wiht the datagrid you put the datagridcolumns into an array and then
> > set the
> > > datagrid.columns property
> > >
> > > On Wed, Jul 23, 2008 at 8:47 AM, Rafael Faria 
> > > wrote:
> > >
> > > >   Is there anyway to create "components" on the fly?
> > > >
> > > > Let me explain what i mean.
> > > >
> > > > I have a datagrid that has like 5 columns. Each one of them use a
> > > > different itemrenderer.
> > > >
> > > > I understand that i can create each itemrenderer on a
different file
> > > > but what if i don't want to create files?
> > > >
> > > > is there anyway to transform the following code in a
dynamically code
> > > > without create any files?
> > > >
> > > > 
> > > > 
> > > > 
> > > > 
> > > > 
> > > > 
> > > > 
> > > >
> > > > ??
> > > > How can i do that without creating any other files? i would
imagine
> > > > something like
> > > >
> > > > var dgc:DataGridColumn = new DataGridColumn();
> > > > var mycomponent:Component = new Component();
> > > > var txt:Text = new Text();
> > > > txt.text = "Somthing here";
> > > > mycomponent.addChild(txt);
> > > >
> > > > var render:ClassFactory = new ClassFactory(mycomponent);
> > > > dcg.itemRender = render;
> > > >
> > > > i know that this code doesnt work but it's just to have an idea of
> > > > what i was thinking.
> > > >
> > > > Is there anyway to do that?
> > > >
> > > > Thanks
> > > > Rafael
> > > >
> > > >
> > > >
> > >
> > >
> > >
> > > --
> > > j:pn
> > > \\no comment
> > >
> >
> >
> >
> > 
> >
> > --
> > Flexcoders Mailing List
> > FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> > Search Archives:
> > http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
> > Links
> >
> >
> >
> >
> 
> 
> -- 
> "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> 
> :: Josh 'G-Funk' McDonald
> :: 0437 221 380 :: [EMAIL PROTECTED]
>




[flexcoders] Re: new Component() ?

2008-07-23 Thread Rafael Faria
Hi Johannes,

Thanks for your reply but my question isn't really about how to put
the columns into the datagrid. It's actually how to create dynamically
components to put inside the columns.

See i don't want to create 4,5,6,7 different itemrenderes files so i
can insert into the columns i would create them on the fly,
programmatically  .  Does it make sense? 

Anyone have some idea about it?!

Thanks
Raf


--- In flexcoders@yahoogroups.com, "Johannes Nel" <[EMAIL PROTECTED]>
wrote:
>
> wiht the datagrid you put the datagridcolumns into an array and then
set the
> datagrid.columns property
> 
> On Wed, Jul 23, 2008 at 8:47 AM, Rafael Faria <[EMAIL PROTECTED]>
> wrote:
> 
> >   Is there anyway to create "components" on the fly?
> >
> > Let me explain what i mean.
> >
> > I have a datagrid that has like 5 columns. Each one of them use a
> > different itemrenderer.
> >
> > I understand that i can create each itemrenderer on a different file
> > but what if i don't want to create files?
> >
> > is there anyway to transform the following code in a dynamically code
> > without create any files?
> >
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> >
> > ??
> > How can i do that without creating any other files? i would imagine
> > something like
> >
> > var dgc:DataGridColumn = new DataGridColumn();
> > var mycomponent:Component = new Component();
> > var txt:Text = new Text();
> > txt.text = "Somthing here";
> > mycomponent.addChild(txt);
> >
> > var render:ClassFactory = new ClassFactory(mycomponent);
> > dcg.itemRender = render;
> >
> > i know that this code doesnt work but it's just to have an idea of
> > what i was thinking.
> >
> > Is there anyway to do that?
> >
> > Thanks
> > Rafael
> >
> >  
> >
> 
> 
> 
> -- 
> j:pn
> \\no comment
>




[flexcoders] new Component() ?

2008-07-22 Thread Rafael Faria
Is there anyway to create "components" on the fly? 

Let me explain what i mean.

I have a datagrid that has like 5 columns. Each one of them use a
different itemrenderer.

I understand that i can create each itemrenderer on a different file
but what if i don't want to create files?

is there anyway to transform the following code in a dynamically code
without create any files?









??
How can i do that without creating any other files? i would imagine
something like

var dgc:DataGridColumn = new DataGridColumn();
var mycomponent:Component = new Component();
var txt:Text = new Text();
txt.text = "Somthing here";
mycomponent.addChild(txt);

var render:ClassFactory = new ClassFactory(mycomponent);
dcg.itemRender = render;


i know that this code doesnt work but it's just to have an idea of
what i was thinking.

Is there anyway to do that?

Thanks
Rafael





[flexcoders] rendering problem

2008-07-22 Thread Rafael Faria
I'm not sure how many of you guys had this problem before but for some
reason im getting a rendering problem with forms and datagrid and i
have no ideia how to solve it.

Check this example
the first part is the right one, after i scroll up and down, it gets
all mess up.
http://www.enilsson.com/assets/examples/rendering.png

This one is how it deformed the datagrids.
http://www.enilsson.com/assets/examples/rendering2.png

Any idea how to fix that?
it's killing me.

raf




[flexcoders] Re: Another Bug? Security? OBject Related.

2008-06-11 Thread Rafael Faria
Thanks Very much.
:P



--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> To elaborate a bit: ObjectUtil.toString() has a few things it won't
show by
> default (like anything named password, and a couple of others). It's
to help
> stop you accidentally exposing important stuff in trace() statements
that
> make it into production that anybody with the debug player can see.
> 
> -Josh
> 
> On Thu, Jun 12, 2008 at 2:36 PM, Alex Harui <[EMAIL PROTECTED]> wrote:
> 
> >Try ObjectUtil.toString(bla, null, []);
> >
> >
> >  --
> >
> > *From:* flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] *On
> > Behalf Of *Rafael Faria
> > *Sent:* Wednesday, June 11, 2008 9:30 PM
> > *To:* flexcoders@yahoogroups.com
> > *Subject:* [flexcoders] Another Bug? Security? OBject Related.
> >
> >
> >
> > Someone can explain to me why flex just disapear with my variable
> > "password" in the following example?
> >
> > var bla:Object = new Object();
> > bla.password = "TEST";
> > bla.username = "Rafael";
> > trace(ObjectUtil.toString(bla));
> >
> > Is it a security thing on flex? Is there any way to work around it as
> > i need to use password as a name.
> >
> > Someone?
> >
> > raf
> >
> >  
> >
> 
> 
> 
> -- 
> "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> 
> :: Josh 'G-Funk' McDonald
> :: 0437 221 380 :: [EMAIL PROTECTED]
>




[flexcoders] Another Bug? Security? OBject Related.

2008-06-11 Thread Rafael Faria
Someone can explain to me why flex just disapear with my variable
"password" in the following example?

var bla:Object = new Object();
bla.password = "TEST";
bla.username = "Rafael";
trace(ObjectUtil.toString(bla));

Is it a security thing on flex? Is there any way to work around it as
i need to use password as a name.

Someone?

raf




[flexcoders] Re: HTTPService Bug

2008-06-11 Thread Rafael Faria
--- In flexcoders@yahoogroups.com, "LazerWonder" <[EMAIL PROTECTED]> wrote:
>
> Wherever you get the returned XML object from... does it pass in a 1 
> or 2?  Or does it pass a "1.0" / "2.0".  As far as I know, 
> HTTPService does not transform data (some one more experience can 
> correct me if I am wrong).  It just spits back to you what it 
> receives.

The XML Returns 1.0 and 2.0;
But when it become an object the number 1.0 becomes 1;

> 
> If you have control over the server side of things (that is, where 
> the HTTPService connects to) you might need to see if 1.0/2.0 is 
> being passed to the XML object or maybe only 1 / 2 is being 
> passed to the object.  If you have no control over this, then you 
> might need to add the ".0" manually; or if you do have control but 
> Flex still trip the ".0" off, then try adding quotation marks 
> around "1.0" / "2.0" on the server side.
> 

That's what i had to do. Add manually, although i still think that
FLEX shouldn't mess around whatever you pass as a variable.

> You can also do a trace (which I'm sure you already did - but I 
> thought I'll just plug this in here anyways) statement on the 
> returned object, just to see what you get.

Yeah i did indeed and that's why i'm saying it's returning as integer
and not as a string which is the one i need. =/




[flexcoders] HTTPService Bug

2008-06-10 Thread Rafael Faria
Any reason why HTTPService when return my XML as an Object transform
the following array into strings that was suppose to contain strings
















I'm populating my combobox with the "source" node. I'm using
HTTPService and the resultFormaat = "object".

It adds but whenever i have 1.0 or 2.0 flex just assume it's an string
and use "1 or 2" removing the .0. 

there is anyway to tell flex to NOT remove that i want an string and
not an integer?

raf



[flexcoders] Flex deleting files

2008-06-10 Thread Rafael Faria
How weird it is if you create folder, files on your explorer on flex
framework and do control (in my case on mac command) + Z it just
disappear with the files without any notice?

anyone else had this problem?!

I had to undo some changes on my code but didnt realize that the
cursor was outside my editor. It ends up deleting my image folder that
i had created during the process. The worst thing is that i can't find
it anywhere. it just disapear.





[flexcoders] Re: Tree duplicating items - desperate!!!

2008-06-02 Thread Rafael Faria
I have been tracing and changing the whole script for almost a week
and still getting this bug. The thing is everything looks all right,
the debug version doesnt throw any error. So its a bit hard to find
out what's wrong.

tell me something, how would you do to create branches on dragging
over an element? you know, dynamically!?

do you have any suggestion?!


--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> I would add trace statements showing when you add/remove stuff and see
> if the log makes sense.  You could be dragging over or out in some way
> that you don't expect
> 
>  
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Sunday, June 01, 2008 5:18 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Tree duplicating items - desperate!!!
> 
>  
> 
> If i remove those lines it wont create the brances dynamically...
> 
> What i do is when i drag over a page that is not a branch it
> automatically transform it as a branch, if i don't drop and drag out
> of it, it will trasnform back to a simple leaf. that's why i need to
> leave it on the dragover.
> 
> if you have a better solution please i would love to hear because this
> is killing me.
> 
> i don't know why is duplicating like i showed on the screenshots
> because even when i use the debug version i get no errors.
> 
> helpp 
> 
> --- In flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> , "Alex Harui"  wrote:
> >
> > What are the four lines? If you remove them what happens? Step through
> > dragCompleteHandler.
> > 
> > 
> > 
> > ____
> > 
> > From: flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> [mailto:flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> ] On
> > Behalf Of Rafael Faria
> > Sent: Thursday, May 29, 2008 11:14 PM
> > To: flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com> 
> > Subject: [flexcoders] Tree duplicating items - desperate!!!
> > 
> > 
> > 
> > fellows,
> > 
> > i have been bugging you guys about my tree component for a quite long
> > time and i'm almost finish. the only thing i still have to deal is a
> > "bug" that's happening.
> > 
> > What happen is, i have to create branches on the fly, dynamically
> > whenever i dragover a item.
> > 
> > here is the code to do that (anyone think in a better solution?)
> > 
> > var currNodeOver:TreeItemRenderer =
> > TreeItemRenderer(indexToItemRenderer(calculateDropIndex(event)));
> > if (currNodeOver == null) return;
> > [EMAIL PROTECTED] = true;
> > expandItem(currNodeOver.data,true, true);
> > 
> > What is happening is along the drag and drop, an item has been
> > duplicated somehow. I have cleaned the code on the point to leave just
> > that 4 lines on my extended tree and guess what? still happens.
> > 
> > so i'm not sure if it's a tree bug or is something wrong with those
> > lines, but sometimes (and it doesnt happen everytime) when i drag a
> > children from a branch it duplicates, which mean that the one i was
> > dragging does not move.
> > 
> > I'm not sure if i'm being clear, but i hope i can get some help on
> > that cause i just lost a couple days trying to fix it.
> > 
> > Here is some screen shot of what's happening.
> > 
> > Picture 1, the normal state. 
> > http://www.enilsson.com/assets/images/pic1.png
> <http://www.enilsson.com/assets/images/pic1.png> 
> > <http://www.enilsson.com/assets/images/pic1.png
> <http://www.enilsson.com/assets/images/pic1.png> > 
> > 
> > Picture 2, the bug 
> > http://www.enilsson.com/assets/images/pic2.png
> <http://www.enilsson.com/assets/images/pic2.png> 
> > <http://www.enilsson.com/assets/images/pic2.png
> <http://www.enilsson.com/assets/images/pic2.png> > 
> > 
> > Like i said. it should had moved instead of duplicate. Most of the
> > time is working, everything works... but suddenly it duplicates and
> > debug doesn't return any errors.
> > 
> > helpp
> >
>




[flexcoders] Re: Tree duplicating items - desperate!!!

2008-06-01 Thread Rafael Faria
If i remove those lines it wont create the brances dynamically...

What i do is when i drag over a page that is not a branch it
automatically transform it as a branch, if i don't drop and drag out
of it, it will trasnform back to a simple leaf. that's why i need to
leave it on the dragover.

if you have a better solution please i would love to hear because this
is killing me.

i don't know why is duplicating like i showed on the screenshots
because even when i use the debug version i get no errors.

helpp 


--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> What are the four lines?  If you remove them what happens?  Step through
> dragCompleteHandler.
> 
>  
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Thursday, May 29, 2008 11:14 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Tree duplicating items - desperate!!!
> 
>  
> 
> fellows,
> 
> i have been bugging you guys about my tree component for a quite long
> time and i'm almost finish. the only thing i still have to deal is a
> "bug" that's happening.
> 
> What happen is, i have to create branches on the fly, dynamically
> whenever i dragover a item.
> 
> here is the code to do that (anyone think in a better solution?)
> 
> var currNodeOver:TreeItemRenderer =
> TreeItemRenderer(indexToItemRenderer(calculateDropIndex(event)));
> if (currNodeOver == null) return;
> [EMAIL PROTECTED] = true;
> expandItem(currNodeOver.data,true, true);
> 
> What is happening is along the drag and drop, an item has been
> duplicated somehow. I have cleaned the code on the point to leave just
> that 4 lines on my extended tree and guess what? still happens.
> 
> so i'm not sure if it's a tree bug or is something wrong with those
> lines, but sometimes (and it doesnt happen everytime) when i drag a
> children from a branch it duplicates, which mean that the one i was
> dragging does not move.
> 
> I'm not sure if i'm being clear, but i hope i can get some help on
> that cause i just lost a couple days trying to fix it.
> 
> Here is some screen shot of what's happening.
> 
> Picture 1, the normal state. 
> http://www.enilsson.com/assets/images/pic1.png
> <http://www.enilsson.com/assets/images/pic1.png> 
> 
> Picture 2, the bug 
> http://www.enilsson.com/assets/images/pic2.png
> <http://www.enilsson.com/assets/images/pic2.png> 
> 
> Like i said. it should had moved instead of duplicate. Most of the
> time is working, everything works... but suddenly it duplicates and
> debug doesn't return any errors.
> 
> helpp
>




[flexcoders] Tree duplicating items - desperate!!!

2008-05-29 Thread Rafael Faria
fellows,

i have been bugging you guys about my tree component for a quite long
time and i'm almost finish. the only thing i still have to deal is a
"bug" that's happening.

What happen is, i have to create branches on the fly, dynamically
whenever i dragover a item.

here is the code to do that (anyone think in a better solution?)

var currNodeOver:TreeItemRenderer =
TreeItemRenderer(indexToItemRenderer(calculateDropIndex(event)));
if (currNodeOver == null) return;
[EMAIL PROTECTED] = true;
expandItem(currNodeOver.data,true, true);

What is happening is along the drag and drop, an item has been
duplicated somehow. I have cleaned the code on the point to leave just
that 4 lines on my extended tree and guess what? still happens.

so i'm not sure if it's a tree bug or is something wrong with those
lines, but sometimes (and it doesnt happen everytime) when i drag a
children from a branch it duplicates, which mean that the one i was
dragging does not move.

I'm not sure if i'm being clear, but i hope i can get some help on
that cause i just lost a couple days trying to fix it.

Here is some screen shot of what's happening.

Picture 1, the normal state. 
http://www.enilsson.com/assets/images/pic1.png

Picture 2, the bug 
http://www.enilsson.com/assets/images/pic2.png

Like i said. it should had moved instead of duplicate. Most of the
time is working, everything works... but suddenly it duplicates and
debug doesn't return any errors.

helpp



[flexcoders] Drop Handler

2008-05-14 Thread Rafael Faria
When i drop an item from a tree to another, on the drop handler how do
i get the SOURCE tree object? 

i know how to get the target (event.target or event.currentTarget) but
how do i get the source?

Rafael





[flexcoders] Re: How can i refresh the runtime.

2008-05-01 Thread Rafael Faria
hi Swamy,

i'm not sure if i got that right, but you can try to use "callLater"
functin.

callLater(function():void { functionyouload() });

or set the dataprovider with the xml you load again.

like i said, it's not clear what you want, but i think that one of
those solution might work.

good lucky :p
raf


--- In flexcoders@yahoogroups.com, "Swamy Nathan" <[EMAIL PROTECTED]>
wrote:
>
> Hi Folks,
> 
> I am working with the Dragndrop app. When i finished the dragndrop
images to
> the canvas, i saved into the xml file. and also load into the canvas.
> 
> My problem is when i edit the saved xml file at runtime after i
saved. but i
> open to load the same file after i saving the file.
> 
> this time the file not yet updated. loading the old file only. but am
> checking to open the xml file manually. it is updated the latest nodes.
> 
> How can i refresh the xml file at runtime. please any one reply me...
> 
> -- 
> Thanks & Regards
> Swaminathan. M
>




[flexcoders] Re: Drag and Drop question

2008-05-01 Thread Rafael Faria
So here is a example to what i'm talking about.

someone can tell me why:

1 - First test
on this example if i drag an item from a branch(NOT the WHOLE BRANCH)
from tree1 and drop to tree2, and than click on "get elements from
tree 2" button. it shows nothing... and if you keep adding elements it
will show commas. 

How could i get the elements in the first place, and why it is showing
the commas (apparently is behaving as an ArrayColletion but why?
although this is not what i need to get... i need to get the elements).

2 - Second test
If i drop the 2 branches that sits on the tree 1 and click to see what
dataprovider is on tree2, it show the elements but in between the commas.

i'm not sure what to do =/

someone help... what i need is to be able to drop fomr tree1 to tree2
and get an xml from tree2 with exactly the same structure that shows
the elemnets. is this possible?





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




 





   


























[flexcoders] Re: Drag and Drop question

2008-05-01 Thread Rafael Faria
The thing is ... if the dataprovider is blank and i drop some element
there, i'm not able to retrieve it.

For instance i create a tree 1 and i set the dataprovider

 
 


and create a second tree without any dataprovider.

At the moment i drop an element to the second tree i even though it
show the element there the dataprovider is blank.

can you explain this?

or how do i get what is there? 

--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> You still should be able to use dragComplete instead.
> 
>  
> 
> The dataProvider wraps the XML and is the only good way to get it.
> 
>  
> 



[flexcoders] Re: Drag and Drop question

2008-05-01 Thread Rafael Faria
Yes it does...

I found a solution. I used "callLater" and apparently it works now.

I couldn't understand callLater before but it is a function that it's
saving my life a lot lately! :P


Now the question i have is there is anyway to get the XML from the
tree without getting from the dataprovider? i'm getting
tree.dataProvider and for some things it works fine... but i'm
wondering if there is any other way to do that.

someone?!
raf


--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> Does it disappear from the first tree (i mean visually)?
> 
> On Fri, May 2, 2008 at 9:57 AM, Rafael Faria <[EMAIL PROTECTED]>
> wrote:
> 
> >   That's nice that everybody is learning from my question :p
> >
> > I'm hereee o/ ehheheh
> >
> > someone can help me? :0
> >
> > i still don't know how to get an updated tree after i move the node...
> >
> > or there is any easy way to remove a node from an xml?!
> >
> > thanks
> >
> > rafael
> >
> > --- In flexcoders@yahoogroups.com ,
"Josh
> > McDonald"  wrote:
> > >
> > > Ew =)
> > >
> > > All my dragdrop stuff is funky custom components so I never noticed.
> > But ew.
> > >
> > > -J
> > >
> > > On Fri, May 2, 2008 at 7:49 AM, Tracy Spratt  wrote:
> > >
> > > > Move is the default, there is extra work to copy.
> > > >
> > > >
> > > >
> > > > http://livedocs.adobe.com/flex/3/html/dragdrop_8.html
> > > >
> > > > Tracy
> > > >
> > > >
> > > > --
> > > >
> > > > *From:* flexcoders@yahoogroups.com 
> > [mailto:flexcoders@yahoogroups.com ] *On
> > > > Behalf Of *Josh McDonald
> > > > *Sent:* Thursday, May 01, 2008 5:05 PM
> > > >
> > > > *To:* flexcoders@yahoogroups.com 
> > > > *Subject:* Re: [flexcoders] Drag and Drop question
> > > >
> > > >
> > > >
> > > > How do you mark a drag/drop operation as having a certain type (ie
> > Move)?
> > > >
> > > > -J
> > > >
> > > > On Fri, May 2, 2008 at 5:32 AM, Tracy Spratt 
> > > > wrote:
> > > >
> > > > Actually I am pretty sure the list-based component's built-in
> > drag/drop
> > > > functionality does do this on a MOVE. The docs describe this.
> > Are the XML
> > > > structures the same?
> > > >
> > > >
> > > >
> > > > Tracy
> > > >
> > > >
> > > > --
> > > >
> > > > *From:* flexcoders@yahoogroups.com 
> > [mailto:flexcoders@yahoogroups.com ] *On
> > > > Behalf Of *Josh McDonald
> > > > *Sent:* Thursday, May 01, 2008 2:46 AM
> > > > *To:* flexcoders@yahoogroups.com 
> > > > *Subject:* Re: [flexcoders] Drag and Drop question
> > > >
> > > >
> > > >
> > > > I'm fairly certain that there's no voodoo to automatically delete
> > nodes
> > > > from your XML, you need to do that yourself in your drop handler.
> > > >
> > > > -J
> > > >
> > > > On Thu, May 1, 2008 at 4:36 PM, Rafael Faria 
> > > > wrote:
> > > >
> > > > If i'm dragging an element from one tree to another. How do i
get the
> > > > updated xml of the tree i'm dragging off?
> > > >
> > > > For instance
> > > >
> > > > TREE 1
> > > > - Element 1
> > > > - Element 2
> > > >
> > > > TREE 2
> > > >
> > > > if i get the xml from tree 1 it would be something like
> > > > 
> > > > 
> > > > 
> > > > 
> > > >
> > > > but if i drag the Element 1 into the TREE 2 i want to get the xml
> > > > without the "Element 1", without that node.
> > > >
> > > > i'm trying to get it creating a handler for "dragDrop"
attribute on
> > > > the Tree 2, but everytime i get it the items are not updated.
> > > >
> > > > Anyone know how to get the updated xml that tree 1 will have
after i
> > > > drop the element?
> > > >
> > > > Please... this is killing me =/
> > > >
> > > > Thanks
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > --
> > > > "Therefore, send not to know For whom the bell tolls. It tolls for
> > thee."
> > > >
> > > > :: Josh 'G-Funk' McDonald
> > > >
> > > > :: 0437 221 380 :: josh@
> > > >
> > > >
> > > >
> > > >
> > > > --
> > > > "Therefore, send not to know For whom the bell tolls. It tolls for
> > thee."
> > > >
> > > > :: Josh 'G-Funk' McDonald
> > > > :: 0437 221 380 :: josh@
> > > >
> > > >
> > >
> > >
> > >
> > >
> > > --
> > > "Therefore, send not to know For whom the bell tolls. It tolls for
> > thee."
> > >
> > > :: Josh 'G-Funk' McDonald
> > > :: 0437 221 380 :: josh@
> > >
> >
> >  
> >
> 
> 
> 
> -- 
> "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> 
> :: Josh 'G-Funk' McDonald
> :: 0437 221 380 :: [EMAIL PROTECTED]
>




[flexcoders] Re: Drag and Drop question

2008-05-01 Thread Rafael Faria
That's nice that everybody is learning from my question :p

I'm hereee o/ ehheheh

someone can help me? :0

i still don't know how to get an updated tree after i move the node...

or there is any easy way to remove a node from an xml?!

thanks
rafael

--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> Ew =)
> 
> All my dragdrop stuff is funky custom components so I never noticed.
But ew.
> 
> -J
> 
> On Fri, May 2, 2008 at 7:49 AM, Tracy Spratt <[EMAIL PROTECTED]> wrote:
> 
> >Move is the default, there is extra work to copy.
> >
> >
> >
> > http://livedocs.adobe.com/flex/3/html/dragdrop_8.html
> >
> > Tracy
> >
> >
> >  --
> >
> > *From:* flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] *On
> > Behalf Of *Josh McDonald
> > *Sent:* Thursday, May 01, 2008 5:05 PM
> >
> > *To:* flexcoders@yahoogroups.com
> > *Subject:* Re: [flexcoders] Drag and Drop question
> >
> >
> >
> > How do you mark a drag/drop operation as having a certain type (ie
Move)?
> >
> > -J
> >
> > On Fri, May 2, 2008 at 5:32 AM, Tracy Spratt <[EMAIL PROTECTED]>
> > wrote:
> >
> > Actually I am pretty sure the list-based component's built-in
drag/drop
> > functionality does do this on a MOVE.  The docs describe this. 
Are the XML
> > structures the same?
> >
> >
> >
> > Tracy
> >
> >
> >  --
> >
> > *From:* flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] *On
> > Behalf Of *Josh McDonald
> > *Sent:* Thursday, May 01, 2008 2:46 AM
> > *To:* flexcoders@yahoogroups.com
> > *Subject:* Re: [flexcoders] Drag and Drop question
> >
> >
> >
> > I'm fairly certain that there's no voodoo to automatically delete
nodes
> > from your XML, you need to do that yourself in your drop handler.
> >
> > -J
> >
> > On Thu, May 1, 2008 at 4:36 PM, Rafael Faria <[EMAIL PROTECTED]>
> > wrote:
> >
> > If i'm dragging an element from one tree to another. How do i get the
> > updated xml of the tree i'm dragging off?
> >
> > For instance
> >
> > TREE 1
> > - Element 1
> > - Element 2
> >
> > TREE 2
> >
> > if i get the xml from tree 1 it would be something like
> > 
> > 
> > 
> > 
> >
> > but if i drag the Element 1 into the TREE 2 i want to get the xml
> > without the "Element 1", without that node.
> >
> > i'm trying to get it creating a handler for "dragDrop" attribute on
> > the Tree 2, but everytime i get it the items are not updated.
> >
> > Anyone know how to get the updated xml that tree 1 will have after i
> > drop the element?
> >
> > Please... this is killing me =/
> >
> > Thanks
> >
> >
> >
> >
> >
> > --
> > "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> >
> > :: Josh 'G-Funk' McDonald
> >
> > :: 0437 221 380 :: [EMAIL PROTECTED]
> >
> >
> >
> >
> > --
> > "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> >
> > :: Josh 'G-Funk' McDonald
> > :: 0437 221 380 :: [EMAIL PROTECTED]
> >
> >  
> 
> 
> 
> 
> -- 
> "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> 
> :: Josh 'G-Funk' McDonald
> :: 0437 221 380 :: [EMAIL PROTECTED]
>




[flexcoders] Re: Drag and Drop question

2008-05-01 Thread Rafael Faria
If im moving the object i would assume it will not be in the tree 1
anymore...

anyone would help me how do i drag from tree 1, drop on tree 2 and
after i drop i get the elements on tree 1 without the one i just
dropped on tree 2?

should this be that painfull? do i have to delete manually?!

Thanks

--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> I wouldn't say "voodoo" but if you drag an item from tree 1 to tree 2
> the dataprovider should not contain the item you've dragged to the
> other tree... am i wrong?
> 
> rafael
> 
> 
> --- In flexcoders@yahoogroups.com, "Josh McDonald"  wrote:
> >
> > I'm fairly certain that there's no voodoo to automatically delete
> nodes from
> > your XML, you need to do that yourself in your drop handler.
> > 
> > -J
> > 
> > On Thu, May 1, 2008 at 4:36 PM, Rafael Faria 
> > wrote:
> > 
> > >   If i'm dragging an element from one tree to another. How do i
> get the
> > > updated xml of the tree i'm dragging off?
> > >
> > > For instance
> > >
> > > TREE 1
> > > - Element 1
> > > - Element 2
> > >
> > > TREE 2
> > >
> > > if i get the xml from tree 1 it would be something like
> > > 
> > > 
> > > 
> > > 
> > >
> > > but if i drag the Element 1 into the TREE 2 i want to get the xml
> > > without the "Element 1", without that node.
> > >
> > > i'm trying to get it creating a handler for "dragDrop" attribute on
> > > the Tree 2, but everytime i get it the items are not updated.
> > >
> > > Anyone know how to get the updated xml that tree 1 will have after i
> > > drop the element?
> > >
> > > Please... this is killing me =/
> > >
> > > Thanks
> > >
> > >  
> > >
> > 
> > 
> > 
> > -- 
> > "Therefore, send not to know For whom the bell tolls. It tolls for
> thee."
> > 
> > :: Josh 'G-Funk' McDonald
> > :: 0437 221 380 :: josh@
> >
>




[flexcoders] Re: Showroot - Tree control

2008-05-01 Thread Rafael Faria
This was just an example i got on adobe website so i can show what i
need. On my project i use XML. I just think if i find a solution for
whatever i use as dataprovider i could apply on my project.

Anyone else can help me with it!?

Thanks
Rafael


--- In flexcoders@yahoogroups.com, "Tracy Spratt" <[EMAIL PROTECTED]> wrote:
>
> First, do away with the collections and just try it with XML.  XML works
> extremely well with Tree, since it is inherently hierarchical.  Nested
> collections add a level of complexity you probably do not need.
> 
>  
> 
> Tracy
> 
>  
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Tuesday, April 22, 2008 7:13 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Showroot - Tree control
> 
>  
> 
> any help?! im really tight on it. =/
> 
> Thanks
> Raf
> 
> --- In flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> , "Rafael Faria"
>  wrote:
> >
> > 
> > 
> > http://www.adobe.com/2006/mxml
> <http://www.adobe.com/2006/mxml> ">
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > Whenever i have just 1 node (that is the root one) on the XML it
> > doesnt matter if i set the attribute showRoot="false" because it keep
> > showing.
> > 
> > I need to keep the root to not show on my tree.
> > 
> > 
> > if i do
> > 
> > 
> > 
> > 
> > http://www.adobe.com/2006/mxml
> <http://www.adobe.com/2006/mxml> ">
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> >  
> >  
> >  
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > The "Mail" one its not there...
> > 
> > i cant filter, or delete, or whatever... i just need it to work
> > exactly how it work on the second example, but whenever i dont have
> > the nodes after the root i just want to show a blank tree.
> > 
> > The reason i need to keep root is because i have a drag and drop the
> > needs to keep the root on it.
> > 
> > anyone can explain why in the first example even though i set
> > showroot="false" it still show it?!
> > 
> > thanks
> >
>




[flexcoders] Re: Drag and Drop question

2008-05-01 Thread Rafael Faria
I wouldn't say "voodoo" but if you drag an item from tree 1 to tree 2
the dataprovider should not contain the item you've dragged to the
other tree... am i wrong?

rafael


--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> I'm fairly certain that there's no voodoo to automatically delete
nodes from
> your XML, you need to do that yourself in your drop handler.
> 
> -J
> 
> On Thu, May 1, 2008 at 4:36 PM, Rafael Faria <[EMAIL PROTECTED]>
> wrote:
> 
> >   If i'm dragging an element from one tree to another. How do i
get the
> > updated xml of the tree i'm dragging off?
> >
> > For instance
> >
> > TREE 1
> > - Element 1
> > - Element 2
> >
> > TREE 2
> >
> > if i get the xml from tree 1 it would be something like
> > 
> > 
> > 
> > 
> >
> > but if i drag the Element 1 into the TREE 2 i want to get the xml
> > without the "Element 1", without that node.
> >
> > i'm trying to get it creating a handler for "dragDrop" attribute on
> > the Tree 2, but everytime i get it the items are not updated.
> >
> > Anyone know how to get the updated xml that tree 1 will have after i
> > drop the element?
> >
> > Please... this is killing me =/
> >
> > Thanks
> >
> >  
> >
> 
> 
> 
> -- 
> "Therefore, send not to know For whom the bell tolls. It tolls for
thee."
> 
> :: Josh 'G-Funk' McDonald
> :: 0437 221 380 :: [EMAIL PROTECTED]
>




[flexcoders] Drag and Drop question

2008-04-30 Thread Rafael Faria
If i'm dragging an element from one tree to another. How do i get the
updated xml of the tree i'm dragging off?

For instance

TREE 1
 - Element 1
 - Element 2


TREE 2



if i get the xml from tree 1 it would be something like

   
   


but if i drag the Element 1 into the TREE 2 i want to get the xml
without the "Element 1", without that node.

i'm trying to get it creating a handler for "dragDrop" attribute on
the Tree 2, but everytime i get it the items are not updated.

Anyone know how to get the updated xml that tree 1 will have after i
drop the element?

Please... this is killing me =/

Thanks




[flexcoders] Re: Showroot - Tree control

2008-04-22 Thread Rafael Faria
any help?! im really tight on it. =/

Thanks
Raf


--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> 
> 
> http://www.adobe.com/2006/mxml";>
>   
>   
>  
> 
>
> 
>  
>   
>
> 
> 
> Whenever i have just 1 node (that is the root one) on the XML it
> doesnt matter if i set the attribute showRoot="false" because it keep
> showing.
> 
> I need to keep the root to not show on my tree.
> 
> 
> if i do
> 
> 
> 
> 
> http://www.adobe.com/2006/mxml";>
>
>   
>  
> 
>
>
>   
>
>   
>   
>   
>   
>   
> 
>  
>   
>
> 
> 
> 
> The "Mail" one its not there...
> 
> i cant filter, or delete, or whatever... i just need it to work
> exactly how it work on the second example, but whenever i dont have
> the nodes after the root i just want to show a blank tree.
> 
> The reason i need to keep root is because i have a drag and drop the
> needs to keep the root on it.
> 
> anyone can explain why in the first example even though i set
> showroot="false" it still show it?!
> 
> thanks
>




[flexcoders] Showroot - Tree control

2008-04-21 Thread Rafael Faria


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

  
 

   

 
  
   


Whenever i have just 1 node (that is the root one) on the XML it
doesnt matter if i set the attribute showRoot="false" because it keep
showing.

I need to keep the root to not show on my tree.


if i do




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

   
   
  
   
  
  
  
  
  

 
  
   



The "Mail" one its not there...

i cant filter, or delete, or whatever... i just need it to work
exactly how it work on the second example, but whenever i dont have
the nodes after the root i just want to show a blank tree.

The reason i need to keep root is because i have a drag and drop the
needs to keep the root on it.

anyone can explain why in the first example even though i set
showroot="false" it still show it?!

thanks




[flexcoders] Chart effects

2008-04-15 Thread Rafael Faria
Any suggestion which effects is good for area or line charts?




[flexcoders] Re: Charting...

2008-04-15 Thread Rafael Faria
Josh,

I tried messing with the order but it didnt work. But thanks for your
suggestion. callLater work quite good as well. I think is a better
solution than 1ms timer ;p

Cheers
Raf



--- In flexcoders@yahoogroups.com, "Josh McDonald" <[EMAIL PROTECTED]> wrote:
>
> That doesn't seem right :)
> 
> Try messing about with the order in which you're setting various
properties
> - perhaps just setting the provider last will do it? Also if that
doesn't
> work, try using callLater() instead of a 1ms timer.
> 
> -J
> 
> On Wed, Apr 16, 2008 at 11:40 AM, Rafael Faria <[EMAIL PROTECTED]>
> wrote:
> 
> >   For some reason if you put a timer to set the dataprovider it work
> > just fine.
> >
> > var loadTimer:Timer = new Timer(1,1);
> > loadTimer.addEventListener("timer", function():void {
> > barchart.dataProvider = chartdata.item });
> > .start();
> >
> > Now.. 1 msecond is what it takes to make it work...
> >
> > weird...
> >
> > --- In flexcoders@yahoogroups.com ,
"Rafael
> > Faria"
> >
> >  wrote:
> > >
> > > What am i doing wrong? The chart works fine but there is no
effect...
> > > not matter what i do it just doesnt play.
> > >
> > > Can someone help me to apply the Series Slide on this chart?! do i
> > > have to do something else?
> > >
> > > i set the style but doesnt work =/
> > >
> > >
> > > var bss:SeriesSlide = new SeriesSlide();
> > > bss.duration = 1000;
> > > bss.direction = "right";
> > >
> > > var bseries:BarSeries = new BarSeries();
> > > bseries.yField = "yfield";
> > > bseries.xField = "xfield";
> > > bseries.setStyle("showDataEffect",bss);
> > >
> > > var barchart:BarChart = new BarChart();
> > > barchart.percentWidth = 100;
> > > barchart.percentHeight = 100;
> > > barchart.showDataTips = true;
> > > barchart.dataProvider = chartdata.item;
> > > barchart.series = [bseries];
> > >
> > > var ca:CategoryAxis = new CategoryAxis();
> > > ca.categoryField = "yfield";
> > > barchart.verticalAxis = ca;
> > >
> > > addChild(barchart);
> > >
> >
> >  
> >
> 
> 
> 
> -- 
> "Therefore, send not to know For whom the bell tolls, It tolls for
thee."
> 
> :: Josh 'G-Funk' McDonald
> :: 0437 221 380 :: [EMAIL PROTECTED]
>




[flexcoders] Re: Charting...

2008-04-15 Thread Rafael Faria
For some reason if you put a timer to set the dataprovider it work
just fine.

var loadTimer:Timer = new Timer(1,1);   
loadTimer.addEventListener("timer", function():void {
barchart.dataProvider = chartdata.item });  
.start();

Now.. 1 msecond is what it takes to make it work...

weird...




--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> What am i doing wrong? The chart works fine but there is no effect...
> not matter what i do it just doesnt play.
> 
> Can someone help me to apply the Series Slide on this chart?! do i
> have to do something else?
> 
> i set the style but doesnt work =/
> 
> 
> var bss:SeriesSlide = new SeriesSlide();
> bss.duration = 1000;
> bss.direction = "right";
> 
> var bseries:BarSeries = new BarSeries();
> bseries.yField = "yfield";
> bseries.xField = "xfield";
> bseries.setStyle("showDataEffect",bss);
> 
> var barchart:BarChart = new BarChart();
> barchart.percentWidth = 100;
> barchart.percentHeight = 100;
> barchart.showDataTips = true;
> barchart.dataProvider = chartdata.item;
> barchart.series = [bseries];
> 
> var ca:CategoryAxis = new CategoryAxis();
> ca.categoryField = "yfield";
> barchart.verticalAxis = ca;
> 
> addChild(barchart);
>




[flexcoders] Charting...

2008-04-15 Thread Rafael Faria
What am i doing wrong? The chart works fine but there is no effect...
not matter what i do it just doesnt play.

Can someone help me to apply the Series Slide on this chart?! do i
have to do something else?

i set the style but doesnt work =/


var bss:SeriesSlide = new SeriesSlide();
bss.duration = 1000;
bss.direction = "right";

var bseries:BarSeries = new BarSeries();
bseries.yField = "yfield";
bseries.xField = "xfield";
bseries.setStyle("showDataEffect",bss);

var barchart:BarChart = new BarChart();
barchart.percentWidth = 100;
barchart.percentHeight = 100;
barchart.showDataTips = true;
barchart.dataProvider = chartdata.item;
barchart.series = [bseries];

var ca:CategoryAxis = new CategoryAxis();
ca.categoryField = "yfield";
barchart.verticalAxis = ca;

addChild(barchart);





[flexcoders] Sound Recorder

2008-03-27 Thread Rafael Faria
Is there any way to record anything on the client and save it on the
server?  have anyone done that? if yes, can you help me?



[flexcoders] Re: Tree SelectedItem

2008-03-12 Thread Rafael Faria
I have this handler... but i dont know how to get select the item once
i drop it to tree2.

event.target or relatedTarget makes reference to the Trees not to the
element itself.

Any ideas?

raf


--- In flexcoders@yahoogroups.com, "Giles Roadnight" <[EMAIL PROTECTED]> wrote:
>
> You'll have to add an eventListener that fires on the itemDrop (or
whatever
> it is) event. In that code then just set the selected Item to the object
> passed in the event.
> 
> On Wed, Mar 12, 2008 at 6:22 AM, Rafael Faria <[EMAIL PROTECTED]>
> wrote:
> 
> >   If i'm dragging a item from tree1 to tree2 how do i select the item
> > after i drop it on tree2?
> >
> >  
> >
> 
> 
> 
> -- 
> Giles Roadnight
> http://giles.roadnight.name
>




[flexcoders] Tree SelectedItem

2008-03-11 Thread Rafael Faria
If i'm dragging a item from tree1 to tree2 how do i select the item
after i drop it on tree2? 



[flexcoders] Re: Tree Bug?

2008-03-03 Thread Rafael Faria
Sorry...
when i say tabs... i mean browser tabs...

raf
eNilsson Asia & Pacific
http://www.enilsson.com/blog/


--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> Hi sherif... Please check this
> 
> http://www.enilsson.com/assets/examples/menuTree.html
> 
> Select some items, and than change tabs, than come back to the menu...
> you will see that it automatically start editing an item. And it
> doesnt listen to the listeners. Just start editing from nowhere.
> 
> I tried Alex suggestion 
> 
> addEventListener(FocusEvent.FOCUS_IN, handleItemFocusIn);
> 
> and on handleItemFocusIn function i put
> 
> editedItemPosition = null;
> 
> i have a listening to the begginingedit too
> 
> private function handleItemEditBeginning(event:ListEvent):void
>   {
> event.preventDefault(); 
> }
> 
> but it doesnt seems to work either.
> 
> 
> but it didnt change anything on FF but it throws an error on Safari.
> 
> 
> Also note that if you start editing (to start editing it works like
> mac, click once, and than click again) and you double click at the
> textinput it will jump to the native editor...
> 
> those 2 issues are making me lost some nights of work... doesnt matter
> what i do, it just don't fix it.
> 
> 
> 
> 
> 
> 
> 
> 
> 
> This is what my listeners handle...
> 
>
> addEventListener(ListEvent.ITEM_EDIT_BEGINNING,handleItemEditBeginning);
> addEventListener(ListEvent.ITEM_EDIT_END,handleItemEditEnd);
> addEventListener(ListEvent.ITEM_CLICK,handleItemEdit);
> 
> 
> 
> 
> 
>   /**
> * Action taken when you start editing the item
> **/
> private function handleItemEditBeginning(event:ListEvent):void
>   {
> event.preventDefault(); 
> }
>   
> 
>   /**
> * Action taken when you finish editing the item
> **/
> private function handleItemEditEnd(event:ListEvent):void
>   {
>   _tmpSelectedItem = null;
>   
> }
> 
>   /**
> * Action taken when you edit a item
> **/
>   private var _tmpSelectedItem:Object;
>   private var editTimer:Timer = new Timer(1500,1);
> private function handleItemEdit(event:ListEvent):void
>   {
>   
>   if ((_tmpSelectedItem == selectedItem) && (editable)) {
>   // Edit
>   editedItemPosition = event;
>   
>   } else {
>   // not edit
>   event.preventDefault(); 
>   }
>   
>   editTimer.removeEventListener(TimerEvent.TIMER_COMPLETE,
> clearSelectedItem);
>   
> editTimer.addEventListener(TimerEvent.TIMER_COMPLETE,clearSelectedItem);
>   editTimer.start();
>   
>   _tmpSelectedItem = selectedItem;
>   
> }
> 
> private function clearSelectedItem(event:TimerEvent):void
> {
>   _tmpSelectedItem = null;
>       editTimer.removeEventListener(TimerEvent.TIMER_COMPLETE,
> clearSelectedItem);   
> }
> 
> 
> 
> 
> 
> --- In flexcoders@yahoogroups.com, Sherif Abdou  wrote:
> >
> > u have a link or a bit of source code? try removing focus on the
> editing by listeneing to the stage leave
> > 
> > 
> > 
> > - Original Message 
> > From: Rafael Faria 
> > To: flexcoders@yahoogroups.com
> > Sent: Sunday, March 2, 2008 10:12:00 PM
> > Subject: [flexcoders] Re: Tree Bug?
> > 
> > anyone?
> > 
> > --- In [EMAIL PROTECTED] ups.com, "Rafael Faria"
> >  wrote:
> > >
> > > I'm almost finished with my Tree custom component. 
> > > 
> > > Just 2 things are bugging me a lot.
> > > 
> > > Firstly, when i select a node (not editing), change tab on my
firefox,
> > > and come back, it enters to editing mode without touching anything.
> > > 
> > > Secondly, when i'm in the editing a node, and double click
inside the
> > > custom texteditor i created, it just jump back to the native editor.
> > > 
> > > Anyone knows how to prevent both of those things to happen?
> > > 
> > > thanks
> > > raf
> > >
> > 
> > 
> >  
> > 
> > 
> >  
>

> > Looking for last minute shopping deals?  
> > Find them fast with Yahoo! Search. 
> http://tools.search.yahoo.com/newsearch/category.php?category=shopping
> >
>




[flexcoders] Re: Tree Bug?

2008-03-03 Thread Rafael Faria
Hi sherif... Please check this

http://www.enilsson.com/assets/examples/menuTree.html

Select some items, and than change tabs, than come back to the menu...
you will see that it automatically start editing an item. And it
doesnt listen to the listeners. Just start editing from nowhere.

I tried Alex suggestion 

addEventListener(FocusEvent.FOCUS_IN, handleItemFocusIn);

and on handleItemFocusIn function i put

editedItemPosition = null;

i have a listening to the begginingedit too

private function handleItemEditBeginning(event:ListEvent):void
{
event.preventDefault(); 
}

but it doesnt seems to work either.


but it didnt change anything on FF but it throws an error on Safari.


Also note that if you start editing (to start editing it works like
mac, click once, and than click again) and you double click at the
textinput it will jump to the native editor...

those 2 issues are making me lost some nights of work... doesnt matter
what i do, it just don't fix it.









This is what my listeners handle...

   
addEventListener(ListEvent.ITEM_EDIT_BEGINNING,handleItemEditBeginning);
addEventListener(ListEvent.ITEM_EDIT_END,handleItemEditEnd);
addEventListener(ListEvent.ITEM_CLICK,handleItemEdit);





/**
* Action taken when you start editing the item
**/
private function handleItemEditBeginning(event:ListEvent):void
{
event.preventDefault(); 
}


/**
* Action taken when you finish editing the item
**/
private function handleItemEditEnd(event:ListEvent):void
{
_tmpSelectedItem = null;

}

/**
* Action taken when you edit a item
**/
private var _tmpSelectedItem:Object;
private var editTimer:Timer = new Timer(1500,1);
private function handleItemEdit(event:ListEvent):void
{

if ((_tmpSelectedItem == selectedItem) && (editable)) {
// Edit
editedItemPosition = event;

} else {
// not edit
event.preventDefault(); 
}

editTimer.removeEventListener(TimerEvent.TIMER_COMPLETE,
clearSelectedItem);

editTimer.addEventListener(TimerEvent.TIMER_COMPLETE,clearSelectedItem);
editTimer.start();

_tmpSelectedItem = selectedItem;

}

private function clearSelectedItem(event:TimerEvent):void
{
_tmpSelectedItem = null;
editTimer.removeEventListener(TimerEvent.TIMER_COMPLETE,
clearSelectedItem); 
}





--- In flexcoders@yahoogroups.com, Sherif Abdou <[EMAIL PROTECTED]> wrote:
>
> u have a link or a bit of source code? try removing focus on the
editing by listeneing to the stage leave
> 
> 
> 
> - Original Message 
> From: Rafael Faria <[EMAIL PROTECTED]>
> To: flexcoders@yahoogroups.com
> Sent: Sunday, March 2, 2008 10:12:00 PM
> Subject: [flexcoders] Re: Tree Bug?
> 
> anyone?
> 
> --- In [EMAIL PROTECTED] ups.com, "Rafael Faria"
>  wrote:
> >
> > I'm almost finished with my Tree custom component. 
> > 
> > Just 2 things are bugging me a lot.
> > 
> > Firstly, when i select a node (not editing), change tab on my firefox,
> > and come back, it enters to editing mode without touching anything.
> > 
> > Secondly, when i'm in the editing a node, and double click inside the
> > custom texteditor i created, it just jump back to the native editor.
> > 
> > Anyone knows how to prevent both of those things to happen?
> > 
> > thanks
> > raf
> >
> 
> 
>  
> 
> 
>  

> Looking for last minute shopping deals?  
> Find them fast with Yahoo! Search. 
http://tools.search.yahoo.com/newsearch/category.php?category=shopping
>




[flexcoders] Re: Tree Bug?

2008-03-02 Thread Rafael Faria
anyone?

--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> I'm almost finished with my Tree custom component. 
> 
> Just 2 things are bugging me a lot.
> 
> Firstly, when i select a node (not editing), change tab on my firefox,
> and come back, it enters to editing mode without touching anything.
> 
> Secondly, when i'm in the editing a node, and double click inside the
> custom texteditor i created, it just jump back to the native editor.
> 
> Anyone knows how to prevent both of those things to happen?
> 
> thanks
> raf
>




[flexcoders] Tree Bug?

2008-03-02 Thread Rafael Faria
I'm almost finished with my Tree custom component. 

Just 2 things are bugging me a lot.

Firstly, when i select a node (not editing), change tab on my firefox,
and come back, it enters to editing mode without touching anything.

Secondly, when i'm in the editing a node, and double click inside the
custom texteditor i created, it just jump back to the native editor.

Anyone knows how to prevent both of those things to happen?

thanks
raf




[flexcoders] Selecting a Item on a Tree Control

2008-02-20 Thread Rafael Faria
I was reading blog.flexexamples and i saw an example of what i need.
But it was quite exactly.

The following example is Opening nodes on a tree control.

http://blog.flexexamples.com/2007/11/29/opening-nodes-in-a-flex-tree-control-using-the-expanditem-method/

What i need is basically the same thing but using a different source.

in the example above it uses

var node:XMLList = mlb.league.division.team.(@label == team);

to get the list.

If i try to change based on the dataProvider XML it wont work although
i traced and it seems to get the right data.

var node:XMLList = XML(tree.dataProvider).league.division.team.(@label
== team);

any one would know how to explain why it happen?

Thanks in advanced
Raf




[flexcoders] Re: Tree descendants

2008-02-20 Thread Rafael Faria
Hey mate... who said you are an idiot? 

 no worries mate... you put me on the right path :P 

thanks a lot!!!

raf


--- In flexcoders@yahoogroups.com, "Jim Hayes" <[EMAIL PROTECTED]> wrote:
>
> Close but no cigar then :-(
>  
> > the thing now is how do i change the element.
>  
> var list:XMLList = XML(dataProvider).descendants().(attribute("editing")
> == "true")
>  
> for each ( var editingNode:XML in list)
> {
> [EMAIL PROTECTED]"false"; // or whatever you want to do to that node
> }
>  
>  
> (that probably won't work either! apologies if I am an idiot)
>  
>  
>  
> -Original Message-
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: 20 February 2008 23:38
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Tree descendants
>  
> Ok you got it almost right like you said.
> 
> instead of attributes use attribute.
> 
> var list:XMLList =
> XML(dataProvider).descendants().(attribute("editing") == "true")
> 
> the thing now is how do i change the element. 
> i tried go through the list and change the attribute to "false" but it
> doesnt really change it.
> 
> this is killing me =/
> 
> --- In flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> , "Rafael Faria"
>  wrote:
> >
> > Not really. Got an error as well.
> > 
> > someone else can help me out?? 
> > raf
> > 
> > --- In flexcoders@yahoogroups.com
> <mailto:flexcoders%40yahoogroups.com> , "Jim Hayes"  wrote:
> > >
> > > I think it's XML(dataProvider).descendants().(attributes("enabled")
> ==
> > > "true") that you want ? Not checked it but I think it's pretty
> close at
> > > least.
> > > 
> > > -Original Message-
> > > From: flexcoders@yahoogroups.com
> <mailto:flexcoders%40yahoogroups.com> 
> [mailto:flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> ] On
> > > Behalf Of Rafael Faria
> > > Sent: 20 February 2008 05:55
> > > To: flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> 
> > > Subject: [flexcoders] Tree descendants
> > > 
> > > I'm trying to get the descendants from my XML which has the
> attribute
> > > "enabled = true"
> > > 
> > > if i try
> > > 
> > > XML(dataProvider).descendants().(@enabled = "true") 
> > > 
> > > i get an error " A term is undefined and has no properties."
> > > 
> > > which is understandable because not every node has the enabled
> > > attribute. The question is how to get all that has the "enabled"
> > > attribute and is set true.
> > > 
> > > 
> > > __
> > > This communication is from Primal Pictures Ltd., a company
> > registered in England and Wales with registration No. 02622298 and
> > registered office: 4th Floor, Tennyson House, 159-165 Great Portland
> > Street, London, W1W 5PA, UK. VAT registration No. 648874577.
> > > 
> > > This e-mail is confidential and may be privileged. It may be read,
> > copied and used only by the intended recipient. If you have received
> > it in error, please contact the sender immediately by return e-mail or
> > by telephoning +44(0)20 7637 1010. Please then delete the e-mail and
> > do not disclose its contents to any person.
> > > This email has been scanned for Primal Pictures by the MessageLabs
> > Email Security System.
> > > __
> > >
> >
>  
> 
> __
> This communication is from Primal Pictures Ltd., a company
registered in England and Wales with registration No. 02622298 and
registered office: 4th Floor, Tennyson House, 159-165 Great Portland
Street, London, W1W 5PA, UK. VAT registration No. 648874577.
> 
> This e-mail is confidential and may be privileged. It may be read,
copied and used only by the intended recipient. If you have received
it in error, please contact the sender immediately by return e-mail or
by telephoning +44(0)20 7637 1010. Please then delete the e-mail and
do not disclose its contents to any person.
> This email has been scanned for Primal Pictures by the MessageLabs
Email Security System.
> __
>




[flexcoders] Re: Tree descendants

2008-02-20 Thread Rafael Faria
As usual, i sent the message and solve my problem.

The problem was casting the dataProvider as XML.

if i use

var list:XMLList = dataProvider.descendants().(attribute("editing") ==
"true")

i can parse through the list and change it attributes

for (var i:* in list){
 [EMAIL PROTECTED] = "false";
}

:P

Thanks for your help. It put me on the right track :P

raf
--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> Ok you got it almost right like you said.
> 
> instead of attributes use attribute.
> 
>   var list:XMLList =
> XML(dataProvider).descendants().(attribute("editing") == "true")
> 
> 
> the thing now is how do i change the element. 
> i tried go through the list and change the attribute to "false" but it
> doesnt really change it.
> 
> this is killing me =/
> 
> 
> --- In flexcoders@yahoogroups.com, "Rafael Faria"
>  wrote:
> >
> > Not really. Got an error as well.
> > 
> > someone else can help me out?? 
> > raf
> > 
> > --- In flexcoders@yahoogroups.com, "Jim Hayes"  wrote:
> > >
> > > I think it's
XML(dataProvider).descendants().(attributes("enabled") ==
> > > "true") that you want ? Not checked it but I think it's pretty
> close at
> > > least.
> > >  
> > > -Original Message-
> > > From: flexcoders@yahoogroups.com
> [mailto:[EMAIL PROTECTED] On
> > > Behalf Of Rafael Faria
> > > Sent: 20 February 2008 05:55
> > > To: flexcoders@yahoogroups.com
> > > Subject: [flexcoders] Tree descendants
> > >  
> > > I'm trying to get the descendants from my XML which has the
attribute
> > > "enabled = true"
> > > 
> > > if i try
> > > 
> > > XML(dataProvider).descendants().(@enabled = "true") 
> > > 
> > > i get an error " A term is undefined and has no properties."
> > > 
> > > which is understandable because not every node has the enabled
> > > attribute. The question is how to get all that has the "enabled"
> > > attribute and is set true.
> > >  
> > > 
> > >
__
> > > This communication is from Primal Pictures Ltd., a company
> > registered in England and Wales with registration No. 02622298 and
> > registered office: 4th Floor, Tennyson House, 159-165 Great Portland
> > Street, London, W1W 5PA, UK. VAT registration No. 648874577.
> > > 
> > > This e-mail is confidential and may be privileged. It may be read,
> > copied and used only by the intended recipient. If you have received
> > it in error, please contact the sender immediately by return e-mail or
> > by telephoning +44(0)20 7637 1010. Please then delete the e-mail and
> > do not disclose its contents to any person.
> > > This email has been scanned for Primal Pictures by the MessageLabs
> > Email Security System.
> > >
__
> > >
> >
>




[flexcoders] Re: Tree descendants

2008-02-20 Thread Rafael Faria
Ok you got it almost right like you said.

instead of attributes use attribute.

var list:XMLList =
XML(dataProvider).descendants().(attribute("editing") == "true")


the thing now is how do i change the element. 
i tried go through the list and change the attribute to "false" but it
doesnt really change it.

this is killing me =/


--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> Not really. Got an error as well.
> 
> someone else can help me out?? 
> raf
> 
> --- In flexcoders@yahoogroups.com, "Jim Hayes"  wrote:
> >
> > I think it's XML(dataProvider).descendants().(attributes("enabled") ==
> > "true") that you want ? Not checked it but I think it's pretty
close at
> > least.
> >  
> > -Original Message-
> > From: flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] On
> > Behalf Of Rafael Faria
> > Sent: 20 February 2008 05:55
> > To: flexcoders@yahoogroups.com
> > Subject: [flexcoders] Tree descendants
> >  
> > I'm trying to get the descendants from my XML which has the attribute
> > "enabled = true"
> > 
> > if i try
> > 
> > XML(dataProvider).descendants().(@enabled = "true") 
> > 
> > i get an error " A term is undefined and has no properties."
> > 
> > which is understandable because not every node has the enabled
> > attribute. The question is how to get all that has the "enabled"
> > attribute and is set true.
> >  
> > 
> > __
> > This communication is from Primal Pictures Ltd., a company
> registered in England and Wales with registration No. 02622298 and
> registered office: 4th Floor, Tennyson House, 159-165 Great Portland
> Street, London, W1W 5PA, UK. VAT registration No. 648874577.
> > 
> > This e-mail is confidential and may be privileged. It may be read,
> copied and used only by the intended recipient. If you have received
> it in error, please contact the sender immediately by return e-mail or
> by telephoning +44(0)20 7637 1010. Please then delete the e-mail and
> do not disclose its contents to any person.
> > This email has been scanned for Primal Pictures by the MessageLabs
> Email Security System.
> > __
> >
>




[flexcoders] Re: Tree descendants

2008-02-20 Thread Rafael Faria
Not really. Got an error as well.

someone else can help me out?? 
raf

--- In flexcoders@yahoogroups.com, "Jim Hayes" <[EMAIL PROTECTED]> wrote:
>
> I think it's XML(dataProvider).descendants().(attributes("enabled") ==
> "true") that you want ? Not checked it but I think it's pretty close at
> least.
>  
> -Original Message-
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: 20 February 2008 05:55
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Tree descendants
>  
> I'm trying to get the descendants from my XML which has the attribute
> "enabled = true"
> 
> if i try
> 
> XML(dataProvider).descendants().(@enabled = "true") 
> 
> i get an error " A term is undefined and has no properties."
> 
> which is understandable because not every node has the enabled
> attribute. The question is how to get all that has the "enabled"
> attribute and is set true.
>  
> 
> __
> This communication is from Primal Pictures Ltd., a company
registered in England and Wales with registration No. 02622298 and
registered office: 4th Floor, Tennyson House, 159-165 Great Portland
Street, London, W1W 5PA, UK. VAT registration No. 648874577.
> 
> This e-mail is confidential and may be privileged. It may be read,
copied and used only by the intended recipient. If you have received
it in error, please contact the sender immediately by return e-mail or
by telephoning +44(0)20 7637 1010. Please then delete the e-mail and
do not disclose its contents to any person.
> This email has been scanned for Primal Pictures by the MessageLabs
Email Security System.
> __
>




[flexcoders] Tree descendants

2008-02-19 Thread Rafael Faria
I'm trying to get the descendants from my XML which has the attribute
"enabled = true"

if i try

XML(dataProvider).descendants().(@enabled = "true") 

i get an error " A term is undefined and has no properties."

which is understandable because not every node has the enabled
attribute. The question is how to get all that has the "enabled"
attribute and is set true.





[flexcoders] Tree

2008-02-19 Thread Rafael Faria
How to get the updated XML after i drag and drop some elements inside
the tree?




[flexcoders] Re: Tree Branch???

2008-02-19 Thread Rafael Faria
Try to set your labelFunction to this one

labelFunction = "parseBranches"





private function parseBranches(item:XML):String
{
if (item.name() == "folder") {
[EMAIL PROTECTED] = true;
}
return [EMAIL PROTECTED];
}




--- In flexcoders@yahoogroups.com, "xmwang1982" <[EMAIL PROTECTED]> wrote:
>
> Hi Ryan,
> 
> Thanks. It seems data decriptor is only for reading properties, not 
> changing.
> 
> Actually I think my problem is common, for example:
> 
> 
>
>
> 
> 
> In the xml above, node named "Folder" should be always displayed as a 
> branch. However, the default of flex tree is, if the node doesn't 
> have sub nodes, display it as leaf. 
> 
> So the question comes up, how to set "isBranch" property base on node 
> names?
> 
> Thanks a lot.
> 
> --- In flexcoders@yahoogroups.com, "Ryan Frishberg"  
> wrote:
> >
> > Check out dataDescriptor.  You should be able to google (or search
> > these forums) for it and get something on how to use this feature.  
> If
> > not, post back.
> > 
> > -Ryan
> > 
> > --- In flexcoders@yahoogroups.com, "xmwang1982"  wrote:
> > >
> > > Thanks Raf,
> > > 
> > > However, what I need is something called "isBranchFunction", in 
> which
> > > we can set "isBranch" property base on e.g. node name.
> > > 
> > > Thanks.
> > > 
> > > --- In flexcoders@yahoogroups.com, "Rafael Faria"
> > >  wrote:
> > > >
> > > > actually you can define a function to "labelFunction".
> > > > 
> > > > Check
> > > >
> > >
> > http://blog.flexexamples.com/2007/10/29/defining-a-custom-label-
> function-on-a-flex-tree-control/
> > > > 
> > > > 
> > > > raf
> > > > 
> > > > --- In flexcoders@yahoogroups.com, "xmwang1982"  wrote:
> > > > >
> > > > > Hi experts,
> > > > > 
> > > > > Can we determine the "isBranch" property of a tree node in a
> > > function? 
> > > > > I need to set this property according to XML node name. It 
> would be 
> > > > > nice if we can define a function like "labelFunction". 
> However it
> > > seems 
> > > > > not existing. 
> > > > > 
> > > > > I don't want to translate my XML to new XML  > > > > isBranch=..>   How to set the property in runtime? Thanks.
> > > > >
> > > >
> > >
> >
>




[flexcoders] Re: Extending Tree component

2008-02-18 Thread Rafael Faria
How can i get the Tree control i'm dropping at the DragComplete?

raf

--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> I read that too but the thing is i need to perform an action after i
> drop the element, not ondrop. This text suggest that if i'm draging
> from one tree control to another i should use "dragcomplete" but
> extending the tree component, i add the following line to the
constructor
> 
>
addEventListener(DragEvent.DRAG_COMPLETE,handleDragComplete);
> 
> whenever i drag and drop items within the same tree control it fires
> handleDragComplete function, if i drop from another one, it doesnt.
> 
> 
> To clarify more, i need to perform an action after i insert an element
> from another tree to my main tree. How i would do that? DRAG_COMPLETE
> does the job whithin the same tree control but not sure what i could
> use to perform an event after the item is inserted at the tree control.
> 
> 
> 
> 
> 
> --- In flexcoders@yahoogroups.com, Sherif Abdou  wrote:
> >
> > off the flex documentation
> > * Because of the way data to a Tree control is structured, 
> > * the Tree control handles drag and drop differently from the other
> list-based controls. 
> > * For the Tree control, the event handler for the
> dragDrop event 
> > * only performs an action when you move or copy data in the same
> Tree control, 
> > * or copy data to another Tree control. 
> > * If you drag data from one Tree control and drop it onto another
> Tree control 
> > * to move the data, the event handler for the
> dragComplete event 
> > * actually performs the work to add the data to the destination Tree
> control, 
> > * rather than the event handler for the dragDrop event, 
> > * and also removes the data from the source Tree control. 
> > * This is necessary because to reparent the data being moved, 
> > * Flex must remove it first from the source Tree control.
> > 
> > Is this what you were sort of asking?
> > 
> > 
> > 
> > - Original Message 
> > From: Rafael Faria 
> > To: flexcoders@yahoogroups.com
> > Sent: Monday, February 18, 2008 5:20:03 PM
> > Subject: [flexcoders] Re: Extending Tree component
> > 
> > you mean showDropFeedback?
> > 
> > Another problem im having is, whenever you try to drop from one tree
> > to another, the event DRAG_COMPLETE or DRAG_EXIT does not works. Any
> > explanation?
> > 
> > Alex?
> > 
> > --- In [EMAIL PROTECTED] ups.com, Sherif Abdou 
wrote:
> > >
> > > yes just use a style on it to hide it or just remove it
> > > dropIndicatorSkin= "{mx.skins. ProgrammaticSkin }"
> > > or call showFeedBack( ) and hideFeedback( )
> > > 
> > > 
> > > 
> > > - Original Message 
> > > From: Rafael Faria 
> > > To: [EMAIL PROTECTED] ups.com
> > > Sent: Monday, February 18, 2008 4:37:17 PM
> > > Subject: [flexcoders] Re: Extending Tree component
> > > 
> > > Nobody?
> > > 
> > > --- In [EMAIL PROTECTED] ups.com, "Rafael Faria"
> > >  wrote:
> > > >
> > > > I'm extending the Tree component and i have had some great
progress
> > > > with it.
> > > > 
> > > > Somethings still bug me like the place you will drop the item.
> > > > Whenever you drag an item, a thick black line show marking where
> will
> > > > be drop it. The thing is, sometimes i'm positioning the
element over
> > > > the element i want to drop and the line is still on the item above
> > it. 
> > > > 
> > > > The line i'm mentioning is this one: http://www.rafaelfa
> > ria.net/tree. png
> > > > 
> > > > Is there any way to controle this line? I mean, is there any
way to
> > > > choose exactly the item i want to drop it?
> > > > 
> > > > Thanks
> > > >
> > > 
> > > 
> > > 
> > > 
> > > 
> > > 
> >  _ _ _ _ _ _
> > > Never miss a thing. Make Yahoo your home page. 
> > > http://www.yahoo. com/r/hs
> > >
> > 
> > 
> > 
> > 
> > 
> >  
>

> > Never miss a thing.  Make Yahoo your home page. 
> > http://www.yahoo.com/r/hs
> >
>




[flexcoders] Re: Extending Tree component

2008-02-18 Thread Rafael Faria
I read that too but the thing is i need to perform an action after i
drop the element, not ondrop. This text suggest that if i'm draging
from one tree control to another i should use "dragcomplete" but
extending the tree component, i add the following line to the constructor

addEventListener(DragEvent.DRAG_COMPLETE,handleDragComplete);

whenever i drag and drop items within the same tree control it fires
handleDragComplete function, if i drop from another one, it doesnt.


To clarify more, i need to perform an action after i insert an element
from another tree to my main tree. How i would do that? DRAG_COMPLETE
does the job whithin the same tree control but not sure what i could
use to perform an event after the item is inserted at the tree control.





--- In flexcoders@yahoogroups.com, Sherif Abdou <[EMAIL PROTECTED]> wrote:
>
> off the flex documentation
> * Because of the way data to a Tree control is structured, 
> * the Tree control handles drag and drop differently from the other
list-based controls. 
> * For the Tree control, the event handler for the
dragDrop event 
> * only performs an action when you move or copy data in the same
Tree control, 
> * or copy data to another Tree control. 
> * If you drag data from one Tree control and drop it onto another
Tree control 
> * to move the data, the event handler for the
dragComplete event 
> * actually performs the work to add the data to the destination Tree
control, 
> * rather than the event handler for the dragDrop event, 
> * and also removes the data from the source Tree control. 
> * This is necessary because to reparent the data being moved, 
> * Flex must remove it first from the source Tree control.
> 
> Is this what you were sort of asking?
> 
> 
> 
> - Original Message 
> From: Rafael Faria <[EMAIL PROTECTED]>
> To: flexcoders@yahoogroups.com
> Sent: Monday, February 18, 2008 5:20:03 PM
> Subject: [flexcoders] Re: Extending Tree component
> 
> you mean showDropFeedback?
> 
> Another problem im having is, whenever you try to drop from one tree
> to another, the event DRAG_COMPLETE or DRAG_EXIT does not works. Any
> explanation?
> 
> Alex?
> 
> --- In [EMAIL PROTECTED] ups.com, Sherif Abdou  wrote:
> >
> > yes just use a style on it to hide it or just remove it
> > dropIndicatorSkin= "{mx.skins. ProgrammaticSkin }"
> > or call showFeedBack( ) and hideFeedback( )
> > 
> > 
> > 
> > - Original Message 
> > From: Rafael Faria 
> > To: [EMAIL PROTECTED] ups.com
> > Sent: Monday, February 18, 2008 4:37:17 PM
> > Subject: [flexcoders] Re: Extending Tree component
> > 
> > Nobody?
> > 
> > --- In [EMAIL PROTECTED] ups.com, "Rafael Faria"
> >  wrote:
> > >
> > > I'm extending the Tree component and i have had some great progress
> > > with it.
> > > 
> > > Somethings still bug me like the place you will drop the item.
> > > Whenever you drag an item, a thick black line show marking where
will
> > > be drop it. The thing is, sometimes i'm positioning the element over
> > > the element i want to drop and the line is still on the item above
> it. 
> > > 
> > > The line i'm mentioning is this one: http://www.rafaelfa
> ria.net/tree. png
> > > 
> > > Is there any way to controle this line? I mean, is there any way to
> > > choose exactly the item i want to drop it?
> > > 
> > > Thanks
> > >
> > 
> > 
> > 
> > 
> > 
> > 
>  _ _ _ _ _ _
> > Never miss a thing. Make Yahoo your home page. 
> > http://www.yahoo. com/r/hs
> >
> 
> 
> 
> 
> 
>  

> Never miss a thing.  Make Yahoo your home page. 
> http://www.yahoo.com/r/hs
>




[flexcoders] Re: Tree nodes expansion

2008-02-17 Thread Rafael Faria
Try TreeForm.updateList();

Raf


--- In flexcoders@yahoogroups.com, "Tom Preet" <[EMAIL PROTECTED]> wrote:
>
> Hi All,
> 
> In my application am using Tree with nodes  when I click on the node
it was
> displaying the alert,
> but when I selected the first node the related page was displaying, next
> time when I click
> on another node it was not displaying the second page.
> 
> Now I need to use it as when I click on particular node the related
page was
> displayed.
> 
> how to refresh the nodes when selecting the each node simultaniously.
> 
> *My Application:*
> http://www.adobe.com/2006/mxml"; width="1094"
> height="640" verticalScrollPolicy="off" horizontalScrollPolicy="off">
>  
>   
>  
> 
>   verticalScrollPolicy="off" horizontalScrollPolicy="off">
>  
>horizontalScrollPolicy="off" backgroundColor="white">
>showRoot="true" width="210" height="595">
>
>
> 
>
>
>
>
>
>
>
>
>
>   
>  
>  
> 
> 
>  can you suggest me how to achieve this.
> 
> Thanks,
> 
> Tomt.
>




[flexcoders] Re: Tree Branch???

2008-02-17 Thread Rafael Faria
actually you can define a function to "labelFunction".

Check
http://blog.flexexamples.com/2007/10/29/defining-a-custom-label-function-on-a-flex-tree-control/


raf

--- In flexcoders@yahoogroups.com, "xmwang1982" <[EMAIL PROTECTED]> wrote:
>
> Hi experts,
> 
> Can we determine the "isBranch" property of a tree node in a function? 
> I need to set this property according to XML node name. It would be 
> nice if we can define a function like "labelFunction". However it seems 
> not existing. 
> 
> I don't want to translate my XML to new XML  isBranch=..>   How to set the property in runtime? Thanks.
>




[flexcoders] Extending Tree component

2008-02-17 Thread Rafael Faria
I'm extending the Tree component and i have had some great progress
with it.

Somethings still bug me like the place you will drop the item.
Whenever you drag an item, a thick black line show marking where will
be drop it. The thing is, sometimes i'm positioning the element over
the element i want to drop and the line is still on the item above it. 

The line i'm mentioning is this one: http://www.rafaelfaria.net/tree.png

Is there any way to controle this line? I mean, is there any way to
choose exactly the item i want to drop it?

Thanks




[flexcoders] Re: HTTPService - POST problem

2008-02-14 Thread Rafael Faria
It didnt do anything.


--- In flexcoders@yahoogroups.com, Sherif Abdou <[EMAIL PROTECTED]> wrote:
>
> add a fault listener and see if that does anything
> 
> 
> - Original Message 
> From: Rafael Faria <[EMAIL PROTECTED]>
> To: flexcoders@yahoogroups.com
> Sent: Thursday, February 14, 2008 6:41:05 PM
> Subject: [flexcoders] HTTPService - POST problem
> 
> any idea why the following code wont post any data?
> 
> var formValues:Object = {submit: 'submit'};
> var submit:HTTPService = new HTTPService( );
> submit.url = 'http://myurl. com/service';
> submit.resultFormat = "object";
> submit.method = "POST";
> submit.addEventList ener(ResultEvent .RESULT,
> function(e:ResultEv ent):void {
> trace('result' );
> });
> submit.send( formValues) ;
> 
> 
> 
> 
> 
>  

> Looking for last minute shopping deals?  
> Find them fast with Yahoo! Search. 
http://tools.search.yahoo.com/newsearch/category.php?category=shopping
>




[flexcoders] HTTPService - POST problem

2008-02-14 Thread Rafael Faria
any idea why the following code wont post any data?


var formValues:Object = {submit: 'submit'};
var submit:HTTPService = new HTTPService();
submit.url = 'http://myurl.com/service';
submit.resultFormat = "object";
submit.method = "POST";
submit.addEventListener(ResultEvent.RESULT,
function(e:ResultEvent):void {
trace('result');
});
submit.send(formValues);




[flexcoders] Re: Rich Text Editor

2008-02-14 Thread Rafael Faria
That's really good news... i'm just wondering if you guys will skip
from Flex 3 beta 3 to flex 4 than... otherwise i reckon that flex 4 is
miles aways... hehe :p

anyway, thanks !:P


I'm working on an extension to RichTextEditor but i'm not sure how i
would create "tables" on it... any ideia you could suggest Gordon?

thanks
Raf

--- In flexcoders@yahoogroups.com, Harald Dehn <[EMAIL PROTECTED]> wrote:
>
> Hi Gordon,
> 
> this is a realy good news. Do you the a chance to get a component from  
> your "buzzword"-company in the meantime. We need a texteditor for a  
> crm application we developed in flex.
> 
> Regards,
> Harald Dehn
> 
> Am 14.02.2008 um 02:48 schrieb Gordon Smith:
> 
> >
> > > Why Adobe does not make something decent about this issue?
> >
> > We're working on it! Flash Player 10 ("Astro") and Flex 4 are likely  
> > to have a new text engine that will support right-to-left text and  
> > other text improvements.
> >
> > Gordon Smith
> > Adobe Flex SDK Team
> >
> > From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]  
> > On Behalf Of Rafael Faria
> > Sent: Wednesday, February 13, 2008 4:47 PM
> > To: flexcoders@yahoogroups.com
> > Subject: [flexcoders] Rich Text Editor
> >
> > I know this had been a big subject of discussion in the past but i
> > want to bring it up again.
> >
> > Does anybody found a good solution to implement RTE in flex?
> >
> > I tried the iframe solution but it seems that it has some problems
> > with rendering, someone work it out how to fix it?
> >
> > I know there is some people from adobe here, so my question is
> > Why Adobe does not make something decent about this issue?
> > If adobe is trying to improve the flash player as much as they can,
> > why do not spend some time in a decent RTE component?
> >
> > Any suggestion for any good RTE, even a paid one?
> >
> > Thanks
> > Raf
> >
> >
> >
> >
>




[flexcoders] Rich Text Editor

2008-02-13 Thread Rafael Faria
I know this had been a big subject of discussion in the past but i
want to bring it up again.

Does anybody found a good solution to implement RTE in flex?

I tried the iframe solution but it seems that it has some problems
with rendering, someone work it out how to fix it?

I know there is some people from adobe here, so my question is
Why Adobe does not make something decent about this issue?
If adobe is trying to improve the flash player as much as they can,
why do not spend some time in a decent RTE component?

Any suggestion for any good RTE, even a paid one?


Thanks
Raf




[flexcoders] Text Rich Editor

2008-02-13 Thread Rafael Faria
I know this had been a big subject of discussion in the past but i
want to bring it up again.

Does anybody found a good solution to implement TRE in flex?

I tried the iframe solution but it seems that it has some problems
with rendering, someone work it out how to fix it?

I know there is some people from adobe here, so my question is
Why Adobe does not make something decent about this issue?
If adobe is trying to improve the flash player as much as they can,
why do not spend some time in a decent TRE component?

Any suggestion for any good TRE, even a paid one?


Thanks
Raf




[flexcoders] Re: Tab Navigator (BUG???)

2008-02-11 Thread Rafael Faria
But any reason for this being happening?

I don't set anything to go anywhere.

raf

--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> TabNav uses historyManager.  Set historyManagementEnabled='false'
> 
>  
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Sunday, February 10, 2008 6:57 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Tab Navigator (BUG???)
> 
>  
> 
> Alex?
> 
> --- In flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> , "Rafael Faria"
>  wrote:
> >
> > Hi all,
> > 
> > I'm not sure if it's a bug, but i created a module and inside it i
> > have a lot of panels, vbox, and all kind of components. For some
> > reason when the module loads it was sending to my index page with a
> > hash symbol like http://mydomain.com/# <http://mydomain.com/> 
> > 
> > Although this wasn't happening when i test localhost it was annoying
> > me when i upload it to a live server.
> > 
> > I review my whole code and nothing apparently was wrong. Than i start
> > to remove parts of the code to find the problem. And the moment a take
> > the TabNavigator off it seems to be work just fine.
> > 
> > Someomen can clarify me why this could be possibly hapenning?
> > 
> > Below the exactly code i remove:
> > 
> >  > buttonMode="true">
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> >  
> > 
> >
>




[flexcoders] Re: Tab Navigator (BUG???)

2008-02-10 Thread Rafael Faria
Alex?


--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> Hi all,
> 
> I'm not sure if it's a bug, but i created a module and inside it i
> have a lot of panels, vbox, and all kind of components. For some
> reason when the module loads it was sending to my index page with a
> hash symbol like http://mydomain.com/#
> 
> Although this wasn't happening when i test localhost it was annoying
> me when i upload it to a live server.
> 
> I review my whole code and nothing apparently was wrong. Than i start
> to remove parts of the code to find the problem. And the moment a take
> the TabNavigator off it seems to be work just fine.
> 
> Someomen can clarify me why this could be possibly hapenning?
> 
> Below the exactly code i remove:
> 
>  buttonMode="true">
>   
> 
>  
> 
>   
>   
>   
>   
>   
>   
>   
>   
> 
>   
>




[flexcoders] Tab Navigator (BUG???)

2008-02-10 Thread Rafael Faria
Hi all,

I'm not sure if it's a bug, but i created a module and inside it i
have a lot of panels, vbox, and all kind of components. For some
reason when the module loads it was sending to my index page with a
hash symbol like http://mydomain.com/#

Although this wasn't happening when i test localhost it was annoying
me when i upload it to a live server.

I review my whole code and nothing apparently was wrong. Than i start
to remove parts of the code to find the problem. And the moment a take
the TabNavigator off it seems to be work just fine.

Someomen can clarify me why this could be possibly hapenning?

Below the exactly code i remove:




 









  




[flexcoders] Re: Still Tree

2008-02-06 Thread Rafael Faria
The thing is... the icons are just fine, even when i open the branch
for the first time, the icons are all there. The only think it doesnt
work really well is when i load the application and i try to open it
for the first time, than it just popup my leafs instead of being
smooth with that animation of the leafs blinding down if you know what
i mean.

than when i close and open it again it just work fine. This happens on
all of the branches.


all i do is set a iconFunction in the begging of my constructor to
call the parseIcons function

public class menuTree extends Tree
{
 

  public function menuTree()
  {
super();
iconFunction = parseIcons;
   }

   private function parseIcons(node:XML, type:String = ""): void 
   {
var nodeName:String = node.name();
if (type == "edit") {
if (nodeName == "module") {
if (getStyle("defaultEditModuleIcon") 
!= null) { 
setItemIcon(node, 
getStyle("defaultEditModuleIcon"),
getStyle("defaultEditModuleIcon"));
}
} else if (nodeName == "category") { 
if (getStyle("folderEditIcon") != null) 
{ 
setItemIcon(node, getStyle("folderEditIcon"),
getStyle("folderEditIcon"));
}
} else {
if (getStyle("defaultEditLeafIcon") != 
null) { 
setItemIcon(node, 
getStyle("defaultEditLeafIcon"),
getStyle("defaultEditLeafIcon"));
}
}
} else {
if (nodeName == "module") {
setItemIcon(node, getStyle("defaultModuleIcon"),
getStyle("defaultModuleIcon"));
} else if (nodeName == "category") { 
setItemIcon(node, getStyle("folderClosedIcon"),
getStyle("folderOpenIcon"));
} else {
setItemIcon(node, getStyle("defaultLeafIcon"),
getStyle("defaultLeafIcon"));
}
}
}

}

The icons are embed on a CSS file.

Tree {
disclosureClosedIcon: Embed('../assets/images/plus.png');
disclosureOpenIcon: Embed('../assets/images/minus.png');
folderClosedIcon: Embed('../assets/images/application.png');
folderOpenIcon: Embed('../assets/images/application_put.png');
folderEditIcon: Embed('../assets/images/application_edit.png');
defaultLeafIcon: Embed('../assets/images/file.png');
defaultEditLeafIcon: Embed('../assets/images/file_edit.png');
defaultModuleIcon: Embed('../assets/images/module.png');
defaultEditModuleIcon: Embed('../assets/images/module_edit.png');
disableColor:#CC;
defaultColor:#00;
indentation:14;
}





   






--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> If the icon is embedded in a different MXML file then it won't be found
> in the destination tree
> 
>  
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Wednesday, February 06, 2008 3:27 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Still Tree
> 
>  
> 
> another thing is happening is whenever i drag an element from another
> tree into my main tree the icon does not appear.
> 
> why would this happen?! 
> 
> --- In flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> , "Alex Harui"  wrote:
> >
> > 1. setStyle("indentation", ...)
> > 
> > 2. itemRenderer = new ClassFactory(myTreeRenderer)
> > 
> > 3. If your renderer invalidates the tree it will cancel the tween
> > 
> > 4. Make sure you're using the right methods at the right time
> > (commitProperties, measure, updateDisplayList)
> > 
> > 
> > 
> > 
> > 
> > From: flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> [mailto:flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> ] On
> > Behalf Of Rafael Faria
> &

[flexcoders] Re: Still Tree

2008-02-06 Thread Rafael Faria
another thing is happening is whenever i drag an element from another
tree into my main tree the icon does not appear.

why would this happen?! 



--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> 1.   setStyle("indentation", ...)
> 
> 2.   itemRenderer = new ClassFactory(myTreeRenderer)
> 
> 3.   If your renderer invalidates the tree it will cancel the tween
> 
> 4.   Make sure you're using the right methods at the right time
> (commitProperties, measure, updateDisplayList)
> 
>  
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Tuesday, February 05, 2008 5:05 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Still Tree
> 
>  
> 
> For some reason whenever i use setItemIcon on a function set for a
> iconFunction its behavior is very weird.
> 
> --- In flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> , "Rafael Faria"
>  wrote:
> >
> > I think is better to post most of my questions and if anyone can help
> > just reply with an answer :)
> > 
> > I'm still struggling myself with packages so if someone has a good
> > article about it or where i can find a good material about packages it
> > would be very helpful as well.
> > 
> > 
> > 1 - There is anyway to set the indentation of each element? how?
> > 
> > 2 - itemRenderer = myTreeRender i get an error... how can i make a
> > reference inside my TreeCustom class? if i put  > itemRenderer="com.myTreeRendeder" /> it works just fine. But i want to
> > be able to set it inside the package as a default.
> > 
> > 3 - For some reason, when i first open a branch it doesnt play that
> > easing animation, but after it open it works just fine... someone
> > knows why it happens?
> > 
> > 4 - I set a mouseevent.double_click and whenever i double click on a
> > branch and it opens the leaf icons doesnt apear until i click in
> > something else. someone knows why it happens too?
> > 
> > Well.. i will be here googling trying to find the answers but if
> > someone knows how to help me it would be great :P
> > 
> > thanks
> >
>




[flexcoders] Re: Still Tree

2008-02-06 Thread Rafael Faria
Hi Alex,

thanks for your reply.

I just dont get it why this function would invalidate the renderer
once it works fine after i open it once.

menuTree(owner).setItemIcon(_oTreeListData,
getStyle("defaultModuleIcon"), getStyle("defaultModuleIcon"));



--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> 1.   setStyle("indentation", ...)
> 
> 2.   itemRenderer = new ClassFactory(myTreeRenderer)
> 
> 3.   If your renderer invalidates the tree it will cancel the tween
> 
> 4.   Make sure you're using the right methods at the right time
> (commitProperties, measure, updateDisplayList)
> 
>  
> 
> ________
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Tuesday, February 05, 2008 5:05 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Still Tree
> 
>  
> 
> For some reason whenever i use setItemIcon on a function set for a
> iconFunction its behavior is very weird.
> 
> --- In flexcoders@yahoogroups.com <mailto:flexcoders%40yahoogroups.com>
> , "Rafael Faria"
>  wrote:
> >
> > I think is better to post most of my questions and if anyone can help
> > just reply with an answer :)
> > 
> > I'm still struggling myself with packages so if someone has a good
> > article about it or where i can find a good material about packages it
> > would be very helpful as well.
> > 
> > 
> > 1 - There is anyway to set the indentation of each element? how?
> > 
> > 2 - itemRenderer = myTreeRender i get an error... how can i make a
> > reference inside my TreeCustom class? if i put  > itemRenderer="com.myTreeRendeder" /> it works just fine. But i want to
> > be able to set it inside the package as a default.
> > 
> > 3 - For some reason, when i first open a branch it doesnt play that
> > easing animation, but after it open it works just fine... someone
> > knows why it happens?
> > 
> > 4 - I set a mouseevent.double_click and whenever i double click on a
> > branch and it opens the leaf icons doesnt apear until i click in
> > something else. someone knows why it happens too?
> > 
> > Well.. i will be here googling trying to find the answers but if
> > someone knows how to help me it would be great :P
> > 
> > thanks
> >
>




[flexcoders] Re: Still Tree

2008-02-05 Thread Rafael Faria
Would be this a bug? Because i tried to change the icon inside the
itemrenderer but its behaving weird as well.



--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> For some reason whenever i use setItemIcon on a function set for a
> iconFunction its behavior is very weird.
> 
> 
> 
> --- In flexcoders@yahoogroups.com, "Rafael Faria"
>  wrote:
> >
> > I think is better to post most of my questions and if anyone can help
> > just reply with an answer :)
> > 
> > I'm still struggling myself with packages so if someone has a good
> > article about it or where i can find a good material about packages it
> > would be very helpful as well.
> > 
> > 
> > 1 - There is anyway to set the indentation of each element? how?
> > 
> > 2 - itemRenderer = myTreeRender i get an error... how can i make a
> > reference inside my TreeCustom class? if i put  > itemRenderer="com.myTreeRendeder" /> it works just fine. But i want to
> > be able to  set it inside the package as a default.
> > 
> > 3 - For some reason, when i first open a branch it doesnt play that
> > easing animation, but after it open it works just fine... someone
> > knows why it happens?
> > 
> > 4 - I set a mouseevent.double_click and whenever i double click on a
> > branch and it opens the leaf icons doesnt apear until i click in
> > something else. someone knows why it happens too?
> > 
> > Well.. i will be here googling trying to find the answers but if
> > someone knows how to help me it would be great :P
> > 
> > thanks
> >
>




[flexcoders] Re: Still Tree

2008-02-05 Thread Rafael Faria
For some reason whenever i use setItemIcon on a function set for a
iconFunction its behavior is very weird.



--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> I think is better to post most of my questions and if anyone can help
> just reply with an answer :)
> 
> I'm still struggling myself with packages so if someone has a good
> article about it or where i can find a good material about packages it
> would be very helpful as well.
> 
> 
> 1 - There is anyway to set the indentation of each element? how?
> 
> 2 - itemRenderer = myTreeRender i get an error... how can i make a
> reference inside my TreeCustom class? if i put  itemRenderer="com.myTreeRendeder" /> it works just fine. But i want to
> be able to  set it inside the package as a default.
> 
> 3 - For some reason, when i first open a branch it doesnt play that
> easing animation, but after it open it works just fine... someone
> knows why it happens?
> 
> 4 - I set a mouseevent.double_click and whenever i double click on a
> branch and it opens the leaf icons doesnt apear until i click in
> something else. someone knows why it happens too?
> 
> Well.. i will be here googling trying to find the answers but if
> someone knows how to help me it would be great :P
> 
> thanks
>




[flexcoders] Re: Still Tree

2008-02-05 Thread Rafael Faria
The double click problem i solved using 
updateList();




--- In flexcoders@yahoogroups.com, "Rafael Faria"
<[EMAIL PROTECTED]> wrote:
>
> I think is better to post most of my questions and if anyone can help
> just reply with an answer :)
> 
> I'm still struggling myself with packages so if someone has a good
> article about it or where i can find a good material about packages it
> would be very helpful as well.
> 
> 
> 1 - There is anyway to set the indentation of each element? how?
> 
> 2 - itemRenderer = myTreeRender i get an error... how can i make a
> reference inside my TreeCustom class? if i put  itemRenderer="com.myTreeRendeder" /> it works just fine. But i want to
> be able to  set it inside the package as a default.
> 
> 3 - For some reason, when i first open a branch it doesnt play that
> easing animation, but after it open it works just fine... someone
> knows why it happens?
> 
> 4 - I set a mouseevent.double_click and whenever i double click on a
> branch and it opens the leaf icons doesnt apear until i click in
> something else. someone knows why it happens too?
> 
> Well.. i will be here googling trying to find the answers but if
> someone knows how to help me it would be great :P
> 
> thanks
>




[flexcoders] Still Tree

2008-02-05 Thread Rafael Faria
I think is better to post most of my questions and if anyone can help
just reply with an answer :)

I'm still struggling myself with packages so if someone has a good
article about it or where i can find a good material about packages it
would be very helpful as well.


1 - There is anyway to set the indentation of each element? how?

2 - itemRenderer = myTreeRender i get an error... how can i make a
reference inside my TreeCustom class? if i put  it works just fine. But i want to
be able to  set it inside the package as a default.

3 - For some reason, when i first open a branch it doesnt play that
easing animation, but after it open it works just fine... someone
knows why it happens?

4 - I set a mouseevent.double_click and whenever i double click on a
branch and it opens the leaf icons doesnt apear until i click in
something else. someone knows why it happens too?

Well.. i will be here googling trying to find the answers but if
someone knows how to help me it would be great :P

thanks




[flexcoders] Re: TreeItemRenderer

2008-02-05 Thread Rafael Faria
I get the error

1067: Implicit coercion of a value of type Class to an unrelated
type mx.core:IFactory.  menuTree.as line 36 1202257471190   38776




--- In flexcoders@yahoogroups.com, Sherif Abdou <[EMAIL PROTECTED]> wrote:
>
> just itemRenderer=TreeRender
> 
> 
> - Original Message 
> From: Rafael Faria <[EMAIL PROTECTED]>
> To: flexcoders@yahoogroups.com
> Sent: Monday, February 4, 2008 11:21:00 PM
> Subject: [flexcoders] Re: TreeItemRenderer
> 
> 
> Yeah, i'm extending the Tree but if i do itemRenderer = "" what would
> be the value? my TreeItemRenederer is another package called TreeRender 
> 
> so it doesnt work like (itemRenderer= "TreeRender" ) because
> itemREnderer is not a String variable.
> 
> --- In [EMAIL PROTECTED] ups.com, Sherif Abdou  wrote:
> >
> > so are you extending the tree? if so you can just do itemRenderer=

> > 
> > 
> > - Original Message 
> > From: Rafael Faria 
> > To: [EMAIL PROTECTED] ups.com
> > Sent: Monday, February 4, 2008 10:57:53 PM
> > Subject: [flexcoders] TreeItemRenderer
> > 
> > I'm building my first component using actionscript. 
> > 
> > I'm trying to set some default values or call automatically some
> > functions whenever i instantiate the Tree. How i would set the
> > itemRenderer inside my custom Tree component?
> > 
> > I know if i set the  it
> > will call myItemRender class. But i want to call it FROM my package.
> > 
> > How i would do that? any ideas?
> > 
> > Thanks
> > 
> > 
> > 
> > 
> > 
> > 
>  _ _ _ _ _ _
> > Never miss a thing. Make Yahoo your home page. 
> > http://www.yahoo. com/r/hs
> >
> 
> 
> 
> 
> 
>  

> Looking for last minute shopping deals?  
> Find them fast with Yahoo! Search. 
http://tools.search.yahoo.com/newsearch/category.php?category=shopping
>




[flexcoders] Re: TreeItemRenderer

2008-02-04 Thread Rafael Faria

Yeah, i'm extending the Tree but if i do itemRenderer = "" what would
be the value? my TreeItemRenederer is another package called TreeRender 

so it doesnt work like (itemRenderer="TreeRender") because
itemREnderer is not a String variable.

--- In flexcoders@yahoogroups.com, Sherif Abdou <[EMAIL PROTECTED]> wrote:
>
> so are you extending the tree? if so you can just do itemRenderer=
> 
> 
> ----- Original Message 
> From: Rafael Faria <[EMAIL PROTECTED]>
> To: flexcoders@yahoogroups.com
> Sent: Monday, February 4, 2008 10:57:53 PM
> Subject: [flexcoders] TreeItemRenderer
> 
> I'm building my first component using actionscript. 
> 
> I'm trying to set some default values or call automatically some
> functions whenever i instantiate the Tree. How i would set the
> itemRenderer inside my custom Tree component?
> 
> I know if i set the  it
> will call myItemRender class. But i want to call it FROM my package.
> 
> How i would do that? any ideas?
> 
> Thanks
> 
> 
> 
> 
> 
>  

> Never miss a thing.  Make Yahoo your home page. 
> http://www.yahoo.com/r/hs
>




[flexcoders] TreeItemRenderer

2008-02-04 Thread Rafael Faria
I'm building my first component using actionscript. 

I'm trying to set some default values or call automatically some
functions whenever i instantiate the Tree. How i would set the
itemRenderer inside my custom Tree component?

I know if i set the  it
will call myItemRender class. But i want to call it FROM my package.

How i would do that? any ideas?

Thanks




[flexcoders] Re: Tree

2008-02-04 Thread Rafael Faria
just found out... If someone else has the same problem just add a
attribute " isBranch="true"  "  on your XML node that you want to
force to be a branch.

Thanks


--- In flexcoders@yahoogroups.com, "Alex Harui" <[EMAIL PROTECTED]> wrote:
>
> Read up on isBranch in ITreeDataDescriptor
> 
>  
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
> Behalf Of Rafael Faria
> Sent: Sunday, February 03, 2008 10:14 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Tree
> 
>  
> 
> I'm working on a tree based "menu". 
> 
> My problem is, whenever i drag and drop some child from a "main" 
> folder, instead of continues as a folder icon it automatically
> transform in a "page" icon...
> 
> how can i prevent that?
>




  1   2   >