[flexcoders] Border collapse in Grid?

2008-06-22 Thread williamkusumo
Is there a CSS border-collapse equivalent to Flex Grid? I want to create a 
tabular data with 
1px border around each cell. And no, I don't want to use DataGrid.

Thanks!




[flexcoders] ComboBox selectedLabel bug?

2008-06-17 Thread williamkusumo
I can't seem to get selectedLabel out of a ComboBox, it always returns
empty string for me. Is this a known bug? I ended up doing this instead:

cb.itemToLabel(cb.selectedItem)

Any help is appreciated, thank you.



[flexcoders] Expand/Collapse AdvancedDataGrid row?

2008-05-21 Thread williamkusumo
Hello good people!

I have a DataGrid with a button in each row and when you press one of the 
button, there 
should be a control panel that expands below that row (pushing down everything 
else). This 
panel spans the entire row and has a specific height.

Any recommendation on how to achieve this? I've seen ADG demo on group-able 
items, but 
is this the right way to do it? If so, that means I need to insert dummy data 
for each row in 
the dataProvider?

Any help is highly appreciated.

Thanks!



[flexcoders] Trouble manually creating ToolTip with showEffect and hideEffect

2007-12-15 Thread williamkusumo
I use createToolTip to create a ToolTip manually, but somehow I couldn't get 
the showEffect 
and hideEffect to apply. I have properly set the ToolTipManager.showEffect and 
ToolTipManager.hideEffect to an effect, but it's not biting. The same effect 
works if I just use 
the 'tooltip' property of a component. Anyone knows why?



[flexcoders] Trouble manually creating ToolTip with showEffect and hideEffect

2007-12-15 Thread williamkusumo
I use createToolTip to create a ToolTip manually, but somehow I couldn't get 
the showEffect 
and hideEffect to apply. I have properly set the ToolTipManager.showEffect and 
ToolTipManager.hideEffect to an effect, but it's not biting. The same effect 
works if I just use 
the 'tooltip' property of a component. Anyone knows why?



[flexcoders] Trouble manually creating ToolTip with showEffect and hideEffect

2007-12-14 Thread williamkusumo
Hello, flexcoders!

Anyone had experience using createToolTip() to create ToolTip manually and then 
have 
showEffect and hideEffect apply to it? I have to manually create the ToolTips 
because I want 
them to follow my mouse in realtime. I also want it to fade in and out on 
show/hide, so I set 
the effects like this:

ToolTipManager.showEffect = this.myShowEffect;
ToolTipManager.hideEffect = this.myHideEffect;

But this doesn't seem to work for manually created ToolTip. It work if you 
specify the tooltip 
property in the components markup. Any idea why?

Thanks!



[flexcoders] Component that passes through mouse events (?)

2007-12-06 Thread williamkusumo
Hi fellow flexcoders,

Is it possible to have a component that is on top of another component yet it 
does not block 
any mouse events, instead it passes them through to the component underneath it?

I need to overlay a component over another one for visual treatment, but it is 
blocking the 
mouse interaction.

Thanks in advance for the help, I appreciate it.



[flexcoders] ExternalInterface race conditions problem. Please help!

2007-11-20 Thread williamkusumo
Can anyone shed a light on how code execution flows when you have JS
calling AS function which calls another JS function? I seem to be
getting a very unpredictable race conditions.

So here's how my code kind of looks like:

[JS]
 JSLine1();
 swfMov.callASFuncA(); // this calls AS functions
 JSLine3();

[AS]
function ASFuncA()
{
 ASLine1();
 ExternalInterface.call(callJSFuncB);
 ASLine3();
}

So does JSLine3() get called before callJSFuncB()? Or does the code
execution hangs on callASFuncA() until it returns? And what about
ASLine3(), when is it gonna get called?

Thanks for the help!



[flexcoders] HorizontalList drop indicator weirdness

2007-11-12 Thread williamkusumo
Hello!

I have a HorizontalList with drag  drop enabled, so you can
re-arrange stuff in it. For some reason in HorizontalList, the drop
indicator line appears on top of an item instead of on the side of the
item like in TileList. I was wondering if there's a way to change this.

I was trying to reason why this is happening and my guess is
HorizontalList is probably a TileList with direction=vertical and max
row set to 1. Thus, it is working as if it is a tall 1-column list and
that's why the drop indicator is on top of the item.

I appreciate the advice!



[flexcoders] Custom skin on HScrollBar appearing differently than VScrollBar

2007-11-12 Thread williamkusumo
Hi flexcoders!

I have a VScrollBar and HScrollBar that both loads identical skins
(it's simply some PNGs). The VScrollBar looks great, but HScrollBar
ends up having slightly cropped up/down arrow (at the tip of the
arrow) and the thumb is lower than where it's supposed to be.

Why is this so? Anyone has an idea?

Thanks!



[flexcoders] Drag-scroll in a List not working on Mac (?)

2007-11-12 Thread williamkusumo
I have a List that has drag  drop enabled so you can rearrange the
items. On Windows, while you are dragging an item, you can go near the
bottom of the list and it'll scroll if there are more content and it's
scrollable. I can't seem to get this behavior on Mac. Is this a known bug?

Thanks!



[flexcoders] Re: How do I remove/modify the default effect on List-based drag drop?

2007-10-15 Thread williamkusumo
Wow, really?! That's odd, it seems very un-Flex-like to set something
like that in stone.

Thanks, Alex!

--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 There is no API to control those effects.  I don't see any obvious
 workaround either.
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of williamkusumo
 Sent: Friday, October 12, 2007 6:46 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] How do I remove/modify the default effect on
 List-based drag drop?
 
  
 
 I'd like to either remove/modify the default animation that happens
 when you drag and drop a list item, how might I go about doing that? I
 tried specifying addedEffect and moveEffect with no luck.
 
 Appreciate your help! Thanks!





[flexcoders] Re: Wheel-scroll on Mac

2007-10-05 Thread williamkusumo
I guess everyone is still on their way back from Adobe Max? :(

I should've asked someone while I was there...

--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 Is wheel-scroll bug on Mac gonna be fixed anytime soon? I am thinking
 if it's worth doing the Javascript hack I've found online to solve
 this issue for now.
 
 Thanks!





[flexcoders] Re: FlexBuilder feature rich? Not as a development tool.

2007-10-05 Thread williamkusumo
Let's all vote for wheel-scroll issue on Mac! And also wheel-scroll
issue when wmode is on! This issue seems to be have plagued Flash
since the beginning of age, is there a reason why this hasn't been
resolved yet?

Thanks!

--- In flexcoders@yahoogroups.com, Matt Chotin [EMAIL PROTECTED] wrote:

 Beta 2 essentially exposes the features that we have planned for the
 Flex 3 release.  But one thing that we talked about at MAX is how
 excited developers should be for Thermo, because it means that we're
 going to be able to allow Flex Builder to become even more developer
 focused while Thermo can solve more problems for designers.  This means
 more engineering effort behind the coding features like you mention.
 
  
 
 So please file and vote for bugs (can't stress the voting enough) at
 http://bugs.adobe.com/flex, it's really the best way for us to gauge
 what developer features we need to focus on since you should assume we
 are not all-powerful and can't get everything done in a single release.
 
  
 
 Matt 
 
  
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of dbronk
 Sent: Friday, October 05, 2007 6:34 AM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] FlexBuilder feature rich? Not as a development
 tool.
 
  
 
 I have seen a sneak peak a month or 2 ago of FlexBuilder 3. I've
 tried to load Flex 3 Beta 1 on my box with no luck. It simply erred
 out on the install. Have not tried beta 2 yet. But it is beta so
 that is fine.
 
 But, from the sneak peak I saw, there were only a few IDE features
 added that still leaves it behind almost every other IDE out there. I
 know that Flex 3 will add some basic refactoring features and some
 people said wow, that's cool!. But I said, wow, it's about time! My
 question... How much effort is Adobe putting into the FlexBuilder IDE
 (which we pay for) as it is very behind the times as far as expected
 developer productivity features (found in almost all FREE progamming
 language IDE's). I've been waiting for some extemely basic ones such as:
 
 - Code formatter to reformat code of sloppy developers not caring
 about the format of their code.
 
 - Import organization, which organizes, add/deletes imports as needed.
 
 - Smarter indentation. Cut a section of code from one place in my
 file to another, it should re-indent as necessary for the destination.
 
 - Renaming or moving a class should go through the entire project and
 refactor for me.
 
 These are just some of the most basic things and the list goes on. 
 What, if any, should we expect to see in Flex 3?
 
 Don't get me wrong, I think Flex absolutely rocks! But, I do find
 that I lose productivity with these very basic and completely expected
 features that I'm use to having.
 
 Dale





[flexcoders] Wheel-scroll on Mac

2007-10-02 Thread williamkusumo
Is wheel-scroll bug on Mac gonna be fixed anytime soon? I am thinking
if it's worth doing the Javascript hack I've found online to solve
this issue for now.

Thanks!



[flexcoders] Re: Trouble skinning ComboBox that is shorter than default one...

2007-09-26 Thread williamkusumo
Is there a way, maybe, to adjust the postiion of TextInput inside the
ComboBox, but not the height of it?

Thanks!

--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 Calling all skinners!
 
 I am skinning a ComboBox using some vector images in Flash and the
 ComboBox is shorter in height than the default ComboBox. I notice that
 I have to explicitly set the height of the skinned ComboBox, otherwise
 it'll stretch the skin to its default height.
 
 SO, that's fine...annoying that's all. The problem is, after I set the
 height, the text on the ComboBox becomes cut-off. Any idea how I might
 resolve this issue?
 
 Thanks! Appreciate the help!





[flexcoders] Re: Trouble skinning ComboBox that is shorter than default one...

2007-09-26 Thread williamkusumo
Hmm, that means I have to extend ComboBox, right? Hmm...that sucks, I
wish there's an easier way.

Thanks!

--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 Sure, set its position in updateDisplayList
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of williamkusumo
 Sent: Wednesday, September 26, 2007 11:54 AM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Trouble skinning ComboBox that is shorter than
 default one...
 
 
 
 Is there a way, maybe, to adjust the postiion of TextInput inside the
 ComboBox, but not the height of it?
 
 Thanks!
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 , williamkusumo williamkusumo@
 wrote:
 
  Calling all skinners!
  
  I am skinning a ComboBox using some vector images in Flash and the
  ComboBox is shorter in height than the default ComboBox. I notice that
  I have to explicitly set the height of the skinned ComboBox, otherwise
  it'll stretch the skin to its default height.
  
  SO, that's fine...annoying that's all. The problem is, after I set the
  height, the text on the ComboBox becomes cut-off. Any idea how I might
  resolve this issue?
  
  Thanks! Appreciate the help!
 





[flexcoders] Re: Trouble skinning ComboBox that is shorter than default one...

2007-09-26 Thread williamkusumo
Oh, I thought you have to re-define all the functions. I think I was
mistaking extending vs implementing :)

Thanks, Alex! As always :D

--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 Aw, c'mon it should look like:
  
 mx:ComboBox
 mx:Script
 ![CDATA[
 override protected function updateDisplayList(w:Number,
 h:Number):void
 {
 super.updateDisplayList(w,h);
 textInput.y = ???
 }
 ]]
 /mx:Script
 /mx:ComboBox
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of williamkusumo
 Sent: Wednesday, September 26, 2007 3:02 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Trouble skinning ComboBox that is shorter than
 default one...
 
 
 
 Hmm, that means I have to extend ComboBox, right? Hmm...that sucks, I
 wish there's an easier way.
 
 Thanks!
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 , Alex Harui aharui@ wrote:
 
  Sure, set its position in updateDisplayList
  
  
  
  From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 ] On
  Behalf Of williamkusumo
  Sent: Wednesday, September 26, 2007 11:54 AM
  To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com 
  Subject: [flexcoders] Re: Trouble skinning ComboBox that is shorter
 than
  default one...
  
  
  
  Is there a way, maybe, to adjust the postiion of TextInput inside the
  ComboBox, but not the height of it?
  
  Thanks!
  
  --- In flexcoders@yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
 mailto:flexcoders%40yahoogroups.com
  , williamkusumo williamkusumo@
  wrote:
  
   Calling all skinners!
   
   I am skinning a ComboBox using some vector images in Flash and the
   ComboBox is shorter in height than the default ComboBox. I notice
 that
   I have to explicitly set the height of the skinned ComboBox,
 otherwise
   it'll stretch the skin to its default height.
   
   SO, that's fine...annoying that's all. The problem is, after I set
 the
   height, the text on the ComboBox becomes cut-off. Any idea how I
 might
   resolve this issue?
   
   Thanks! Appreciate the help!
  
 





[flexcoders] Trouble skinning ComboBox that is shorter than default one...

2007-09-25 Thread williamkusumo
Calling all skinners!

I am skinning a ComboBox using some vector images in Flash and the
ComboBox is shorter in height than the default ComboBox. I notice that
I have to explicitly set the height of the skinned ComboBox, otherwise
it'll stretch the skin to its default height.

SO, that's fine...annoying that's all. The problem is, after I set the
height, the text on the ComboBox becomes cut-off. Any idea how I might
resolve this issue?

Thanks! Appreciate the help!



[flexcoders] Re: Is it possible to anti-alias fonts without embedding?

2007-09-24 Thread williamkusumo
Alex, are you sure about this? You mean, I will get anti-aliased
system text by default without having to set anything? I've never seen
this happening. I've tried explicitly setting cacheAsBitmaps to false.

Thanks!

--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 Device fonts are anti-aliased except when cached as bitmaps.  They
 should be anti-aliased even when cached as bitmaps in the upcoming
 Player 9,0,60 and later.
 
  
 
 The anti-aliasing isn't as good for small fonts as when you embed the
 font, so you have to trade off swf size for quality.
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of williamkusumo
 Sent: Friday, September 21, 2007 7:03 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Is it possible to anti-alias fonts without
 embedding?
 
  
 
 Is it possible to get anti-alias fonts without having to embed a font?
 I need to achieve anti-alias look, but doesn't want to increase the
 size of the app by embedding fonts.
 
 Thanks! Appreciate the help!





[flexcoders] Re: Is it possible to anti-alias fonts without embedding?

2007-09-24 Thread williamkusumo
Hmm, I guess I misunderstood how anti-alias text supposed to work.

So for application like the Adobe Max Session Scheduler (sorry,
couldn't think of any other examples), all the text seems to be
anti-aliased, even when my effect setting is off, so I assume it is
using embedded font, correct?

Thanks!

--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 Anti-aliasing device text is dependent on your system settings in
 Windows.
 
  
 
 ControlPanel-Display-AppearanceEffects-Use the following method to
 smooth edges of screen fonts.
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of williamkusumo
 Sent: Monday, September 24, 2007 11:55 AM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Is it possible to anti-alias fonts without
 embedding?
 
  
 
 Alex, are you sure about this? You mean, I will get anti-aliased
 system text by default without having to set anything? I've never seen
 this happening. I've tried explicitly setting cacheAsBitmaps to false.
 
 Thanks!
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 , Alex Harui aharui@ wrote:
 
  Device fonts are anti-aliased except when cached as bitmaps. They
  should be anti-aliased even when cached as bitmaps in the upcoming
  Player 9,0,60 and later.
  
  
  
  The anti-aliasing isn't as good for small fonts as when you embed the
  font, so you have to trade off swf size for quality.
  
  
  
  
  
  From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 ] On
  Behalf Of williamkusumo
  Sent: Friday, September 21, 2007 7:03 PM
  To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com 
  Subject: [flexcoders] Is it possible to anti-alias fonts without
  embedding?
  
  
  
  Is it possible to get anti-alias fonts without having to embed a font?
  I need to achieve anti-alias look, but doesn't want to increase the
  size of the app by embedding fonts.
  
  Thanks! Appreciate the help!
 





[flexcoders] Separator in ComboBox item?

2007-09-20 Thread williamkusumo
Is it possible to insert a separator in ComboBox items? This separator
would not be clickable like any other item.

Appreciate the help!



[flexcoders] Changing styleName at run-time

2007-09-17 Thread williamkusumo
Hi!

I have a skinned play button that needs to turn into a pause button
when clicked. Is it possible to change the styleName at run-time? If
not, what is the recommended way to change the button skin when user
clicks it?

Appreciate the help!



[flexcoders] Re: Changing styleName at run-time

2007-09-17 Thread williamkusumo
Argh, my newbie-ness shows. styleName is part of the property, I can
just change it like any other prop. Sorry to waste your time :)

--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 Hi!
 
 I have a skinned play button that needs to turn into a pause button
 when clicked. Is it possible to change the styleName at run-time? If
 not, what is the recommended way to change the button skin when user
 clicks it?
 
 Appreciate the help!





[flexcoders] Re: Cannot get unselected Tab to be pure white color...

2007-09-14 Thread williamkusumo
Hmm, this doesn't get rid of the border, it simply sets the color to
what the background color would look.

And it's not pure white either, the highlight only sets the upper half
of the tab to white.

I think the only way to do this is to override the skin, because the
default skin is actually semi-transparent.

Another related question. Is it possible to have fillColor works on
selected tab? The selected tab is always a flat color, can I use CSS
to make it a gradient?

Thanks!

--- In flexcoders@yahoogroups.com, Randy Martin [EMAIL PROTECTED] wrote:

 You can get rid of the border around the tabs, keep the border
around the
 tab body, and make the unselected tabs white like this:
  
 TabNavigator {
   tabWidth: 80;
   tabHeight: 25;
   horizontalAlign: right;
   horizontalGap: 3;
   backgroundColor: #EE;
   tabStyleName: myTabs;
   selectedTabTextStyleName: mySelectedTabs;
   borderThickness: 1;
   borderColor: #33;
 }
  
 .myTabs {
   highlightAlphas: 1, 1;
   fillAlphas: 1, 1;
   fillColors: #FF, #FF;
   cornerRadius: 0;
   fontSize: 12;
   color: #CC;
 }
  
 .mySelectedTabs {
   color: #66;
 }
  
 Unfortunately, this makes the selected tab the same color as the
 TabNavigator backgroundColor. If you want to distinguish the
selected tab
 from the others, you need to make the TabNavigator backgroundColor
different
 than white, or in this case #EE.
  
 Hope this helps.
  
 
_  
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of williamkusumo
 Sent: Thursday, September 13, 2007 11:51 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Cannot get unselected Tab to be pure white
 color...
 
 
 
 Another thing I am having trouble with is getting rid of the borders
 around the tab (the top part, NOT the tab body)
 
 Any idea what style I have to set? The documentation seems incomplete. 
 
 Thanks!
 
 --- In HYPERLINK
 mailto:flexcoders%40yahoogroups.com[EMAIL PROTECTED],
 williamkusumo williamkusumo@
 wrote:
 
  Hi!
  
  I am trying to get the unselected Tab in a TabNavigator to be pure
  white, but so far everything I tried always ended up with a gray-ish
  tab. Why is that??
  
  Here's the CSS I have:
  
  .myTab
  {
  tabWidth:80;
  tabHeight:25;
  horizontalAlign:-right;
  horizontalGap:-3;
  backgroundColor:-#EE;
  tabStyleName:-myTabs;
  selectedTabTextStyl-eName:mySelecte-dTabs;
  }
  .myTabs
  {
  cornerRadius:-0;
  fontSize:12;
  color:#CC;
  fillColors:#-FF, #FF, #FF, #FF;
  fillAlphas:1, 1;
  highlightAlphas:-0, 0;
  }
  .mySelectedTabs
  {
  color:#66;
  }
  
  I tried adjusting the alphas as well, no luck, is there any other
  styles I need to be setting? Appreciate the help!
 
 
 
 
  
 
 
 No virus found in this outgoing message.
 Checked by AVG. 
 Version: 7.5.485 / Virus Database: 269.13.18/1007 - Release Date:
9/13/2007
 9:48 PM





[flexcoders] Re: Cannot get unselected Tab to be pure white color...

2007-09-13 Thread williamkusumo
Another thing I am having trouble with is getting rid of the borders
around the tab (the top part, NOT the tab body)

Any idea what style I have to set? The documentation seems incomplete. 

Thanks!

--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 Hi!
 
 I am trying to get the unselected Tab in a TabNavigator to be pure
 white, but so far everything I tried always ended up with a gray-ish
 tab. Why is that??
 
 Here's the CSS I have:
 
 .myTab
 {
   tabWidth:80;
   tabHeight:25;
   horizontalAlign:right;
   horizontalGap:3;
   backgroundColor:#EE;
   tabStyleName:myTabs;
   selectedTabTextStyleName:mySelectedTabs;
 }
 .myTabs
 {
   cornerRadius:0;
   fontSize:12;
   color:#CC;
   fillColors:#FF, #FF, #FF, #FF;
   fillAlphas:1, 1;
   highlightAlphas:0, 0;
 }
 .mySelectedTabs
 {
   color:#66;
 }
 
 I tried adjusting the alphas as well, no luck, is there any other
 styles I need to be setting? Appreciate the help!





[flexcoders] Is CSS child selector supported?

2007-09-11 Thread williamkusumo
I am trying to style the GridItem of a grid that has a specific style
name, I tried to do this:

.editFormGrid GridItem
{
   ...
}

and the styles won't take...is child selector supported in Flex CSS?

Thanks!



[flexcoders] Variable instances behavior in Actionscript

2007-09-04 Thread williamkusumo
Very stupid question which has been bugging me for a while and just
might be the most basic question in this group.

How does a object instance behave in Actionscript? Say if I have this:

var a:Book = new Book();
var b:Book = a;
var c:Book = b;

So does c actually point to the instance that a and b is pointing to
or is it pointing to b?

And if I do this:

c = null;

Does a and b get nulled too or does it act more like a pointer where
it means c is now pointing to null, a and b still points to the object
instance?

Thanks!



[flexcoders] Re: Problem with HTTPService ResultEvent.RESULT not firing

2007-08-31 Thread williamkusumo
Okay, I haven't found a solution yet, but after some debugging, turns
out everything boils down to the Content-type that the webservice is
returning. The webservice is returning text/plain result, not XML (I
did my own test, if the service returns text/xml, everything works as
it should). I tried setting HTTPService.RESULT_FORMAT_TEXT to
resultFormat, it still doesn't work. The request is successful (HTTP
status 200), but it won't trigger ResultEvent...

This is frustrating...

--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 Hello!
 
 I am calling a webservice that does something and return HTTP status
 (either success or fail) that's it, no data whatsoever is returned. I
 need to do something when I got the response back but for some reason,
 ResultEvent.RESULT is not firing if there is no data being returned by
 the webservice. Is there another event I can listen to that'll do this?
 
 Appreciate the help! Thanks!





[flexcoders] Re: Problem with HTTPService ResultEvent.RESULT not firing

2007-08-31 Thread williamkusumo
Yes, found it! Somewhere along my ResultEvent callback function, I
have a conversion to XML that is failing. Damn, gotta learn to put try
catch in everything...


--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 Okay, I haven't found a solution yet, but after some debugging, turns
 out everything boils down to the Content-type that the webservice is
 returning. The webservice is returning text/plain result, not XML (I
 did my own test, if the service returns text/xml, everything works as
 it should). I tried setting HTTPService.RESULT_FORMAT_TEXT to
 resultFormat, it still doesn't work. The request is successful (HTTP
 status 200), but it won't trigger ResultEvent...
 
 This is frustrating...
 
 --- In flexcoders@yahoogroups.com, williamkusumo williamkusumo@
 wrote:
 
  Hello!
  
  I am calling a webservice that does something and return HTTP status
  (either success or fail) that's it, no data whatsoever is returned. I
  need to do something when I got the response back but for some reason,
  ResultEvent.RESULT is not firing if there is no data being returned by
  the webservice. Is there another event I can listen to that'll do
this?
  
  Appreciate the help! Thanks!
 





[flexcoders] Re: How to get the previously selected item in ComboBox on change?

2007-08-31 Thread williamkusumo
Hmm, completely bummed with this...I tried calling e.preventDefault();
e.stopImmediatePropagation(); e.stopPropagation(); on click event and
it won't cancel the default actions.

Seems like there's no other way but to extend ComboBox and override
the way it does changeHandler?

Thanks!

--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 Hmm, actually, maybe 'change' is not what I should be listening to. I
 need to intercept the default action when user tries to change the
 selected item and based on user input, allow/disallow the option user
 is trying to select. What event should I listen to then? I was
 thinking of 'close', but that wouldn't work on keyboard action,
would it?
 
 Thanks!
 
 --- In flexcoders@yahoogroups.com, Tracy Spratt tspratt@ wrote:
 
  I think you'll need to store the previously selectedItem in an
instance
  variable.
  
   
  
  That is how I handle it.
  
   
  
  Tracy
  
   
  
  
  
  From: flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] On
  Behalf Of williamkusumo
  Sent: Wednesday, August 29, 2007 4:27 PM
  To: flexcoders@yahoogroups.com
  Subject: [flexcoders] How to get the previously selected item in
  ComboBox on change?
  
   
  
  Hi!
  
  I can't seem to get a reference to the previously selected item in
  ComboBox on change. When the function executes on change, the
  selectedItem has already become the newly selected item, I would like
  to check on the previously selected. I checked on the docs and can't
  seem to find any property that indicates previous item.
  
  As always, thanks for the help!
 





[flexcoders] Problem with HTTPService ResultEvent.RESULT not firing

2007-08-30 Thread williamkusumo
Hello!

I am calling a webservice that does something and return HTTP status
(either success or fail) that's it, no data whatsoever is returned. I
need to do something when I got the response back but for some reason,
ResultEvent.RESULT is not firing if there is no data being returned by
the webservice. Is there another event I can listen to that'll do this?

Appreciate the help! Thanks!



[flexcoders] How to get the previously selected item in ComboBox on change?

2007-08-29 Thread williamkusumo
Hi!

I can't seem to get a reference to the previously selected item in
ComboBox on change. When the function executes on change, the
selectedItem has already become the newly selected item, I would like
to check on the previously selected. I checked on the docs and can't
seem to find any property that indicates previous item.

As always, thanks for the help!



[flexcoders] How to get the previously selected item in ComboBox on change?

2007-08-29 Thread williamkusumo
Hi!

I can't seem to get a reference to the previously selected item in
ComboBox on change. When the function executes on change, the
selectedItem has already become the newly selected item, I would like
to check on the previously selected. I checked on the docs and can't
seem to find any property that indicates previous item.

As always, thanks for the help!



[flexcoders] Re: How to get the previously selected item in ComboBox on change?

2007-08-29 Thread williamkusumo
Hmm, actually, maybe 'change' is not what I should be listening to. I
need to intercept the default action when user tries to change the
selected item and based on user input, allow/disallow the option user
is trying to select. What event should I listen to then? I was
thinking of 'close', but that wouldn't work on keyboard action, would it?

Thanks!

--- In flexcoders@yahoogroups.com, Tracy Spratt [EMAIL PROTECTED] wrote:

 I think you'll need to store the previously selectedItem in an instance
 variable.
 
  
 
 That is how I handle it.
 
  
 
 Tracy
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of williamkusumo
 Sent: Wednesday, August 29, 2007 4:27 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] How to get the previously selected item in
 ComboBox on change?
 
  
 
 Hi!
 
 I can't seem to get a reference to the previously selected item in
 ComboBox on change. When the function executes on change, the
 selectedItem has already become the newly selected item, I would like
 to check on the previously selected. I checked on the docs and can't
 seem to find any property that indicates previous item.
 
 As always, thanks for the help!





[flexcoders] Problem with Flex moving XML namespaces

2007-08-28 Thread williamkusumo
Hi!

I am assembling XML from strings. This XML has a default namespace and
one custom namespace. The namespaces declarations have to be inside
certain node. I notice Flex seems to be moving the namespaces around
and putting them all into the root node. Is it possible to have it not
do that?

Appreciate the thoughts.



[flexcoders] Re: Problem with Flex moving XML namespaces

2007-08-28 Thread williamkusumo
Actually, it only happens with default namespace.

I am trying to achieve this:

Root
  Test xmlns=http://somenamespace;/Test
/Root

I assign that to an XML object, set the default xml namespace, and it
always turns out like this:

Root xmlns=http://somenamespace;
  Test/Test
/Root

--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 Hi!
 
 I am assembling XML from strings. This XML has a default namespace and
 one custom namespace. The namespaces declarations have to be inside
 certain node. I notice Flex seems to be moving the namespaces around
 and putting them all into the root node. Is it possible to have it not
 do that?
 
 Appreciate the thoughts.





[flexcoders] Re: Problem with Flex moving XML namespaces

2007-08-28 Thread williamkusumo
Okay, I think I kinda get it. I should not set default xml namespace,
but I need to use setNamespace() on that specific node. Seems to work
fine now. Sorry for cluttering the board :)

--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 Actually, it only happens with default namespace.
 
 I am trying to achieve this:
 
 Root
   Test xmlns=http://somenamespace;/Test
 /Root
 
 I assign that to an XML object, set the default xml namespace, and it
 always turns out like this:
 
 Root xmlns=http://somenamespace;
   Test/Test
 /Root
 
 --- In flexcoders@yahoogroups.com, williamkusumo williamkusumo@
 wrote:
 
  Hi!
  
  I am assembling XML from strings. This XML has a default namespace and
  one custom namespace. The namespaces declarations have to be inside
  certain node. I notice Flex seems to be moving the namespaces around
  and putting them all into the root node. Is it possible to have it not
  do that?
  
  Appreciate the thoughts.
 





[flexcoders] Re: Problem with ArrayCollection inside an Object

2007-08-27 Thread williamkusumo
It'd be nice if Flex have the ability to pass in a custom argument
when you add an event listener and have that argument be available in
the function handler. Is that possible?

--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 I think this might be a classic programming questions rather than
Flex's.
 
 I have a custom Object with an ArrayCollection as one of its property.
 I added a COLLECTION_CHANGE listener on that ArrayCollection. In its
 handler function, I need a reference to the object that contains the
 ArrayCollection.
 
 Yes, I could've had the object as a global instance so I can access it
 directly in the function, but another caveat to this is there could be
 several of these objects, and looping through them one by one to find
 if they own a particular ArrayCollection might not be a choice.
 
 Is there another way to somehow obtain a reference to the
 ArrayCollection owner's object?
 
 Thanks!





[flexcoders] Problem with ArrayCollection inside an Object

2007-08-27 Thread williamkusumo
I think this might be a classic programming questions rather than Flex's.

I have a custom Object with an ArrayCollection as one of its property.
I added a COLLECTION_CHANGE listener on that ArrayCollection. In its
handler function, I need a reference to the object that contains the
ArrayCollection.

Yes, I could've had the object as a global instance so I can access it
directly in the function, but another caveat to this is there could be
several of these objects, and looping through them one by one to find
if they own a particular ArrayCollection might not be a choice.

Is there another way to somehow obtain a reference to the
ArrayCollection owner's object?

Thanks!



[flexcoders] Problem detecting data change in a List

2007-08-24 Thread williamkusumo
Hi!

I have a List bound to an ArrayCollection. And this List is draggable,
so you can re-arrange the items. You can also remove or add stuff to it.

I would like to do something when the List is modified, but
'dataChange' doesn't seem to work. Anyone has any idea? 'change' is
not what I want since it only detects changes to
selectedItem/selectedIndex.

I've thought about putting an event listener on the ArrayCollection
itself, but the problem is the ArrayCollection can be null under some
circumstances.

Any help appreciated!



[flexcoders] Deleting an Item from a List

2007-06-14 Thread williamkusumo
Hi!

I have a List (populated via a dataProvider) and in each of the list
items, I have a Close button. What is the best way to remove the
item when the Close button is clicked? I understand I must remove
the data from the dataProvider instead of just deleting the list item,
but how do you get the index of the list item based on which button is
clicked?

I have tried using the list's selectedIndex, but that's not really how
you want to do it because the list item won't necessarily be the one
selected when the close button is clicked (it'll screw up if you use
keyboard to navigate to the button)

I have tried getting the list by using thebutton.parent.parent and
then do a getChildIndex(...) passing in thebutton.parent. But all I
got is the number 2 all the time no matter which item I clicked on.

Any help will be greatly appreciated.

Thanks!



[flexcoders] Re: Show incremental numeric index in a List

2007-06-14 Thread williamkusumo
Thanks for the feedback, guys!

I implemented IDropInListItemRenderer and got ahold of listData.owner.
You are right, itemRendererToIndex(...) will get you the correct index.

The trouble now is how do I bind the result of itemRendererToIndex to
a label inside the itemRenderer so that it automatically updates when
the dataProvider is changed?

You mentioned overriding updateDisplayList(), isn't that function
related more to updating the styles?

Thanks again!

--- In flexcoders@yahoogroups.com, Alex Harui [EMAIL PROTECTED] wrote:

 You can implement IDropInListItemRenderer in your HBox if you want.
 
  
 
 You can also assume that owner is the List and call
 itemRendererToIndex in an override of updateDisplayList().
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of williamkusumo
 Sent: Wednesday, June 13, 2007 5:53 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Show incremental numeric index in a List
 
  
 
 A quick note: The itemRenderer is based on HBox. So it does not
 implement IDropInListItemRenderer, thus I don't have reference to
 listData.
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 , williamkusumo williamkusumo@
 wrote:
 
  Hi!
  
  I have a List bounded to a dataProvider and an itemRenderer. Could
  anyone advice me on how I can insert an incremental numeric index in
  each list item (1, 2, 3, and so on)? This list can be re-arranged via
  drag-n-drop, so I can't put the index as part of the data.
  
  Any help will be greatly appreciated.
  
  Thanks!
 





[flexcoders] Re: Show incremental numeric index in a List

2007-06-14 Thread williamkusumo
Actually, if you consider performance, would Tracy's idea be a better
performer? (On dragDrop, we just loop through the dataProvider and
update a property that has the index manually)

Thanks!

--- In flexcoders@yahoogroups.com, williamkusumo [EMAIL PROTECTED]
wrote:

 Thanks for the feedback, guys!
 
 I implemented IDropInListItemRenderer and got ahold of listData.owner.
 You are right, itemRendererToIndex(...) will get you the correct index.
 
 The trouble now is how do I bind the result of itemRendererToIndex to
 a label inside the itemRenderer so that it automatically updates when
 the dataProvider is changed?
 
 You mentioned overriding updateDisplayList(), isn't that function
 related more to updating the styles?
 
 Thanks again!
 
 --- In flexcoders@yahoogroups.com, Alex Harui aharui@ wrote:
 
  You can implement IDropInListItemRenderer in your HBox if you want.
  
   
  
  You can also assume that owner is the List and call
  itemRendererToIndex in an override of updateDisplayList().
  
   
  
  
  
  From: flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] On
  Behalf Of williamkusumo
  Sent: Wednesday, June 13, 2007 5:53 PM
  To: flexcoders@yahoogroups.com
  Subject: [flexcoders] Re: Show incremental numeric index in a List
  
   
  
  A quick note: The itemRenderer is based on HBox. So it does not
  implement IDropInListItemRenderer, thus I don't have reference to
  listData.
  
  --- In flexcoders@yahoogroups.com
mailto:flexcoders%40yahoogroups.com
  , williamkusumo williamkusumo@
  wrote:
  
   Hi!
   
   I have a List bounded to a dataProvider and an itemRenderer. Could
   anyone advice me on how I can insert an incremental numeric index in
   each list item (1, 2, 3, and so on)? This list can be
re-arranged via
   drag-n-drop, so I can't put the index as part of the data.
   
   Any help will be greatly appreciated.
   
   Thanks!
  
 





[flexcoders] How to clone object?

2007-06-14 Thread williamkusumo
How do you clone/make copies of an object? I see some clone()
functions in the docs, but they are all part of some unrelated class
like Events.

Any help is greatly appreciated.

Thanks!



[flexcoders] Re: How to clone object?

2007-06-14 Thread williamkusumo
Thanks,

I saw that, but not sure if it would work with any Object. It seems to
be explaining about cloning arrays.

--- In flexcoders@yahoogroups.com, Bjorn Schultheiss
[EMAIL PROTECTED] wrote:

 There's some info here
 
 http://livedocs.adobe.com/flex/2/docs/wwhelp/wwhimpl/common/html/ 
 wwhelp.htm?context=LiveDocs_Partsfile=1882.html
 
 On 15/06/2007, at 12:04 PM, williamkusumo wrote:
 
  How do you clone/make copies of an object? I see some clone()
  functions in the docs, but they are all part of some unrelated class
  like Events.
 
  Any help is greatly appreciated.
 
  Thanks!
 
 
 





[flexcoders] Re: How to clone object?

2007-06-14 Thread williamkusumo
I tried it. It works for a plain Object with simple properties, but
it's not working for Object that has more Objects in it.

--- In flexcoders@yahoogroups.com, Bjorn Schultheiss
[EMAIL PROTECTED] wrote:

 There's some info here
 
 http://livedocs.adobe.com/flex/2/docs/wwhelp/wwhimpl/common/html/ 
 wwhelp.htm?context=LiveDocs_Partsfile=1882.html
 
 On 15/06/2007, at 12:04 PM, williamkusumo wrote:
 
  How do you clone/make copies of an object? I see some clone()
  functions in the docs, but they are all part of some unrelated class
  like Events.
 
  Any help is greatly appreciated.
 
  Thanks!
 
 
 





[flexcoders] Newbie in need of help with graphics

2007-05-05 Thread williamkusumo
Please forgive this stupid question. I can't seem to figure out how to
draw a simple rectangle in a Flex app...:(

I know it involve the graphics object and I have to call drawRect at
some point. But where do I put this code, and how do I attach this
rectangle into one of the container?

Any help is much appreciated. I can't seem to find any tutorial that
is actually working either.

Thanks!