[flexcoders] Custom mouse cursors including the system cursor?

2009-01-12 Thread Josh McDonald
Hey guys,

I'm wondering how I create a custom mouse cursor that will include the
system cursor, the way DragManager does with the halo mouse cursors?

Any "pointers" (groan) much appreciated!

Cheers,

-Josh

-- 
"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...@gfunk007.com
:: http://flex.joshmcdonald.info/
:: http://twitter.com/sophistifunk


Resending : [flexcoders] Flex MenuBar rolling over HTML Page.

2009-01-12 Thread sachin kothe
Please let me know if anyone has idea on this..

--- On Mon, 1/12/09, sachin kothe  wrote:

From: sachin kothe 
Subject: [flexcoders] Flex MenuBar rolling over HTML Page.
To: flexcoders@yahoogroups.com
Date: Monday, January 12, 2009, 6:18 PM











Hi All,
   I have an use case where any HTML page e.g. google.com is embedded inside 
Flex Application using IFrame and i have a Flex Menu Bar over the IFrame. 
Requirnment is when i select a Flex menu, menu items should roll over the HTML 
Page. 
 Is it Feasible and how we can do that?  
 
I tried as below but Menu Items goes behind IFrame and not visible.
 
 
IFrameDemo.mxml
 - - - - - - 
- - - - -
 

http://www.adobe. com/2006/ mxml" 
xmlns:local= "*" 
creationComplete= "init();" 
viewSourceURL= "srcview/index. html"> 

 
 
 
 

 
 

http://www.adobe. com/devnet/ flex/" 
width="100%" height="100%"/> 
 
 
 
 

 
 
 - - - - - - 
- - - - - -
 
   
-Sachin
 














  

[flexcoders] regular expression tester says it works, but it doesnt????

2009-01-12 Thread flexaustin
pattern = new RegExp('(?<=\"name\":\").*(?=\",\"\w*:)', 'i');
var resultArr:Array = pattern.exec(data);

resultArr ends up equaling null;

But if you check this:  (?<=\"name\":\").*(?=\",\"\w*:) using
http://gskinner.com/RegExr/ it says it works using this data

"error":32,"count":47,"group":true,"connection":39,"warning":3,"name":"Workstations","title":"Workstations","model":"workstation","ticket":1,"type":"TagCategory","id":1

So why is it not working in my code? If anyone has any suggestions I
would appreciate it.  I have been trying to get this to work for 10
hours straight.

TIA



[flexcoders] Timer Solution

2009-01-12 Thread vinod kumar
I am a newbie in flex. can you please send the code

--- On Mon, 12/1/09, Manish Jethani  wrote:
From: Manish Jethani 
Subject: Re: [flexcoders] Timer Solution
To: flexcoders@yahoogroups.com
Date: Monday, 12 January, 2009, 6:51 PM











On Mon, Jan 12, 2009 at 11:09 AM, vinod kumar  wrote:

> I want an urgent help. From metadata information i got the frame rate as 15.

> So between every second i want to display the values 1 to 15 using timer.



You can listen for the enterFrame event and do it there.



Manish


  




 

















  Add more friends to your messenger and enjoy! Go to 
http://messenger.yahoo.com/invite/

RE: [flexcoders] Mouse wheel scrolling past entries in combobox

2009-01-12 Thread Alex Harui
Build a simple test case and if it fails there, file a bug.

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of kaleb_pederson
Sent: Monday, January 12, 2009 3:30 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Mouse wheel scrolling past entries in combobox


I have a ComboBox which displays five entries at a time. When I first
click on the ComboBox, it displays items 1-5, which is as expected.
As soon as I scroll down one click with the mouse wheel, it displays
items 13-17 -- skipping items 6-12.

How can I change the scroll wheel behavior so that it doesn't scroll
past certain items?

I tried adding an event listener for both MouseEvent.MOUSE_WHEEL and
FlexMouseEvent.MOUSE_WHEEL_OUTSIDE, but neither of those triggered
anything. I also tried looking at the source code for the combo box,
but wasn't able to find anything relevant.

Suggestions?

Thanks.

--Kaleb



RE: [flexcoders] the tilelist will be winking when the data is refreshing.

2009-01-12 Thread Alex Harui
You might want to use SuperImage from quietlyscheming.com to cache images on 
the client so they don't get downloaded every time.

You might also need to prevent invalidation of the TileLIst when the progress 
bar is changed.  That can be done by overriding invalidateSize and 
invalidateDisplayList in the renderer.

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Scarlet.H
Sent: Monday, January 12, 2009 5:15 PM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] the tilelist will be winking when the data is 
refreshing.


Alex, Sorry, I don't know how to description the issue in English.

the progressbar that show upload progress will be refreshing when user
select many photos to upload.

All data will be reload again when one data is refreshing Every time , it
will lead the interface flash continually.

Alex Harui wrote:
>
> Not sure what you mean by wink issue, but the renderer could be told to
> stay invisible for a bit longer if that helps
>
> From: flexcoders@yahoogroups.com 
> [mailto:flexcoders@yahoogroups.com] On
> Behalf Of Scarlet.H
> Sent: Sunday, January 11, 2009 8:54 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] the tilelist will be winking when the data is
> refreshing.
>
>
> I have a item component that include label, progressbar and image inside
> VBox.
> the progresss bar of each image in tilelist will be updated in time if the
> user select some photo or videos to upload.
>
> I don't know how to resolve the wink issue when the data be updated.
>
> any suggestion for it?
>
> thanks.
> --
> View this message in context:
> http://www.nabble.com/the-tilelist-will-be-winking-when-the-data-is-refreshing.-tp21408081p21408081.html
> Sent from the FlexCoders mailing list archive at Nabble.com.
>
>
>
http://www.nabble.com/file/p21427310/1.jpg
--
View this message in context: 
http://www.nabble.com/the-tilelist-will-be-winking-when-the-data-is-refreshing-tp21408081p21427310.html
Sent from the FlexCoders mailing list archive at Nabble.com.



RE: [flexcoders] AIR and SQLLite

2009-01-12 Thread Kevin Benz
What are you asking?

 

Are you wanting to synchronize all client sqlite db's from a common
back-end db?

Are you wanting to replicate the client data on the server?

 

Air doesn't provide any facilities to help with either although both
could be accomplished with a non-trivial development effort. I know
there is some discussion on the web of tools to help although you need
to be aware of the fact that Adobe extended SQLite with support for AS
datatypes (like Date for example) so beware of tools that may not be
aware of your whole schema.

 

K

 

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
Behalf Of bonny_us
Sent: Monday, January 12, 2009 7:57 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] AIR and SQLLite

 

Hi All,

Any one have idea of SQLLite and AIR Synchronization. I want to create
one POC using SQLLite. If any one have any example regarding this then
please let me know. it will be very helpful to me.

Thanks,
Bonny

 

<><>

[flexcoders] regex

2009-01-12 Thread flexaustin
Does anyone know how to write a regular expression that says find a
pattern in a String that contains 0 or more letters, numbers, or
spaces, but not a ", (one double quote and a comma).

TIA



RE: [flexcoders] the tilelist will be winking when the data is refreshing.

2009-01-12 Thread Scarlet.H

maybe I found some threads 
in override data function 
I set the image source value with Progressbar value together as is:

thumbCom.img_thumbnail.source = spt;
thumbCom.progress_upload.setProgress(data.current, data.total);

it will be not flash when I remove "thumbCom.img_thumbnail.source = spt;".

it is very weird.


Alex Harui wrote:
> 
> Not sure what you mean by wink issue, but the renderer could be told to
> stay invisible for a bit longer if that helps
> 
> From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
> Behalf Of Scarlet.H
> Sent: Sunday, January 11, 2009 8:54 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] the tilelist will be winking when the data is
> refreshing.
> 
> 
> I have a item component that include label, progressbar and image inside
> VBox.
> the progresss bar of each image in tilelist will be updated in time if the
> user select some photo or videos to upload.
> 
> I don't know how to resolve the wink issue when the data be updated.
> 
> any suggestion for it?
> 
> thanks.
> --
> View this message in context:
> http://www.nabble.com/the-tilelist-will-be-winking-when-the-data-is-refreshing.-tp21408081p21408081.html
> Sent from the FlexCoders mailing list archive at Nabble.com.
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/the-tilelist-will-be-winking-when-the-data-is-refreshing-tp21408081p21429166.html
Sent from the FlexCoders mailing list archive at Nabble.com.


[flexcoders] AIR and SQLLite

2009-01-12 Thread bonny_us
Hi All,

Any one have idea of SQLLite and AIR Synchronization. I want to create
one POC using SQLLite. If any one have any example regarding this then
please let me know. it will be very helpful to me.


Thanks,
Bonny



RE: [flexcoders] the tilelist will be winking when the data is refreshing.

2009-01-12 Thread Scarlet.H

Alex, Sorry, I don't know how to description the issue in English.

the progressbar that show upload progress will be refreshing when user
select many photos to upload.
 
All data will be reload again when one data is refreshing Every time , it
will lead the interface flash continually.


Alex Harui wrote:
> 
> Not sure what you mean by wink issue, but the renderer could be told to
> stay invisible for a bit longer if that helps
> 
> From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
> Behalf Of Scarlet.H
> Sent: Sunday, January 11, 2009 8:54 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] the tilelist will be winking when the data is
> refreshing.
> 
> 
> I have a item component that include label, progressbar and image inside
> VBox.
> the progresss bar of each image in tilelist will be updated in time if the
> user select some photo or videos to upload.
> 
> I don't know how to resolve the wink issue when the data be updated.
> 
> any suggestion for it?
> 
> thanks.
> --
> View this message in context:
> http://www.nabble.com/the-tilelist-will-be-winking-when-the-data-is-refreshing.-tp21408081p21408081.html
> Sent from the FlexCoders mailing list archive at Nabble.com.
> 
> 
> 
http://www.nabble.com/file/p21427310/1.jpg 
-- 
View this message in context: 
http://www.nabble.com/the-tilelist-will-be-winking-when-the-data-is-refreshing-tp21408081p21427310.html
Sent from the FlexCoders mailing list archive at Nabble.com.



Re: [flexcoders] GPS in Flex

2009-01-12 Thread [p e r c e p t i c o n]
Hi Doug,Is it ok if i ask you a blackberry question off list?
thanks
percy

On Thu, Jan 8, 2009 at 4:47 PM, Doug McCune  wrote:

>   Check out Andy Powell's post about using Merapi and GPS:
> http://www.infoaccelerator.net/blog/post.cfm/live-gps-visualizations-with-air-merapi
>
> I have a small app running on my BlackBerry that posts my lat/lon to my own
> webserver, which just stores it in a DB. The using whatever serverside
> technology I want (java, php, etc) I could expose a web service to return my
> coordinates. So you can either communicate directly with the device via
> Merapi, or push data somehow from the device to a webserver and then pull
> the data from the server into your Flex app.
>
> Doug
>
>
> On Thu, Jan 8, 2009 at 4:37 PM, Nate Beck  wrote:
>
>>   In addition to what Tim said.
>>
>> The Merapi project (http://merapiproject.net/), is an excellent candidate
>> for a project like this.  You can use Java to communicate to the GPS unit's
>> device drivers, and then use that data with webservices or the yahoo maps
>> API to serve maps in real time.
>>
>> Just a thought.
>>
>> On Thu, Jan 8, 2009 at 4:14 PM, Tim Rowe wrote:
>>
>>>If you want to do it in realtime you're going to first have to decide
>>> what devices you support.  There might be some standards for communication,
>>> but others go off and do their own thing and those might be the ones you
>>> want to support.  Garmin often take a lot of heat for this (despite what
>>> they're pushing with ANT+ standards).
>>>
>>> Do you have a particular device in mind to start out, and have you done
>>> any research on what dev tools they have available?  Obviously at some point
>>> you're going to want to abstract things out, but you need to at least have a
>>> rough idea whether your design is even going to work for real-world existing
>>> designs and products.
>>>
>>> --Tim
>>>
>>>  --
>>> *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On
>>> Behalf Of *Ben Cessa
>>> *Sent:* Friday, 9 January 2009 11:10 AM
>>> *To:* flexcoders@yahoogroups.com
>>> *Subject:* [flexcoders] GPS in Flex
>>>
>>>  Hi, I'm planning to build an AIR application but I have a major doubt
>>> here, by looking at the amazing work of Doug McCune I think is
>>> possible to integrate real time GPS data into a Map on a Flex
>>> application, but my question is: how? Just in case the above is not a
>>> completely clear explanation let me put it with other words:
>>>
>>> I wanna know how ( considering first if this is even possible right
>>> now ) to get data from a GPS device and load it, real time ( well,
>>> pretty much real time ) inside a map on a Flex and/or AIR application.
>>>
>>> I really hope someone with far more experience than myself can point
>>> in the right direction on this one, thanx in advance for your
>>> attention, and have all a great new year :)
>>>
>>>
>>
>>
>> --
>>
>> Cheers,
>> Nate
>> 
>> http://blog.natebeck.net
>>
>>
>>
>  
>


Re: [flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread Nate Beck
Hey... now that's cool, I didn't realize scale also affects text size.



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

 






 



Thanks Alex.

On Mon, Jan 12, 2009 at 3:02 PM, Alex Harui  wrote:

>xscale = yscale = someScaleFactorGreaterThanOne?
>
>
>
> *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On
> Behalf Of *Nate Beck
> *Sent:* Monday, January 12, 2009 2:15 PM
> *To:* flexcoders@yahoogroups.com
> *Subject:* Re: [flexcoders] Re: Expanding size of panel, and its contained
> objects.
>
>
>
> What Wesley is saying seems like a good starting point.
>
>
>
> I haven't heard of this type of behavior before.  But a uniform scaling of
> all components and all of their text at the same time will be a challenge...
>
>
>
> sidenote:
>
> I'm on a mac, so if I can't read something, I just use the Command+Option+8
> shortcut to enable accessibility, and then Command+Option+= to zoom in.
>
>
>
>
>
> On Mon, Jan 12, 2009 at 2:10 PM, Wesley Acheson 
> wrote:
>
> For all the children try using percentage widths and heights, I don't
> really know about the font of things.   Maybe you could increase the font
> size by giving everything a font size attached to a variable.  Or try using
> CSS to benefit from Cascading rules?
>
> Regards,
>
> Wesley Acheson
>
> On Mon, Jan 12, 2009 at 11:07 PM, aceoohay  wrote:
>
>  Tim:
>
> I am not sure I understand?
>
> What I need is the ability to expand a panel, and all of its
> contained objects such as textinputs, labels, comboboxes and the
> like.
>
> Paul
>
> --- In flexcoders@yahoogroups.com, Tim Rowe  wrote:
> >
> > It won't run in 40 column mode?
> >
> > I feel evil suggesting this when 1280x1024 is the norm these days.
> >
> > --Tim
> >
> > 
> > From: flexcoders@yahoogroups.com
> [mailto:flexcod...@yahoogroups.com] On Behalf Of aceoohay
> > Sent: Tuesday, 13 January 2009 8:59 AM
> > To: flexcoders@yahoogroups.com
> > Subject: [flexcoders] Re: Expanding size of panel, and its
> contained objects.
> >
> >
> > Actually, I have.
> >
> > Unfortunately the system they are coming from is a unix character
> > based system where an 80 character by 24 line screen takes up their
> > entire monitor. A number of the users are complaining that they
> > can't read the default font sizes, and while I told them that's all
> > I can do, I was hoping to find an easy solution.
> >
> > Paul
> >
> > --- In flexcoders@yahoogroups.com 40yahoogroups.com>, "Nate Beck"  wrote:
> > >
> > > After thinking about it for a minute... now I'm understanding
> what
> > you're
> > > saying. You want to actually ZOOM in, make them larger.
> > > Have you tried taking the easy way out and telling the people to
> > change
> > > their monitor resolution? :D
> > >
> > > On Mon, Jan 12, 2009 at 1:47 PM, Nate Beck  wrote:
> > >
> > > > ... If you're using constraint based layout... how is there a
> > problem? A
> > > > component taking 100% of the width of it's container will
> always
> > scale to
> > > > fit that container.
> > > >
> > > >
> > > > On Mon, Jan 12, 2009 at 1:27 PM, aceoohay  wrote:
> > > >
> > > >> While that example does allow you to maximize a panel, it
> > does not
> > > >> expand the contained objects.
> > > >>
> > > >> If it did what I need the buttons  and  > video
> > > >> enable> would become much larger than they were originally
> when
> > the
> > > >> maximize button was clicked.
> > > >>
> > > >> I should have mentioned that I have done searching, and can
> > find the
> > > >> expanding panel in many places, but nowhere can I find code
> that
> > > >> will force the objects in a container to increse in size by
> n%.
> > > >>
> > > >> Paul
> > > >>
> > > >>
> > > >> --- In flexcoders@yahoogroups.com 40yahoogroups.com>  > 40yahoogroups.com>, "Nate
> > > >> Beck"  wrote:
> > > >> >
> > > >> > Doing a quick google search for, "flex maximize, minimize
> > panel"
> > > >> > Returns loads of examples of what you're trying to do I
> > think...
> > > >> >
> > > >> >
> http://www.comtaste.com/DashboardExample/DashboardExample.html
> > > >> >
> > > >> > and
> > > >> >
> > > >> >
> > > >>
> >
> http://blog.comtaste.com/2008/12/how_to_use_the_flex_dashboard_1.html
> > > >> >
> > > >> > Right?
> > > >> >
> > > >> > On Mon, Jan 12, 2009 at 11:17 AM, aceoohay  wrote:
> > > >> >
> > > >> > > Hello?
> > > >> > >
> > > >> > > Is anyone out there?
> > > >> > >
> > > >> > > Any ideas?
> > > >> > >
> > > >> > > Paul
> > > >> > >
> > > >> > >
> > > >> > > --- In flexcoders@yahoogroups.com 40yahoogroups.com>  > 40yahoogroups.com> > > >> 40yahoogroups.com>,
> > > >> > > "aceoohay"  wrote:
> > > >> > > >
> > > >> > > > The systems that I write are traditional data entry
> types
> > of
> > > >> > > systems.
> > > >> > > > I do everything within panels within modules. I have had
> > users
> > > >> ask
> > > >> > > if
> > > >> > > > they could expand the size of the panel in order to read

[flexcoders] Mouse wheel scrolling past entries in combobox

2009-01-12 Thread kaleb_pederson
I have a ComboBox which displays five entries at a time.  When I first
click on the ComboBox, it displays items 1-5, which is as expected. 
As soon as I scroll down one click with the mouse wheel, it displays
items 13-17 -- skipping items 6-12.

How can I change the scroll wheel behavior so that it doesn't scroll
past certain items?

I tried adding an event listener for both MouseEvent.MOUSE_WHEEL and
FlexMouseEvent.MOUSE_WHEEL_OUTSIDE, but neither of those triggered
anything.  I also tried looking at the source code for the combo box,
but wasn't able to find anything relevant.

Suggestions?

Thanks.

--Kaleb





[flexcoders] Re: Instantiating a class from a dynamically loaded swf

2009-01-12 Thread dustyjewett
For Posterity, the solution is to call the 'getDefinition()' function
on the loader's ApplicationDomain...

swfLoader.loaderContext.applicationDomain.getDefinition('className');

No need to implement your own function, it's already there :-D



--- In flexcoders@yahoogroups.com, Alex Harui  wrote:
>
> This is an ApplicationDomain issue.  Read the docs, check out the
presentations on my blog.  One way to solve would be to  expose your
own getDefinition call on the content so you make the call in its context
> 
> From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com]
On Behalf Of dustyjewett
> Sent: Thursday, January 08, 2009 3:03 PM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Instantiating a class from a dynamically
loaded swf
> 
> 
> I'd like to be able to load a swf that has many movieclip assets in
it, then instantiate those assets (icons) throughout the application.
> 
> What I'm doing now is:
> 
> private function handleSwfLoaded(e:Event):void{
> for each(var mc:MovieClip in e.currentTarget.content){
> var ui:UIComponent = new UIComponent();
> ui.addChild(mc);
> ui.height = mc.height;
> mc.y = 0;
> mc.x = 0;
> this.addChild(ui);
> }
>  &nb! sp;  }
> 
> This code will get all of the child items of a loaded swf (those
items on the canvas that were named) and add them to the current app.
> 
> What I want to do is to instantiate new objects, so something more
similar to:
> 
> private function handleSwfLoaded(e:Event):void{
> for each(var mc:MovieClip in e.currentTarget.content){
> var clipClass:Class =
getDefinitionByName(getQualifiedName(mc));
> var newClip:MovieClip = new clipClass();
> var ui:UIComponent = new UIComponent();
> ui.addChild(newClip);
> ui.height = newClip.height;
> newClip.y = 0;
> newClip.x = 0;
> this.addChild(ui);
> }
>  &nbs! p;   ;}
> 
> Unfortunately, this throws the error:
> ReferenceError: Error #1065: Variable icon_regactions_print is not
defined.
> at global/flash.utils::getDefinitionByName()
> 
> Which is particularly interesting, as I'm feeding it
'getQualifiedClassName()'.
> 
> One suggestion floating around is that I should just serialize the
object with ByteArray then deserialize it into another object. I'm
hoping that there is something I'm just missing.
> 
> (And yes, for the record, I am exporting all classes on first frame
and exporting for runtime sharing)
>




RE: [flexcoders] Multiple selection in dataGrid by dragging Mouse with left mouse key

2009-01-12 Thread Alex Harui
Should be doable, but I don't know of any examples

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Dharmendra Chauhan
Sent: Saturday, January 10, 2009 10:25 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Multiple selection in dataGrid by dragging Mouse with 
left mouse key


Is it possible to select multiple rows in data grid by just
dragging mouse over It. I know this can we achieved with combination
of sift key and mouse.
This need has arisen because we are migrating .DOT Net data grid
with flex data grid and user want to have same ease of multiple
selection.

Initially I was confused with dragMultipleSelection propery of
datagird but later I realized that it is for dragging rows and not for
selection.

Please let me know whether it is possible in flex or not and if it
is possible then please provide me some pointers.



RE: [flexcoders] get rowIndex in datagird's mouseOver Function

2009-01-12 Thread Alex Harui
mouseEventToItemRenderer

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Dharmendra Chauhan
Sent: Saturday, January 10, 2009 10:34 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] get rowIndex in datagird's mouseOver Function


My requiremnt is to get rowIndex in mouseover Function in DataGird so
that I can use that index to select perticuler row of
datagrid.ItemRollover Function does not get called when I hold left
mouse key and drag it over dg.
I want to provide functionality where in user can select multiple
rows in dg by holding left mouse key and dragging over the dg.

I have also designed a sample app for this but Only issue with
approach is that It(mOver.target.listData.rowIndex) does not
consistently return rowIndex ,sometimes It throws error `Property
listData not found on mx.controls.listClasses.ListBaseContentHolder
and there is no default value" as a result of it ,few row left
unselected.

This error occurs only when user tries to select rows with fast
mouse movement.

Here is my sample app code :-



http://www.adobe.com/2006/mxml";
layout="absolute" creationComplete="init()"

backgroundColor="#b3b4ae" >









DataGrid {

backgroundColor:#b3b4ae;

borderColor:#66696B;

verticalGridLineColor :#808080;

horizontalGridLineColor :#808080;

themeColor:#0A246A;

borderStyle:solid;

fontSize: 8;

headerStyleName: "dgHeaderStyles";

}

.dgHeaderStyles {

fontSize: 10;

textAlign: left;

backgroundColor: #d4d0c8;

fontFamily :san Sarif;

}























RE: [flexcoders] the tilelist will be winking when the data is refreshing.

2009-01-12 Thread Alex Harui
Not sure what you mean by wink issue, but the renderer could be told to stay 
invisible for a bit longer if that helps

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Scarlet.H
Sent: Sunday, January 11, 2009 8:54 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] the tilelist will be winking when the data is refreshing.


I have a item component that include label, progressbar and image inside
VBox.
the progresss bar of each image in tilelist will be updated in time if the
user select some photo or videos to upload.

I don't know how to resolve the wink issue when the data be updated.

any suggestion for it?

thanks.
--
View this message in context: 
http://www.nabble.com/the-tilelist-will-be-winking-when-the-data-is-refreshing.-tp21408081p21408081.html
Sent from the FlexCoders mailing list archive at Nabble.com.



RE: [flexcoders] Anti-aliasing of device fonts in Flash player 10

2009-01-12 Thread Alex Harui
Hmm. I thought it always anti-aliased, even in FP9.  It might be better in FP10 
with the new text engine.  Flex doesn't support that right now.  You could grab 
a Gumbo build and see if it is any different.

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Sreejith P
Sent: Monday, January 12, 2009 12:51 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Anti-aliasing of device fonts in Flash player 10


Hi Guys,

I am now working with Localization and Internationalization of our
application.Currently we are embedding the fonts with the application
which provide us the ability of anti-aliasing of fonts.

Since embedding the fonts is not a practical solution while doing L10n
and I18n, we lost the ability on anti aliasing the fonts.

But when i saw Justin Everett-Church article about Flash Player 10,he
mentioned about the ability to anti alias the device/system font as
one of the prime features in Flash Player 10.Here is the article
http://www.adobe.com/devnet/logged_in/jchurch_flashplayer10.html

I failed to find any way to do that with flash player 10.Could you
guys please help me how to anti-alias Device/System font using flex 3
and flash player 10.

--
Thanks and Regards,

Sreejith P



[flexcoders] Re: Generating random colors, excluding others

2009-01-12 Thread gr33neye501
Thankyou Sunil for replying to my question. your example uses flash
player 10, i can not view the example or the code for it. 

as it breaks my Flex builder, (still using Flex 3.0) 

I'm at a delicate stage of my project and can't afford Flex builder
breaking and having to reinstall it all!

Do you happen to have the code snipit, which i can see without using
FlashPlayer 10.

I expect to go to 10 in a month or so. But am trying to solve this
issue now. Your help is greatly appriciated.

Once again thank you for responding.
:-)



--- In flexcoders@yahoogroups.com, "sunild99"  wrote:
>
> --- In flexcoders@yahoogroups.com, "gr33neye501"  wrote:
> >
> > Hi guys
> > 
> > I'm trying to generate a series of random colours, but would like to
> > exclude certain colour and closely related shade. 
> > 
> > For example, i'd like create any colours except red or similar shades.
> > Anyone know of how I could do this. It's a really subjective thing I
> > know.  
> > 
> > Help really appreciated
> > ;-)
> >
> 
> Hi,
> 
> I had to do something similar recently. I used HSB color values to
generate distinct colors, 
> and then converted them to RGB.
> 
> I saw you message this morning, and whipped up an example of my
ColorManager class 
> using Degrafa:
>
http://blog.sunild.com/2009/01/generating-many-different-colors-with.html
> 
> To exclude colors, you can modify the code that generates colors to
omit the hues you 
> don't want.
> 
> HTH,
> Sunil
> 
> PS: sorry if this is a repost (Yahoo's beta Rich-Text Editor broke
on me)
>




RE: [flexcoders] DataGrid selectAll problem

2009-01-12 Thread Alex Harui
How small a test case can you build?  I think it is time to see how you're 
trying to wire this up.

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Glenn Jones
Sent: Monday, January 12, 2009 9:21 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] DataGrid selectAll problem


I've tried setting just selectedIndices - same result

In my CheckBoxDataGrid.selectAll() method, I tried calling 
invalidateProperties/invalidateList/validateNow - same result.

In my CheckBoxHeaderRenderer.clickHandler, I tried using callLater to execute 
CheckBoxDataGrid.selectAll() - same result.

I repeated the callLater test after removing 
invalidateProperties/invalidateList/validateNow - same result.

Any suggestions on which operations I should use for callLater()?

As a workaround, I added an event listener for itemEditBeginning on the 
checkboxdatagrid. If the selected item count was > 1,
then I called event.preventDefault().  This actually triggers a crash sometime 
later in mx:DataGrid (line 3889 - itemEditorInstance is null).


On Mon, Jan 12, 2009 at 10:07 AM, Alex Harui 
mailto:aha...@adobe.com>> wrote:

I would not set  both selectedItems and selectedIndices.  Probably just 
selectedIndices because it should be faster.



I don't think selectItem will be called if the item is already selected.  Due 
to the way invalidation works, maybe it hasn't been de-selected yet.  
Sometimes, callLater can help in these situations.



From: flexcoders@yahoogroups.com 
[mailto:flexcoders@yahoogroups.com] On 
Behalf Of Glenn Jones
Sent: Saturday, January 10, 2009 4:52 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] DataGrid selectAll problem



I started with the example from your blog dated Feb 2008 
(CheckBoxListAndDataGrid).

To deselect the other rows, the checkbox column header renderer calls a 
'selectAll()' method on the CheckBoxDataGrid
with  a flag of false.  That method builds two arrays - one for all items in 
the collection and one for all indices in the collection.
It then replaces mx:DataGrid.selectedItems and selectedIndices with new arrays. 
In the deselect case, the new arrays are empty.
In the select all case then have all items/indices.

Visually, selectAll true/false seems to work when it's called. But in the 
use-case I describe below I'm counting on the
mx:DataGrid.selectItem() to be called in order to deselect rows in the case 
that a single row is selected.
Based on trace statements, I know that mx:DataGrid.selectItem() is never called 
when the problem occurs

Is there something about the way I'm selecting things which causes the 
selectItem() to not be called?

I tried replacing just selectedItemds or just selectedIndicies or both. it 
doesn't seem.

Thanks,
Glenn

On Fri, Jan 9, 2009 at 1:11 AM, Alex Harui 
mailto:aha...@adobe.com>> wrote:

Which example did you start with?  Which event do you use to deselect the other 
rows, and what does that code look like?



From: flexcoders@yahoogroups.com 
[mailto:flexcoders@yahoogroups.com] On 
Behalf Of Glenn Jones
Sent: Thursday, January 08, 2009 9:49 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] DataGrid selectAll problem



Hi,

I'm using Flex 3.2 and I have a DataGrid which implements a column of 
checkboxes to select rows.  I started with Alex' example.
Then I added a header renderer on the checkbox column such that if check the 
header, then all rows are selected.
To implement the select all behavior, I'm creating an array of indices for 
[0..n] and assigning that array to mx:DataGrid.selectedIndices.

For the most part this works fine.

But if the DataGrid is editable, then I sometimes have a problem. The problem 
is that if all rows are selected, and you click on
an editable cell, sometimes the cell becomes editable without deselecting all 
of the other rows. The behavior I want is that
if you start editing a cell, then just that row becomes selected. This happens 
some of time, but not all of the time.

If the grid is non-editable, then I can't reproduce the problem.

I overrode mx:DataGrid.selectItem() in order to clear the checkbox in the 
header renderer any time a single item is selected.  I've
noticed that when the problem behavior occurs, the mx:DataGrid.selectItem() 
method is never called.

It's almost like there's some race condition between selecting an item and 
starting a cell edit.

Any ideas on how I could work around this?

Thanks,
Glenn






Re: [flexcoders] Stupid Question - Flex width and height

2009-01-12 Thread Wally Kolcz
Thanks, didn't know that!


From: "Wesley Acheson" 
Sent: Monday, January 12, 2009 2:08 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Stupid Question - Flex width and height 

On Mon, Jan 12, 2009 at 9:48 PM, Wally Kolcz  wrote:
This is probably a dumb question but...

I am trying to do a Flex app primarily in AS. In the constuctor I am trying to 
create an ApplicationControlBar that is the same as this:


I am having a problem with trying to create the same effect as right="5" and 
left="5". I assume that I need to put the x="5" (hence the left="5") and then 
do the math to find out the 'stage' size and subtract the other side (5) for 
the width. However what do I use to do the math?

I tried Application.application.stage.width, but I keeping getting a null value 
error. How can I detect the size of the swf at 100%x100% and do the math or is 
there an easier way to do this. Didn't see a mainACB.right.

Here is what I do have:

var mainACB:ApplicationControlBar = new ApplicationControlBar();
mainACB.x = 5;
mainACB.y = 65;
 mainACB.height = 30;
mainACB.width = Application.application.stage.width - 5;  

Application.application.addChild(mainACB); 

Em can you not just add mainABC.setStyle("right","5") or am I missing 
something? I think that this is what you want?

Regards,
Wesley 





RE: [flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread Alex Harui
xscale = yscale = someScaleFactorGreaterThanOne?

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Nate Beck
Sent: Monday, January 12, 2009 2:15 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Re: Expanding size of panel, and its contained 
objects.

What Wesley is saying seems like a good starting point.

I haven't heard of this type of behavior before.  But a uniform scaling of all 
components and all of their text at the same time will be a challenge...

sidenote:
I'm on a mac, so if I can't read something, I just use the Command+Option+8 
shortcut to enable accessibility, and then Command+Option+= to zoom in.


On Mon, Jan 12, 2009 at 2:10 PM, Wesley Acheson 
mailto:wesley.ache...@gmail.com>> wrote:

For all the children try using percentage widths and heights, I don't really 
know about the font of things.   Maybe you could increase the font size by 
giving everything a font size attached to a variable.  Or try using CSS to 
benefit from Cascading rules?

Regards,

Wesley Acheson
On Mon, Jan 12, 2009 at 11:07 PM, aceoohay 
mailto:pa...@compuace.com>> wrote:
Tim:

I am not sure I understand?

What I need is the ability to expand a panel, and all of its
contained objects such as textinputs, labels, comboboxes and the
like.

Paul

--- In flexcoders@yahoogroups.com, Tim Rowe 
 wrote:
>
> It won't run in 40 column mode?
>
> I feel evil suggesting this when 1280x1024 is the norm these days.
>
> --Tim
>
> 
> From: flexcoders@yahoogroups.com
[mailto:flexcoders@yahoogroups.com] On 
Behalf Of aceoohay
> Sent: Tuesday, 13 January 2009 8:59 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Expanding size of panel, and its
contained objects.
>
>
> Actually, I have.
>
> Unfortunately the system they are coming from is a unix character
> based system where an 80 character by 24 line screen takes up their
> entire monitor. A number of the users are complaining that they
> can't read the default font sizes, and while I told them that's all
> I can do, I was hoping to find an easy solution.
>
> Paul
>
> --- In 
> flexcoders@yahoogroups.com
40yahoogroups.com>, "Nate Beck"  wrote:
> >
> > After thinking about it for a minute... now I'm understanding
what
> you're
> > saying. You want to actually ZOOM in, make them larger.
> > Have you tried taking the easy way out and telling the people to
> change
> > their monitor resolution? :D
> >
> > On Mon, Jan 12, 2009 at 1:47 PM, Nate Beck  wrote:
> >
> > > ... If you're using constraint based layout... how is there a
> problem? A
> > > component taking 100% of the width of it's container will
always
> scale to
> > > fit that container.
> > >
> > >
> > > On Mon, Jan 12, 2009 at 1:27 PM, aceoohay  wrote:
> > >
> > >> While that example does allow you to maximize a panel, it
> does not
> > >> expand the contained objects.
> > >>
> > >> If it did what I need the buttons  and  video
> > >> enable> would become much larger than they were originally
when
> the
> > >> maximize button was clicked.
> > >>
> > >> I should have mentioned that I have done searching, and can
> find the
> > >> expanding panel in many places, but nowhere can I find code
that
> > >> will force the objects in a container to increse in size by
n%.
> > >>
> > >> Paul
> > >>
> > >>
> > >> --- In 
> > >> flexcoders@yahoogroups.com
40yahoogroups.com>  40yahoogroups.com>, "Nate
> > >> Beck"  wrote:
> > >> >
> > >> > Doing a quick google search for, "flex maximize, minimize
> panel"
> > >> > Returns loads of examples of what you're trying to do I
> think...
> > >> >
> > >> >
http://www.comtaste.com/DashboardExample/DashboardExample.html
> > >> >
> > >> > and
> > >> >
> > >> >
> > >>
>
http://blog.comtaste.com/2008/12/how_to_use_the_flex_dashboard_1.html
> > >> >
> > >> > Right?
> > >> >
> > >> > On Mon, Jan 12, 2009 at 11:17 AM, aceoohay  wrote:
> > >> >
> > >> > > Hello?
> > >> > >
> > >> > > Is anyone out there?
> > >> > >
> > >> > > Any ideas?
> > >> > >
> > >> > > Paul
> > >> > >
> > >> > >
> > >> > > --- In 
> > >> > > flexcoders@yahoogroups.com
40yahoogroups.com>  40yahoogroups.com> > >> 40yahoogroups.com>,
> > >> > > "aceoohay"  wrote:
> > >> > > >
> > >> > > > The systems that I write are traditional data entry
types
> of
> > >> > > systems.
> > >> > > > I do everything within panels within modules. I have had
> users
> > >> ask
> > >> > > if
> > >> > > > they could expand the size of the panel in order to r

RE: [flexcoders] Re: Styling Alert box default button

2009-01-12 Thread Alex Harui
And note that the default button has emphasized=true

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of valdhor
Sent: Monday, January 12, 2009 7:39 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Styling Alert box default button


Checkout graphical skinning. A couple of places to start:

http://livedocs.adobe.com/flex/3/html/help.html?content=skinning_4.html
http://userflex.wordpress.com/2008/03/13/button-image-skinning/

--- In flexcoders@yahoogroups.com, 
"achegedus"  wrote:
>
> I have a custom styled alert box with two buttons (ok and cancel), I'm
> trying to make the default button look slightly different, but I can't
> figure out how to do this. Does anyone know? The default style can
> achieve this.
>



[flexcoders] Re: How to register a dynamicEvent in an Actionscript class

2009-01-12 Thread flexcoder2008
In case this helps anyone else - I got this to work.

Had to reference the moduleLoader through the application - so when I
dispatch the dynamicEvent from inside the CairgormCommand's execute
method it looks like this:

initCompleteEvent = new DynamicEvent("initCompleted",true);
Application.application.myModuleLoader.child.dispatchEvent(initCompleteEvent);

--- In flexcoders@yahoogroups.com, "flexcoder2008"  wrote:
>
> Well, I want to dispatch the dynamicEvent from the actionscript class
> (which is a Cairngorm command) and I want my module to listen for that
> event.  
> 
> Since the module event handler code is not being hit, I thought I
> might need to register this event with the compiler (perhaps my
> terminology is wrong - sorry).  I know that when using a component,
> you use the [Event] metadata tag to announce that the component
> dispatches a particular event.  I thought that I might have to do the
> same thing with an actionscript class.  
> 
> 
> 
> --- In flexcoders@yahoogroups.com, "kylewburke"  wrote:
> >
> > What do you mean by "register"?  Do you want to listen for that event
> > or dispatch one?
> > 
> > --- In flexcoders@yahoogroups.com, "flexcoder2008" 
wrote:
> > >
> > > I have seen numerous examples of registering a dynamicEvent in a
> > > component's mxml such as:
> > > 
> > > [Event (name="rowSelected", type="mx.events.DynamicEvent")]
> > > 
> > > If I have an actionscript class that dispatches a dynamicEvent, what
> > > is the syntax for this?
> > > 
> > > I want to dispatch a dynamicEvent from an actionscript class, and I
> > > want my module to listen for that event.
> > >
> >
>




Re: [flexcoders] How to create universal event handler?

2009-01-12 Thread Paul Andrews
- Original Message - 
From: "Dan" 
To: 
Sent: Monday, January 12, 2009 6:24 PM
Subject: [flexcoders] How to create universal event handler?


>I have class MyEvent extends flash.events.Event.
> I also have a second class MyEventChild extends MyEvent.
> Both classes define string constants that are used as event type.
>
> How can I add event listener to handle any of MyEvent or MyChildEvent
> events?
>
> If I do addEventListener(MyEvent.Evt1, handleEvt), I will handle only
> that specific  MyEvent.Evt1 event. I need to be able to handle
> MyEvent.Evt2 and MyChildEvent.Evt1 and my FutureChildEvent.EvtX.
> How can this be achieved?

Is this really a good route to go down?

Your universal event handler will turn into a big switch statement and will 
be responsible for handling  whatever is thrown at it.

The difference between having separate events (most likely custom events) is 
that the handler method is invoked in the correct context for the event and 
that handler method only needs access to data structures that need to be 
changed for that specific event. The event and handler only change in 
response to changing circumstances regarding that specific event (in the 
future it may need to carry some extra or different data).

If you have a universal event handler, the handler function has to have 
access to all the data structures to be manipulated in response for all the 
'subevents'. The universal handler must be changed every time an event is 
added, or changed.

It seems as though the universal handler scheme just avoids the creation of 
individual events and handlers in favour of putting that same effort in one 
basket rather than have the flexibility of separate true events. Effectively 
you are building a controller mechanism  inside of a single event handler.

Paul

>
> Thank you! 



Re: [flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread Nate Beck
What Wesley is saying seems like a good starting point.

I haven't heard of this type of behavior before.  But a uniform scaling of
all components and all of their text at the same time will be a challenge...
sidenote:
I'm on a mac, so if I can't read something, I just use the Command+Option+8
shortcut to enable accessibility, and then Command+Option+= to zoom in.



On Mon, Jan 12, 2009 at 2:10 PM, Wesley Acheson wrote:

>   For all the children try using percentage widths and heights, I don't
> really know about the font of things.   Maybe you could increase the font
> size by giving everything a font size attached to a variable.  Or try using
> CSS to benefit from Cascading rules?
>
> Regards,
>
> Wesley Acheson
>
> On Mon, Jan 12, 2009 at 11:07 PM, aceoohay  wrote:
>
>> Tim:
>>
>> I am not sure I understand?
>>
>> What I need is the ability to expand a panel, and all of its
>> contained objects such as textinputs, labels, comboboxes and the
>> like.
>>
>> Paul
>>
>> --- In flexcoders@yahoogroups.com, Tim Rowe  wrote:
>> >
>> > It won't run in 40 column mode?
>> >
>> > I feel evil suggesting this when 1280x1024 is the norm these days.
>> >
>> > --Tim
>> >
>> > 
>> > From: flexcoders@yahoogroups.com
>> [mailto:flexcod...@yahoogroups.com] On Behalf Of aceoohay
>> > Sent: Tuesday, 13 January 2009 8:59 AM
>> > To: flexcoders@yahoogroups.com
>> > Subject: [flexcoders] Re: Expanding size of panel, and its
>> contained objects.
>> >
>> >
>> > Actually, I have.
>> >
>> > Unfortunately the system they are coming from is a unix character
>> > based system where an 80 character by 24 line screen takes up their
>> > entire monitor. A number of the users are complaining that they
>> > can't read the default font sizes, and while I told them that's all
>> > I can do, I was hoping to find an easy solution.
>> >
>> > Paul
>> >
>> > --- In flexcoders@yahoogroups.com> 40yahoogroups.com>, "Nate Beck"  wrote:
>> > >
>> > > After thinking about it for a minute... now I'm understanding
>> what
>> > you're
>> > > saying. You want to actually ZOOM in, make them larger.
>> > > Have you tried taking the easy way out and telling the people to
>> > change
>> > > their monitor resolution? :D
>> > >
>> > > On Mon, Jan 12, 2009 at 1:47 PM, Nate Beck  wrote:
>> > >
>> > > > ... If you're using constraint based layout... how is there a
>> > problem? A
>> > > > component taking 100% of the width of it's container will
>> always
>> > scale to
>> > > > fit that container.
>> > > >
>> > > >
>> > > > On Mon, Jan 12, 2009 at 1:27 PM, aceoohay  wrote:
>> > > >
>> > > >> While that example does allow you to maximize a panel, it
>> > does not
>> > > >> expand the contained objects.
>> > > >>
>> > > >> If it did what I need the buttons  and > > video
>> > > >> enable> would become much larger than they were originally
>> when
>> > the
>> > > >> maximize button was clicked.
>> > > >>
>> > > >> I should have mentioned that I have done searching, and can
>> > find the
>> > > >> expanding panel in many places, but nowhere can I find code
>> that
>> > > >> will force the objects in a container to increse in size by
>> n%.
>> > > >>
>> > > >> Paul
>> > > >>
>> > > >>
>> > > >> --- In flexcoders@yahoogroups.com> 40yahoogroups.com> > > 40yahoogroups.com>, "Nate
>> > > >> Beck"  wrote:
>> > > >> >
>> > > >> > Doing a quick google search for, "flex maximize, minimize
>> > panel"
>> > > >> > Returns loads of examples of what you're trying to do I
>> > think...
>> > > >> >
>> > > >> >
>> http://www.comtaste.com/DashboardExample/DashboardExample.html
>> > > >> >
>> > > >> > and
>> > > >> >
>> > > >> >
>> > > >>
>> >
>> http://blog.comtaste.com/2008/12/how_to_use_the_flex_dashboard_1.html
>> > > >> >
>> > > >> > Right?
>> > > >> >
>> > > >> > On Mon, Jan 12, 2009 at 11:17 AM, aceoohay  wrote:
>> > > >> >
>> > > >> > > Hello?
>> > > >> > >
>> > > >> > > Is anyone out there?
>> > > >> > >
>> > > >> > > Any ideas?
>> > > >> > >
>> > > >> > > Paul
>> > > >> > >
>> > > >> > >
>> > > >> > > --- In 
>> > > >> > > flexcoders@yahoogroups.com> 40yahoogroups.com> > > 40yahoogroups.com>> > > >> 40yahoogroups.com>,
>> > > >> > > "aceoohay"  wrote:
>> > > >> > > >
>> > > >> > > > The systems that I write are traditional data entry
>> types
>> > of
>> > > >> > > systems.
>> > > >> > > > I do everything within panels within modules. I have had
>> > users
>> > > >> ask
>> > > >> > > if
>> > > >> > > > they could expand the size of the panel in order to read
>> > them
>> > > >> better
>> > > >> > > > due to poor eyesight, high res monitors and the like.
>> > > >> > > >
>> > > >> > > > Are there any existing panel like components that allow
>> > > >> expanding,
>> > > >> > > > while making the contained objects larger?
>> > > >> > > >
>> > > >> > > > Contained objects generally include label, textinput,
>> > textarea,
>> > > >> > > > combobox, etc... Font sizes would need to be incre

RE: [flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread Tim Rowe
Sorry, it sounds like I've misunderstood what you were saying - I thought they 
were saying the 80 column display they already had wasn't large enough and that 
was the reason for your re-write.  Nevermind :)


From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of aceoohay
Sent: Tuesday, 13 January 2009 9:08 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Expanding size of panel, and its contained objects.


Tim:

I am not sure I understand?

What I need is the ability to expand a panel, and all of its
contained objects such as textinputs, labels, comboboxes and the
like.

Paul

--- In flexcoders@yahoogroups.com, Tim 
Rowe  wrote:
>
> It won't run in 40 column mode?
>
> I feel evil suggesting this when 1280x1024 is the norm these days.
>
> --Tim
>
> 
> From: flexcoders@yahoogroups.com
[mailto:flexcoders@yahoogroups.com] On 
Behalf Of aceoohay
> Sent: Tuesday, 13 January 2009 8:59 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Expanding size of panel, and its
contained objects.
>
>
> Actually, I have.
>
> Unfortunately the system they are coming from is a unix character
> based system where an 80 character by 24 line screen takes up their
> entire monitor. A number of the users are complaining that they
> can't read the default font sizes, and while I told them that's all
> I can do, I was hoping to find an easy solution.
>
> Paul
>
> --- In 
> flexcoders@yahoogroups.com, "Nate Beck"  wrote:
> >
> > After thinking about it for a minute... now I'm understanding
what
> you're
> > saying. You want to actually ZOOM in, make them larger.
> > Have you tried taking the easy way out and telling the people to
> change
> > their monitor resolution? :D
> >
> > On Mon, Jan 12, 2009 at 1:47 PM, Nate Beck  wrote:
> >
> > > ... If you're using constraint based layout... how is there a
> problem? A
> > > component taking 100% of the width of it's container will
always
> scale to
> > > fit that container.
> > >
> > >
> > > On Mon, Jan 12, 2009 at 1:27 PM, aceoohay  wrote:
> > >
> > >> While that example does allow you to maximize a panel, it
> does not
> > >> expand the contained objects.
> > >>
> > >> If it did what I need the buttons  and  video
> > >> enable> would become much larger than they were originally
when
> the
> > >> maximize button was clicked.
> > >>
> > >> I should have mentioned that I have done searching, and can
> find the
> > >> expanding panel in many places, but nowhere can I find code
that
> > >> will force the objects in a container to increse in size by
n%.
> > >>
> > >> Paul
> > >>
> > >>
> > >> --- In 
> > >> flexcoders@yahoogroups.com  40yahoogroups.com>, "Nate
> > >> Beck"  wrote:
> > >> >
> > >> > Doing a quick google search for, "flex maximize, minimize
> panel"
> > >> > Returns loads of examples of what you're trying to do I
> think...
> > >> >
> > >> >
http://www.comtaste.com/DashboardExample/DashboardExample.html
> > >> >
> > >> > and
> > >> >
> > >> >
> > >>
>
http://blog.comtaste.com/2008/12/how_to_use_the_flex_dashboard_1.html
> > >> >
> > >> > Right?
> > >> >
> > >> > On Mon, Jan 12, 2009 at 11:17 AM, aceoohay  wrote:
> > >> >
> > >> > > Hello?
> > >> > >
> > >> > > Is anyone out there?
> > >> > >
> > >> > > Any ideas?
> > >> > >
> > >> > > Paul
> > >> > >
> > >> > >
> > >> > > --- In 
> > >> > > flexcoders@yahoogroups.com  40yahoogroups.com> > >> 40yahoogroups.com>,
> > >> > > "aceoohay"  wrote:
> > >> > > >
> > >> > > > The systems that I write are traditional data entry
types
> of
> > >> > > systems.
> > >> > > > I do everything within panels within modules. I have had
> users
> > >> ask
> > >> > > if
> > >> > > > they could expand the size of the panel in order to read
> them
> > >> better
> > >> > > > due to poor eyesight, high res monitors and the like.
> > >> > > >
> > >> > > > Are there any existing panel like components that allow
> > >> expanding,
> > >> > > > while making the contained objects larger?
> > >> > > >
> > >> > > > Contained objects generally include label, textinput,
> textarea,
> > >> > > > combobox, etc... Font sizes would need to be increased,
> etc.
> > >> > > >
> > >> > > > Paul
> > >> > > >
> > >> > >
> > >> > >
> > >> > >
> > >> >
> > >> >
> > >> >
> > >> > --
> > >> >
> > >> > Cheers,
> > >> > Nate
> > >> > 
> > >> > http://blog.natebeck.net
> > >> >
> > >>
> > >>
> > >>
> > >
> > >
> > >
> > > --
> > >
> > > Cheers,
> > > Nate
> > > 
> > > http://blog.natebeck.net
> > >
> > >
> > >
> >
> >

Re: [flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread Wesley Acheson
For all the children try using percentage widths and heights, I don't really
know about the font of things.   Maybe you could increase the font size by
giving everything a font size attached to a variable.  Or try using CSS to
benefit from Cascading rules?

Regards,

Wesley Acheson

On Mon, Jan 12, 2009 at 11:07 PM, aceoohay  wrote:

> Tim:
>
> I am not sure I understand?
>
> What I need is the ability to expand a panel, and all of its
> contained objects such as textinputs, labels, comboboxes and the
> like.
>
> Paul
>
> --- In flexcoders@yahoogroups.com, Tim Rowe  wrote:
> >
> > It won't run in 40 column mode?
> >
> > I feel evil suggesting this when 1280x1024 is the norm these days.
> >
> > --Tim
> >
> > 
> > From: flexcoders@yahoogroups.com
> [mailto:flexcod...@yahoogroups.com] On Behalf Of aceoohay
> > Sent: Tuesday, 13 January 2009 8:59 AM
> > To: flexcoders@yahoogroups.com
> > Subject: [flexcoders] Re: Expanding size of panel, and its
> contained objects.
> >
> >
> > Actually, I have.
> >
> > Unfortunately the system they are coming from is a unix character
> > based system where an 80 character by 24 line screen takes up their
> > entire monitor. A number of the users are complaining that they
> > can't read the default font sizes, and while I told them that's all
> > I can do, I was hoping to find an easy solution.
> >
> > Paul
> >
> > --- In flexcoders@yahoogroups.com 40yahoogroups.com>, "Nate Beck"  wrote:
> > >
> > > After thinking about it for a minute... now I'm understanding
> what
> > you're
> > > saying. You want to actually ZOOM in, make them larger.
> > > Have you tried taking the easy way out and telling the people to
> > change
> > > their monitor resolution? :D
> > >
> > > On Mon, Jan 12, 2009 at 1:47 PM, Nate Beck  wrote:
> > >
> > > > ... If you're using constraint based layout... how is there a
> > problem? A
> > > > component taking 100% of the width of it's container will
> always
> > scale to
> > > > fit that container.
> > > >
> > > >
> > > > On Mon, Jan 12, 2009 at 1:27 PM, aceoohay  wrote:
> > > >
> > > >> While that example does allow you to maximize a panel, it
> > does not
> > > >> expand the contained objects.
> > > >>
> > > >> If it did what I need the buttons  and  > video
> > > >> enable> would become much larger than they were originally
> when
> > the
> > > >> maximize button was clicked.
> > > >>
> > > >> I should have mentioned that I have done searching, and can
> > find the
> > > >> expanding panel in many places, but nowhere can I find code
> that
> > > >> will force the objects in a container to increse in size by
> n%.
> > > >>
> > > >> Paul
> > > >>
> > > >>
> > > >> --- In flexcoders@yahoogroups.com 40yahoogroups.com>  > 40yahoogroups.com>, "Nate
> > > >> Beck"  wrote:
> > > >> >
> > > >> > Doing a quick google search for, "flex maximize, minimize
> > panel"
> > > >> > Returns loads of examples of what you're trying to do I
> > think...
> > > >> >
> > > >> >
> http://www.comtaste.com/DashboardExample/DashboardExample.html
> > > >> >
> > > >> > and
> > > >> >
> > > >> >
> > > >>
> >
> http://blog.comtaste.com/2008/12/how_to_use_the_flex_dashboard_1.html
> > > >> >
> > > >> > Right?
> > > >> >
> > > >> > On Mon, Jan 12, 2009 at 11:17 AM, aceoohay  wrote:
> > > >> >
> > > >> > > Hello?
> > > >> > >
> > > >> > > Is anyone out there?
> > > >> > >
> > > >> > > Any ideas?
> > > >> > >
> > > >> > > Paul
> > > >> > >
> > > >> > >
> > > >> > > --- In flexcoders@yahoogroups.com 40yahoogroups.com>  > 40yahoogroups.com> > > >> 40yahoogroups.com>,
> > > >> > > "aceoohay"  wrote:
> > > >> > > >
> > > >> > > > The systems that I write are traditional data entry
> types
> > of
> > > >> > > systems.
> > > >> > > > I do everything within panels within modules. I have had
> > users
> > > >> ask
> > > >> > > if
> > > >> > > > they could expand the size of the panel in order to read
> > them
> > > >> better
> > > >> > > > due to poor eyesight, high res monitors and the like.
> > > >> > > >
> > > >> > > > Are there any existing panel like components that allow
> > > >> expanding,
> > > >> > > > while making the contained objects larger?
> > > >> > > >
> > > >> > > > Contained objects generally include label, textinput,
> > textarea,
> > > >> > > > combobox, etc... Font sizes would need to be increased,
> > etc.
> > > >> > > >
> > > >> > > > Paul
> > > >> > > >
> > > >> > >
> > > >> > >
> > > >> > >
> > > >> >
> > > >> >
> > > >> >
> > > >> > --
> > > >> >
> > > >> > Cheers,
> > > >> > Nate
> > > >> > 
> > > >> > http://blog.natebeck.net
> > > >> >
> > > >>
> > > >>
> > > >>
> > > >
> > > >
> > > >
> > > > --
> > > >
> > > > Cheers,
> > > > Nate
> > > > 
> > > > http://blog.natebeck.net
> > > >
> > > >
> > > >
> > >
> > >
> > > --
> > >
> > > Cheers,
> > > Nate
> > > 
>

Re: [flexcoders] Stupid Question - Flex width and height

2009-01-12 Thread Wesley Acheson
On Mon, Jan 12, 2009 at 9:48 PM, Wally Kolcz  wrote:

>  This is probably a dumb question but...
>
> I am trying to do a Flex app primarily in AS. In the constuctor I am trying
> to create an ApplicationControlBar that is the same as this:
> 
>
> I am having a problem with trying to create the same effect as right="5"
> and left="5". I assume that I need to put the x="5" (hence the left="5") and
> then do the math to find out the 'stage' size and subtract the other side
> (5) for the width. However what do I use to do the math?
>
> I tried Application.application.stage.width, but I keeping getting a null
> value error. How can I detect the size of the swf at 100%x100% and do the
> math or is there an easier way to do this. Didn't see a mainACB.right.
>
> Here is what I do have:
>
> var mainACB:ApplicationControlBar = new ApplicationControlBar();
> mainACB.x = 5;
> mainACB.y = 65;
>  mainACB.height = 30;
> mainACB.width = Application.application.stage.width - 5;
> Application.application.addChild(mainACB);
> 
>

Em can you not just add mainABC.setStyle("right","5") or am I missing
something? I think that this is what you want?

Regards,
Wesley


[flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread aceoohay
Tim:

I am not sure I understand?

What I need is the ability to expand a panel, and all of its 
contained objects such as textinputs, labels, comboboxes and the 
like.

Paul

--- In flexcoders@yahoogroups.com, Tim Rowe  wrote:
>
> It won't run in 40 column mode?
> 
> I feel evil suggesting this when 1280x1024 is the norm these days.
> 
> --Tim
> 
> 
> From: flexcoders@yahoogroups.com 
[mailto:flexcod...@yahoogroups.com] On Behalf Of aceoohay
> Sent: Tuesday, 13 January 2009 8:59 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Expanding size of panel, and its 
contained objects.
> 
> 
> Actually, I have.
> 
> Unfortunately the system they are coming from is a unix character
> based system where an 80 character by 24 line screen takes up their
> entire monitor. A number of the users are complaining that they
> can't read the default font sizes, and while I told them that's all
> I can do, I was hoping to find an easy solution.
> 
> Paul
> 
> --- In flexcoders@yahoogroups.com, "Nate Beck"  wrote:
> >
> > After thinking about it for a minute... now I'm understanding 
what
> you're
> > saying. You want to actually ZOOM in, make them larger.
> > Have you tried taking the easy way out and telling the people to
> change
> > their monitor resolution? :D
> >
> > On Mon, Jan 12, 2009 at 1:47 PM, Nate Beck  wrote:
> >
> > > ... If you're using constraint based layout... how is there a
> problem? A
> > > component taking 100% of the width of it's container will 
always
> scale to
> > > fit that container.
> > >
> > >
> > > On Mon, Jan 12, 2009 at 1:27 PM, aceoohay  wrote:
> > >
> > >> While that example does allow you to maximize a panel, it
> does not
> > >> expand the contained objects.
> > >>
> > >> If it did what I need the buttons  and  video
> > >> enable> would become much larger than they were originally 
when
> the
> > >> maximize button was clicked.
> > >>
> > >> I should have mentioned that I have done searching, and can
> find the
> > >> expanding panel in many places, but nowhere can I find code 
that
> > >> will force the objects in a container to increse in size by 
n%.
> > >>
> > >> Paul
> > >>
> > >>
> > >> --- In flexcoders@yahoogroups.com  40yahoogroups.com>, "Nate
> > >> Beck"  wrote:
> > >> >
> > >> > Doing a quick google search for, "flex maximize, minimize
> panel"
> > >> > Returns loads of examples of what you're trying to do I
> think...
> > >> >
> > >> > 
http://www.comtaste.com/DashboardExample/DashboardExample.html
> > >> >
> > >> > and
> > >> >
> > >> >
> > >>
> 
http://blog.comtaste.com/2008/12/how_to_use_the_flex_dashboard_1.html
> > >> >
> > >> > Right?
> > >> >
> > >> > On Mon, Jan 12, 2009 at 11:17 AM, aceoohay  wrote:
> > >> >
> > >> > > Hello?
> > >> > >
> > >> > > Is anyone out there?
> > >> > >
> > >> > > Any ideas?
> > >> > >
> > >> > > Paul
> > >> > >
> > >> > >
> > >> > > --- In flexcoders@yahoogroups.com  40yahoogroups.com> > >> 40yahoogroups.com>,
> > >> > > "aceoohay"  wrote:
> > >> > > >
> > >> > > > The systems that I write are traditional data entry 
types
> of
> > >> > > systems.
> > >> > > > I do everything within panels within modules. I have had
> users
> > >> ask
> > >> > > if
> > >> > > > they could expand the size of the panel in order to read
> them
> > >> better
> > >> > > > due to poor eyesight, high res monitors and the like.
> > >> > > >
> > >> > > > Are there any existing panel like components that allow
> > >> expanding,
> > >> > > > while making the contained objects larger?
> > >> > > >
> > >> > > > Contained objects generally include label, textinput,
> textarea,
> > >> > > > combobox, etc... Font sizes would need to be increased,
> etc.
> > >> > > >
> > >> > > > Paul
> > >> > > >
> > >> > >
> > >> > >
> > >> > >
> > >> >
> > >> >
> > >> >
> > >> > --
> > >> >
> > >> > Cheers,
> > >> > Nate
> > >> > 
> > >> > http://blog.natebeck.net
> > >> >
> > >>
> > >>
> > >>
> > >
> > >
> > >
> > > --
> > >
> > > Cheers,
> > > Nate
> > > 
> > > http://blog.natebeck.net
> > >
> > >
> > >
> >
> >
> > --
> >
> > Cheers,
> > Nate
> > 
> > http://blog.natebeck.net
> >
>




RE: [flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread Tim Rowe
It won't run in 40 column mode?

I feel evil suggesting this when 1280x1024 is the norm these days.

--Tim


From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of aceoohay
Sent: Tuesday, 13 January 2009 8:59 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Expanding size of panel, and its contained objects.


Actually, I have.

Unfortunately the system they are coming from is a unix character
based system where an 80 character by 24 line screen takes up their
entire monitor. A number of the users are complaining that they
can't read the default font sizes, and while I told them that's all
I can do, I was hoping to find an easy solution.

Paul

--- In flexcoders@yahoogroups.com, "Nate 
Beck"  wrote:
>
> After thinking about it for a minute... now I'm understanding what
you're
> saying. You want to actually ZOOM in, make them larger.
> Have you tried taking the easy way out and telling the people to
change
> their monitor resolution? :D
>
> On Mon, Jan 12, 2009 at 1:47 PM, Nate Beck  wrote:
>
> > ... If you're using constraint based layout... how is there a
problem? A
> > component taking 100% of the width of it's container will always
scale to
> > fit that container.
> >
> >
> > On Mon, Jan 12, 2009 at 1:27 PM, aceoohay  wrote:
> >
> >> While that example does allow you to maximize a panel, it
does not
> >> expand the contained objects.
> >>
> >> If it did what I need the buttons  and  >> enable> would become much larger than they were originally when
the
> >> maximize button was clicked.
> >>
> >> I should have mentioned that I have done searching, and can
find the
> >> expanding panel in many places, but nowhere can I find code that
> >> will force the objects in a container to increse in size by n%.
> >>
> >> Paul
> >>
> >>
> >> --- In flexcoders@yahoogroups.com 
> >> , "Nate
> >> Beck"  wrote:
> >> >
> >> > Doing a quick google search for, "flex maximize, minimize
panel"
> >> > Returns loads of examples of what you're trying to do I
think...
> >> >
> >> > http://www.comtaste.com/DashboardExample/DashboardExample.html
> >> >
> >> > and
> >> >
> >> >
> >>
http://blog.comtaste.com/2008/12/how_to_use_the_flex_dashboard_1.html
> >> >
> >> > Right?
> >> >
> >> > On Mon, Jan 12, 2009 at 11:17 AM, aceoohay  wrote:
> >> >
> >> > > Hello?
> >> > >
> >> > > Is anyone out there?
> >> > >
> >> > > Any ideas?
> >> > >
> >> > > Paul
> >> > >
> >> > >
> >> > > --- In flexcoders@yahoogroups.com 
> >> > >  >> 40yahoogroups.com>,
> >> > > "aceoohay"  wrote:
> >> > > >
> >> > > > The systems that I write are traditional data entry types
of
> >> > > systems.
> >> > > > I do everything within panels within modules. I have had
users
> >> ask
> >> > > if
> >> > > > they could expand the size of the panel in order to read
them
> >> better
> >> > > > due to poor eyesight, high res monitors and the like.
> >> > > >
> >> > > > Are there any existing panel like components that allow
> >> expanding,
> >> > > > while making the contained objects larger?
> >> > > >
> >> > > > Contained objects generally include label, textinput,
textarea,
> >> > > > combobox, etc... Font sizes would need to be increased,
etc.
> >> > > >
> >> > > > Paul
> >> > > >
> >> > >
> >> > >
> >> > >
> >> >
> >> >
> >> >
> >> > --
> >> >
> >> > Cheers,
> >> > Nate
> >> > 
> >> > http://blog.natebeck.net
> >> >
> >>
> >>
> >>
> >
> >
> >
> > --
> >
> > Cheers,
> > Nate
> > 
> > http://blog.natebeck.net
> >
> >
> >
>
>
> --
>
> Cheers,
> Nate
> 
> http://blog.natebeck.net
>





[flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread aceoohay
Actually, I have.

Unfortunately the system they are coming from is a unix character 
based system where an 80 character by 24 line screen takes up their 
entire monitor. A number of the users are complaining that they 
can't read the default font sizes, and while I told them that's all 
I can do, I was hoping to find an easy solution.

Paul

--- In flexcoders@yahoogroups.com, "Nate Beck"  wrote:
>
> After thinking about it for a minute... now I'm understanding what 
you're
> saying. You want to actually ZOOM in, make them larger.
> Have you tried taking the easy way out and telling the people to 
change
> their monitor resolution? :D
> 
> On Mon, Jan 12, 2009 at 1:47 PM, Nate Beck  wrote:
> 
> > ... If you're using constraint based layout... how is there a 
problem?  A
> > component taking 100% of the width of it's container will always 
scale to
> > fit that container.
> >
> >
> > On Mon, Jan 12, 2009 at 1:27 PM, aceoohay  wrote:
> >
> >>   While that example does allow you to maximize a panel, it 
does not
> >> expand the contained objects.
> >>
> >> If it did what I need the buttons  and  >> enable> would become much larger than they were originally when 
the
> >> maximize button was clicked.
> >>
> >> I should have mentioned that I have done searching, and can 
find the
> >> expanding panel in many places, but nowhere can I find code that
> >> will force the objects in a container to increse in size by n%.
> >>
> >> Paul
> >>
> >>
> >> --- In flexcoders@yahoogroups.com , "Nate
> >> Beck"  wrote:
> >> >
> >> > Doing a quick google search for, "flex maximize, minimize 
panel"
> >> > Returns loads of examples of what you're trying to do I 
think...
> >> >
> >> > http://www.comtaste.com/DashboardExample/DashboardExample.html
> >> >
> >> > and
> >> >
> >> >
> >> 
http://blog.comtaste.com/2008/12/how_to_use_the_flex_dashboard_1.html
> >> >
> >> > Right?
> >> >
> >> > On Mon, Jan 12, 2009 at 11:17 AM, aceoohay  wrote:
> >> >
> >> > > Hello?
> >> > >
> >> > > Is anyone out there?
> >> > >
> >> > > Any ideas?
> >> > >
> >> > > Paul
> >> > >
> >> > >
> >> > > --- In flexcoders@yahoogroups.com  >> 40yahoogroups.com>,
> >> > > "aceoohay"  wrote:
> >> > > >
> >> > > > The systems that I write are traditional data entry types 
of
> >> > > systems.
> >> > > > I do everything within panels within modules. I have had 
users
> >> ask
> >> > > if
> >> > > > they could expand the size of the panel in order to read 
them
> >> better
> >> > > > due to poor eyesight, high res monitors and the like.
> >> > > >
> >> > > > Are there any existing panel like components that allow
> >> expanding,
> >> > > > while making the contained objects larger?
> >> > > >
> >> > > > Contained objects generally include label, textinput, 
textarea,
> >> > > > combobox, etc... Font sizes would need to be increased, 
etc.
> >> > > >
> >> > > > Paul
> >> > > >
> >> > >
> >> > >
> >> > >
> >> >
> >> >
> >> >
> >> > --
> >> >
> >> > Cheers,
> >> > Nate
> >> > 
> >> > http://blog.natebeck.net
> >> >
> >>
> >>  
> >>
> >
> >
> >
> > --
> >
> > Cheers,
> > Nate
> > 
> > http://blog.natebeck.net
> >
> >
> >
> 
> 
> -- 
> 
> Cheers,
> Nate
> 
> http://blog.natebeck.net
>




Re: [flexcoders] Flex 3 Dialog Boxes ...

2009-01-12 Thread Wesley Acheson
Looks like an issue with Java SWT to me.  Do you have a recient JDK
installed?

On Sat, Jan 10, 2009 at 8:22 AM, SJF  wrote:

>  Hello All,
>
> I'm using Flex 3 and working on pure actionscript projects (i.e: File > New
> > ActionScript Project).
>
> I often have issues with numerous dialog boxes and parts of the interface
> within Flex (see images below):
> http://img339.imageshack.us/img339/512/60793305bx2.gif
> http://img224.imageshack.us/img224/7996/64384807bn2.gif
>
> Tabs and controls within these boxes don't appear correctly. This is not a
> memory issue as my laptop is a high spec machine and Flex is the only thing
> running.
>
> Also, a recent suggestion made was to update my display drivers, which I
> have done - unfortunately this hasn't fixed the issue.
>
> Anyone advise or have the same problem?
>
> Cheers,
> SF.
> 
>


Re: [flexcoders] Data Grid with dynamic columns ignoring % width or right style.

2009-01-12 Thread Wesley Acheson
On Mon, Jan 12, 2009 at 7:45 PM, Manish Jethani wrote:

> On Sun, Jan 11, 2009 at 3:51 AM, wesley.acheson
>  wrote:
>
> > I've a problem with the DataGrid ignoring the % width, while using
> > Canvas as the parent.  When I dynamically create columns it stretches
> > to beyond the origional area.  This behaviour has been reported as a
> > bug. http://bugs.adobe.com/jira/browse/SDK-14390.  The workarround
> > described in the bug setting the width to 0 works for me in a simple
> > test case but doesn't appear to work within my main application.
>
> [...]
>
> > I would like to extend datagrid with a version that doesn't have this
> > issue if I can figure out why a fixed width doesn't work.
>
> I've left a reply on the bug:
>
> http://bugs.adobe.com/jira/browse/SDK-14390
>
> Basically your DataGrid's minWidth is too large for the Panel. You can
> set the minWidth property to reduce it. By default the measured value
> for minWidth is always going to be large enough to accommodate all the
> columns.
>
> Manish
>

Okay sorry If I wasn't clear enough about it basically the data grid
stretches, but not enough to accomidate all columns. Nor even enough to fill
the container.  Setting a width of 0 makes the datagrid remember its
constraint layout.  Some other intresting factors in my test case if I leave
on column not dynamically created specified in the mxml, and replace it with
the dynamic columns then it works correctly.

The other point is that it still occurs even if horizontal scroll policy is
set to on.  (Which is actually the way I want it to work).  Again I got this
reply when I was at home so it will have to wait until tomorrow if I produce
a test case.

My test case was simply adding a data grid to an application and either
giving it a right constraint or a percentage width.  The I created a loop
and created an array of DataGridColumn headers.  Then I set this array as
the datagrid column array.

Anyway thanks for your time Manis.

Wesley


Re: [flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread Nate Beck
After thinking about it for a minute... now I'm understanding what you're
saying. You want to actually ZOOM in, make them larger.
Have you tried taking the easy way out and telling the people to change
their monitor resolution? :D

On Mon, Jan 12, 2009 at 1:47 PM, Nate Beck  wrote:

> ... If you're using constraint based layout... how is there a problem?  A
> component taking 100% of the width of it's container will always scale to
> fit that container.
>
>
> On Mon, Jan 12, 2009 at 1:27 PM, aceoohay  wrote:
>
>>   While that example does allow you to maximize a panel, it does not
>> expand the contained objects.
>>
>> If it did what I need the buttons  and > enable> would become much larger than they were originally when the
>> maximize button was clicked.
>>
>> I should have mentioned that I have done searching, and can find the
>> expanding panel in many places, but nowhere can I find code that
>> will force the objects in a container to increse in size by n%.
>>
>> Paul
>>
>>
>> --- In flexcoders@yahoogroups.com , "Nate
>> Beck"  wrote:
>> >
>> > Doing a quick google search for, "flex maximize, minimize panel"
>> > Returns loads of examples of what you're trying to do I think...
>> >
>> > http://www.comtaste.com/DashboardExample/DashboardExample.html
>> >
>> > and
>> >
>> >
>> http://blog.comtaste.com/2008/12/how_to_use_the_flex_dashboard_1.html
>> >
>> > Right?
>> >
>> > On Mon, Jan 12, 2009 at 11:17 AM, aceoohay  wrote:
>> >
>> > > Hello?
>> > >
>> > > Is anyone out there?
>> > >
>> > > Any ideas?
>> > >
>> > > Paul
>> > >
>> > >
>> > > --- In flexcoders@yahoogroups.com 
>> > > > 40yahoogroups.com>,
>> > > "aceoohay"  wrote:
>> > > >
>> > > > The systems that I write are traditional data entry types of
>> > > systems.
>> > > > I do everything within panels within modules. I have had users
>> ask
>> > > if
>> > > > they could expand the size of the panel in order to read them
>> better
>> > > > due to poor eyesight, high res monitors and the like.
>> > > >
>> > > > Are there any existing panel like components that allow
>> expanding,
>> > > > while making the contained objects larger?
>> > > >
>> > > > Contained objects generally include label, textinput, textarea,
>> > > > combobox, etc... Font sizes would need to be increased, etc.
>> > > >
>> > > > Paul
>> > > >
>> > >
>> > >
>> > >
>> >
>> >
>> >
>> > --
>> >
>> > Cheers,
>> > Nate
>> > 
>> > http://blog.natebeck.net
>> >
>>
>>  
>>
>
>
>
> --
>
> Cheers,
> Nate
> 
> http://blog.natebeck.net
>
>
>


-- 

Cheers,
Nate

http://blog.natebeck.net


Re: [flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread Nate Beck
... If you're using constraint based layout... how is there a problem?  A
component taking 100% of the width of it's container will always scale to
fit that container.

On Mon, Jan 12, 2009 at 1:27 PM, aceoohay  wrote:

>   While that example does allow you to maximize a panel, it does not
> expand the contained objects.
>
> If it did what I need the buttons  and  enable> would become much larger than they were originally when the
> maximize button was clicked.
>
> I should have mentioned that I have done searching, and can find the
> expanding panel in many places, but nowhere can I find code that
> will force the objects in a container to increse in size by n%.
>
> Paul
>
>
> --- In flexcoders@yahoogroups.com , "Nate
> Beck"  wrote:
> >
> > Doing a quick google search for, "flex maximize, minimize panel"
> > Returns loads of examples of what you're trying to do I think...
> >
> > http://www.comtaste.com/DashboardExample/DashboardExample.html
> >
> > and
> >
> >
> http://blog.comtaste.com/2008/12/how_to_use_the_flex_dashboard_1.html
> >
> > Right?
> >
> > On Mon, Jan 12, 2009 at 11:17 AM, aceoohay  wrote:
> >
> > > Hello?
> > >
> > > Is anyone out there?
> > >
> > > Any ideas?
> > >
> > > Paul
> > >
> > >
> > > --- In flexcoders@yahoogroups.com 
> > >  40yahoogroups.com>,
> > > "aceoohay"  wrote:
> > > >
> > > > The systems that I write are traditional data entry types of
> > > systems.
> > > > I do everything within panels within modules. I have had users
> ask
> > > if
> > > > they could expand the size of the panel in order to read them
> better
> > > > due to poor eyesight, high res monitors and the like.
> > > >
> > > > Are there any existing panel like components that allow
> expanding,
> > > > while making the contained objects larger?
> > > >
> > > > Contained objects generally include label, textinput, textarea,
> > > > combobox, etc... Font sizes would need to be increased, etc.
> > > >
> > > > Paul
> > > >
> > >
> > >
> > >
> >
> >
> >
> > --
> >
> > Cheers,
> > Nate
> > 
> > http://blog.natebeck.net
> >
>
>  
>



-- 

Cheers,
Nate

http://blog.natebeck.net


[flexcoders] Re: geting info of a user who has loged in

2009-01-12 Thread valdhor
I use PHP and WebORb for PHP so anything I show will use that.
Please do not ask for a tutorial using something else.
There should be enough here for you to extrapolate for use with any
language.

This is a quick and dirty example that hard codes things. In a real
application
I would loosely couple everything with events.

My Flex project is set up with a couple of folders called components and
ValueObjects.

The main Application file (login_example.mxml):

http://www.adobe.com/2006/mxml";
layout="absolute" xmlns:view="components.*"
 applicationComplete="doApplicationComplete()">
 
 
 
 
 
 
 


This has a view stack for each view - Admin and Home. There are also a
couple of functions.
doApplicationComplete is called on applicationComplete event and
instantiates the login
window. doLogin is called from the login component if login is
successful. It poulates the
userCredentials variable of the Admin component.

==
components/Home.mxml:

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



This is just a container for the background of the login window at
startup.

==
components/login.mxml:

http://www.adobe.com/2006/mxml";
layout="absolute" title="Login Form"
 creationComplete="PopUpManager.centerPopUp(this)"
initialize="onInitialize()">
 
 
 
 
 
 
 
 
 
 
 
 
 
 


This is the login window. It has a form with username and password
fields. The login
button invokes the remoteObject with these fields. If these fields are
in the database
then the string "Success" will be returned and the doLogin function in
the main
application will be invoked.

==
components/Admin.mxml:

http://www.adobe.com/2006/mxml"; width="100%"
height="100%"
 creationComplete="onCreationComplete()">
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 


This is the Admin component. It gets instantiated when the login is
successful. The
userCredentials variable will be populated from the main application
file (In the doLogin
function). This component will then invoke the remoteObject call to get
the userInfo
and when the result comes back, populate each of the TextInput items.

==
ValueObjects/UserCredentials.as:
package ValueObjects
{
 [RemoteClass(alias="UserInfo.Classes.UserCredentials")]
 [Bindable]
 public class UserCredentials
 {
 //instance variables
 private var _username:String;
 private var _password:String;

 //accessor methods
 public function get username():String {return _username;}
 public function get password():String {return _password;}

 //mutator methods
 public function set username(username:String):void {_username =
username;}
 public function set password(password:String):void {_password =
password;}
 } // end class
}//end package

This object holds the user credentials (username and password) to be
sent to the server.

==
ValueObjects/UserInfo.as:

package ValueObjects
{
 [RemoteClass(alias="UserInfo.Classes.UserInfo")]
 [Bindable]
 public class UserInfo
 {
 //instance variables
 private var _username:String;
 private var _password:String;
 private var _firstname:String;
 private var _lastname:String;
 private var _email:String;

 //accessor methods
 public function get username():String {return _username;}
 public function get password():String {return _password;}
 public function get firstname():String {return _firstname;}
 public function get lastname():String {return _lastname;}
 public function get email():String {return _email;}

 //mutator methods
 public function set username(username:String):void {_username =
username;}
 public function set password(password:String):void {_password =
password;}
 public function set firstname(firstname:String):void {_firstname
= firstname;}
 public function set lastname(lastname:String):void {_lastname =
lastname;}
 public function set email(email:String):void {_email = email;}
 } // end class
}//end package

This object holds the user info returned by the server.

==

That's it for the Flex code.

Next up, the PHP side...

On the PHP side I have a UserInfo folder inside the Services folder of
WebORB.
Inside this folder I have a Classes folder to hold the value object

Re: [flexcoders] Re: How to create universal event handler?

2009-01-12 Thread Howard Fore
Nope, I meant the process described here:
http://livedocs.adobe.com/flex/3/html/help.html?content=createevents_3.html

But I think Manish's answer is the easier approach.

On Mon, Jan 12, 2009 at 1:55 PM, Dan  wrote:
>> Create a custom event that uses your current event type string as a
>> variable. Then your handler can look at the variable value to decide
>> what to do.
>>
>
> You mean when I do dispatchEvent, I always use the same type string,
> like this?
> dispatchEvent(new MyEvent(MyEvent.MY_EVENT)
> dispatchEvent(new MyChildEvent(MyEvent.MY_EVENT)
> dispatchEvent(new MyFutureChildEvent(MyEvent.MY_EVENT)


-- 
Howard Fore, howard.f...@hofo.com
"The universe tends toward maximum irony. Don't push it." - Jeff Atwood


[flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread aceoohay
While that example does allow you to maximize a panel, it does not 
expand the contained objects.

If it did what I need the buttons  and  would become much larger than they were originally when the 
maximize button was clicked.

I should have mentioned that I have done searching, and can find the 
expanding panel in many places, but nowhere can I find code that 
will force the objects in a container to increse in size by n%.

Paul


--- In flexcoders@yahoogroups.com, "Nate Beck"  wrote:
>
> Doing a quick google search for, "flex maximize, minimize panel"
> Returns loads of examples of what you're trying to do I think...
> 
> http://www.comtaste.com/DashboardExample/DashboardExample.html
> 
> and
> 
> 
http://blog.comtaste.com/2008/12/how_to_use_the_flex_dashboard_1.html
> 
> Right?
> 
> On Mon, Jan 12, 2009 at 11:17 AM, aceoohay  wrote:
> 
> >   Hello?
> >
> > Is anyone out there?
> >
> > Any ideas?
> >
> > Paul
> >
> >
> > --- In flexcoders@yahoogroups.com ,
> > "aceoohay"  wrote:
> > >
> > > The systems that I write are traditional data entry types of
> > systems.
> > > I do everything within panels within modules. I have had users 
ask
> > if
> > > they could expand the size of the panel in order to read them 
better
> > > due to poor eyesight, high res monitors and the like.
> > >
> > > Are there any existing panel like components that allow 
expanding,
> > > while making the contained objects larger?
> > >
> > > Contained objects generally include label, textinput, textarea,
> > > combobox, etc... Font sizes would need to be increased, etc.
> > >
> > > Paul
> > >
> >
> >  
> >
> 
> 
> 
> -- 
> 
> Cheers,
> Nate
> 
> http://blog.natebeck.net
>




[flexcoders] How to avoid red borders created by validators at page loading

2009-01-12 Thread b.kotireddy
Hi,

In my page i have textInput's and Combo Box fields. When my page loads
Text Input fields are not having any red borders, but all Combo Boxes
are with red borders with "This Field is required". I think these
because of Validations. Is their any way that i can avoid that red
borders with text. 

Thanks in Advance
koti 



[flexcoders] Re: How to register a dynamicEvent in an Actionscript class

2009-01-12 Thread flexcoder2008
Thanks Nate,

Tried that but it still doesn't work.  I'm basically trying to
dispatch a dynamicEvent from a Cairngorm event and then trying to get
a module to listen for that event.  I don't want this event to be a
CiarngormEvent to be handled by the FrontController and the Command
object.  In other words, I want the module that originally dispatched
the CairngormEvent to handle the DynamicEvent that gets raised by the
CairngormCommand.

I just can't seem to get this to work.  




--- In flexcoders@yahoogroups.com, "Nate Beck"  wrote:
>
> Events don't bubble by default.
> So if you're depending on the Cairngorm Front Controller to pick
them up,
> and the object dispatching the event isn't directly below the
Application,
> you need to enable event bubbling.
> 
> new DynamicEvent("myType", true);
> 
> Cheers,
> Nate
> 
> On Mon, Jan 12, 2009 at 11:48 AM, flexcoder2008 wrote:
> 
> >   Well, I want to dispatch the dynamicEvent from the actionscript
class
> > (which is a Cairngorm command) and I want my module to listen for that
> > event.
> >
> > Since the module event handler code is not being hit, I thought I
> > might need to register this event with the compiler (perhaps my
> > terminology is wrong - sorry). I know that when using a component,
> > you use the [Event] metadata tag to announce that the component
> > dispatches a particular event. I thought that I might have to do the
> > same thing with an actionscript class.
> >
> > --- In flexcoders@yahoogroups.com ,
> > "kylewburke"  wrote:
> > >
> > > What do you mean by "register"? Do you want to listen for that event
> > > or dispatch one?
> > >
> > > --- In flexcoders@yahoogroups.com ,
> > "flexcoder2008"  wrote:
> > > >
> > > > I have seen numerous examples of registering a dynamicEvent in a
> > > > component's mxml such as:
> > > >
> > > > [Event (name="rowSelected", type="mx.events.DynamicEvent")]
> > > >
> > > > If I have an actionscript class that dispatches a
dynamicEvent, what
> > > > is the syntax for this?
> > > >
> > > > I want to dispatch a dynamicEvent from an actionscript class,
and I
> > > > want my module to listen for that event.
> > > >
> > >
> >
> >  
> >
> 
> 
> 
> -- 
> 
> Cheers,
> Nate
> 
> http://blog.natebeck.net
>




[flexcoders] Re: ExternalInterface erros

2009-01-12 Thread flexaustin
Here is the string being passed. The JSONEncoder encodes the object
into a string (data var in this case) then passes it over using
externalInterface.

data:String =
{"error":0,"requests":0,"group":true,"model":"userdefined","count":0,"name":"\"\\error\\Something\"
YOU $ 
'FBar'","connection":0,"warning":0,"title":"\"\\error\\Something\"
YOU $  'FBar'","type":"BigCategory","id":43}




--- In flexcoders@yahoogroups.com, "Ralf Bokelberg"
 wrote:
>
> Why do you want to use JSON? You can pass in plain objects instead, e.g.
> 
> ExternalInterface.call("someJSMethod", { a: 1, b: { c: true, d:
"hello"} } );
> 
> Ralf.
> 
> On Mon, Jan 12, 2009 at 7:55 PM, flexaustin  wrote:
> > I can't really post the code. The issue is either I think is either
> > one of two things, but I can't seem to resolve either of them.
> >
> > #1. I am passing data to a javascript function in json format, which
> > contains escaped " & \.
> >
> > #2. This is the issue.
> >
http://joshblog.net/2008/01/03/flash-player-externalinterface-variable-name-bug/
> > On this one I tried putting my function call in '' to as this blog
> > post suggests, but it didn't help.
> >
> > The JSONENcoder is escaping the " and \ on the flex/actionscript side,
> > but when it is getting passed to the javascript file I don't think the
> > javascript file is understanding the escaped items. I am not a JS guy
> > so I don't know if JS/Broswer knows about escaped characters?
> >
> > TIA, J
> >
> > --- In flexcoders@yahoogroups.com, "Anthony DeBonis"  wrote:
> >>
> >> -What browser are you using - or does it happen in all browsers
> >>
> >> - Can you get something simple to work like this
> >> ExternalInterface.call("alert('TEST')");
> >>
> >> -Can you post the code?
> >>
> >
> >
>




Re: [flexcoders] VO and LabelField Problem

2009-01-12 Thread Berkay Unal
Nothing happens.
I got it working if i cast the evt.result to ArrayCollection but when i cast
it,  in the flex debugger i see the result.events as an nativeObject not VO
Objects.

Best,

Berkay UNAL
berkayu...@gmail.com


On Mon, Jan 12, 2009 at 18:06, Alex Harui  wrote:

>What happens when you use labelField="courseName"?
>
>
>
> *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On
> Behalf Of *Berkay Unal
> *Sent:* Sunday, January 11, 2009 9:24 AM
> *To:* flexcoders@yahoogroups.com
> *Subject:* [flexcoders] VO and LabelField Problem
>
>
>
> Hi,
>
>
>
> When trying have dataprovider for a list control using remoting with VO i
> cannot set the label of the control with the labelField = "courseName".
>
>
>
> How to achieve this, guess i am missing smthing. Any help appreciated much
>
>
>
> result   Array (@1a522159)
>
>
>
> [0]com.abc.courseList.VO.CourseVO (@1ee40449)
>
> courseID 1
>
> courseName"Course1"
>
> [1]com.abc.courseList.VO.CourseVO (@1ee404c1)
>
> courseID 2
>
> courseName"Course2"
>
> [2]com.abc.courseList.VO.CourseVO (@1ee40719)
>
> courseID 3
>
> courseName"Course3"
>
> length  3
>
>
>
> Best
>
> Bunal
>
>
>
>   
>


Re: [flexcoders] Stupid Question - Flex width and height

2009-01-12 Thread Alan K
It would seem to me that "Application.application.stage.width" only  
exists when using the Flex framework.  Without Flex your just dealing  
with the 'default' Flash display list.


Alan
On Jan 12, 2009, at 3:48 PM, Wally Kolcz wrote:


Application.application.stage.width




[flexcoders] Stupid Question - Flex width and height

2009-01-12 Thread Wally Kolcz

This is probably a dumb question but...

I am trying to do a Flex app primarily in AS. In the constuctor I am trying to 
create an ApplicationControlBar that is the same as this:


I am having a problem with trying to create the same effect as right="5" and 
left="5". I assume that I need to put the x="5" (hence the left="5") and then 
do the math to find out the 'stage' size and subtract the other side (5) for 
the width. However what do I use to do the math?

I tried Application.application.stage.width, but I keeping getting a null value 
error. How can I detect the size of the swf at 100%x100% and do the math or is 
there an easier way to do this. Didn't see a mainACB.right.

Here is what I do have:

var mainACB:ApplicationControlBar = new ApplicationControlBar();
mainACB.x = 5;
mainACB.y = 65;
 mainACB.height = 30;
mainACB.width = Application.application.stage.width - 5;  
Application.application.addChild(mainACB); 




Re: [flexcoders] Re: How to register a dynamicEvent in an Actionscript class

2009-01-12 Thread Nate Beck
Events don't bubble by default.
So if you're depending on the Cairngorm Front Controller to pick them up,
and the object dispatching the event isn't directly below the Application,
you need to enable event bubbling.

new DynamicEvent("myType", true);

Cheers,
Nate

On Mon, Jan 12, 2009 at 11:48 AM, flexcoder2008 wrote:

>   Well, I want to dispatch the dynamicEvent from the actionscript class
> (which is a Cairngorm command) and I want my module to listen for that
> event.
>
> Since the module event handler code is not being hit, I thought I
> might need to register this event with the compiler (perhaps my
> terminology is wrong - sorry). I know that when using a component,
> you use the [Event] metadata tag to announce that the component
> dispatches a particular event. I thought that I might have to do the
> same thing with an actionscript class.
>
> --- In flexcoders@yahoogroups.com ,
> "kylewburke"  wrote:
> >
> > What do you mean by "register"? Do you want to listen for that event
> > or dispatch one?
> >
> > --- In flexcoders@yahoogroups.com ,
> "flexcoder2008"  wrote:
> > >
> > > I have seen numerous examples of registering a dynamicEvent in a
> > > component's mxml such as:
> > >
> > > [Event (name="rowSelected", type="mx.events.DynamicEvent")]
> > >
> > > If I have an actionscript class that dispatches a dynamicEvent, what
> > > is the syntax for this?
> > >
> > > I want to dispatch a dynamicEvent from an actionscript class, and I
> > > want my module to listen for that event.
> > >
> >
>
>  
>



-- 

Cheers,
Nate

http://blog.natebeck.net


[flexcoders] Re: How to register a dynamicEvent in an Actionscript class

2009-01-12 Thread flexcoder2008
Well, I want to dispatch the dynamicEvent from the actionscript class
(which is a Cairngorm command) and I want my module to listen for that
event.  

Since the module event handler code is not being hit, I thought I
might need to register this event with the compiler (perhaps my
terminology is wrong - sorry).  I know that when using a component,
you use the [Event] metadata tag to announce that the component
dispatches a particular event.  I thought that I might have to do the
same thing with an actionscript class.  



--- In flexcoders@yahoogroups.com, "kylewburke"  wrote:
>
> What do you mean by "register"?  Do you want to listen for that event
> or dispatch one?
> 
> --- In flexcoders@yahoogroups.com, "flexcoder2008"  wrote:
> >
> > I have seen numerous examples of registering a dynamicEvent in a
> > component's mxml such as:
> > 
> > [Event (name="rowSelected", type="mx.events.DynamicEvent")]
> > 
> > If I have an actionscript class that dispatches a dynamicEvent, what
> > is the syntax for this?
> > 
> > I want to dispatch a dynamicEvent from an actionscript class, and I
> > want my module to listen for that event.
> >
>




[flexcoders] Re: How to register a dynamicEvent in an Actionscript class

2009-01-12 Thread kylewburke
What do you mean by "register"?  Do you want to listen for that event
or dispatch one?

--- In flexcoders@yahoogroups.com, "flexcoder2008"  wrote:
>
> I have seen numerous examples of registering a dynamicEvent in a
> component's mxml such as:
> 
> [Event (name="rowSelected", type="mx.events.DynamicEvent")]
> 
> If I have an actionscript class that dispatches a dynamicEvent, what
> is the syntax for this?
> 
> I want to dispatch a dynamicEvent from an actionscript class, and I
> want my module to listen for that event.
>




[flexcoders] Re: How to register a dynamicEvent in an Actionscript class

2009-01-12 Thread flexcoder2008
Hmmm, this is the way I have done it - but my event handler is not firing.

I am dispatching my DynamicEvent from a Cairngorm command - in the
execute method I have:

var evt:DynamicEvent = new DynamicEvent("initCompleted");
dispatchEvent(evt);


in my module's creationComplete handler I have this code:

this.addEventListener("initCompleted",initCompletedHandler);



Then in the module's script block I have the event handler

private function initCompletedHandler(event:DynamicEvent):void{
}


This handler never gets hit.


--- In flexcoders@yahoogroups.com, "Nate Beck"  wrote:
>
> It's exactly the same as a standard Event.  As you can see in the
Language
> Reference (
> http://livedocs.adobe.com/flex/3/langref/mx/events/DynamicEvent.html):
> 
> var event:DynamicEvent = new DynamicEvent("credentialsChanged");
>   event.name = name;
>   event.passsword = password; // misspelling won't be caught!
>   dispatchEvent(event);
> 
> then..
> 
> module.addEventListener("credentialsChanged", myHandler);
> 
> The DynamicEvent class works exactly like and Event... it just gives
> you the ability to add properties to it at runtime.  If you're going
> to be using the same event over and over again.  You're better off
> just creating a custom event
>
(http://livedocs.adobe.com/flex/3/html/help.html?content=createevents_1.html#110674).
> 
> "If you do not identify an event in the class file with the [Event]
> metadata tag, the MXML compiler generates an error if you try to use
> the event name in MXML. Any component can register an event listener
> for the event in ActionScript by using the addEventListener()method,
> even if you omit the [Event] metadata tag."
> 
> HTH,
> 
> Nate
> 
> On Mon, Jan 12, 2009 at 11:07 AM, flexcoder2008 wrote:
> 
> >   I have seen numerous examples of registering a dynamicEvent in a
> > component's mxml such as:
> >
> > [Event (name="rowSelected", type="mx.events.DynamicEvent")]
> >
> > If I have an actionscript class that dispatches a dynamicEvent, what
> > is the syntax for this?
> >
> > I want to dispatch a dynamicEvent from an actionscript class, and I
> > want my module to listen for that event.
> >
> >  
> >
> 
> 
> 
> -- 
> 
> Cheers,
> Nate
> 
> http://blog.natebeck.net
>




Re: [flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread Nate Beck
Doing a quick google search for, "flex maximize, minimize panel"
Returns loads of examples of what you're trying to do I think...

http://www.comtaste.com/DashboardExample/DashboardExample.html

and

http://blog.comtaste.com/2008/12/how_to_use_the_flex_dashboard_1.html

Right?

On Mon, Jan 12, 2009 at 11:17 AM, aceoohay  wrote:

>   Hello?
>
> Is anyone out there?
>
> Any ideas?
>
> Paul
>
>
> --- In flexcoders@yahoogroups.com ,
> "aceoohay"  wrote:
> >
> > The systems that I write are traditional data entry types of
> systems.
> > I do everything within panels within modules. I have had users ask
> if
> > they could expand the size of the panel in order to read them better
> > due to poor eyesight, high res monitors and the like.
> >
> > Are there any existing panel like components that allow expanding,
> > while making the contained objects larger?
> >
> > Contained objects generally include label, textinput, textarea,
> > combobox, etc... Font sizes would need to be increased, etc.
> >
> > Paul
> >
>
>  
>



-- 

Cheers,
Nate

http://blog.natebeck.net


Re: [flexcoders] How to register a dynamicEvent in an Actionscript class

2009-01-12 Thread Nate Beck
It's exactly the same as a standard Event.  As you can see in the Language
Reference (
http://livedocs.adobe.com/flex/3/langref/mx/events/DynamicEvent.html):

var event:DynamicEvent = new DynamicEvent("credentialsChanged");
  event.name = name;
  event.passsword = password; // misspelling won't be caught!
  dispatchEvent(event);

then..

module.addEventListener("credentialsChanged", myHandler);

The DynamicEvent class works exactly like and Event... it just gives
you the ability to add properties to it at runtime.  If you're going
to be using the same event over and over again.  You're better off
just creating a custom event
(http://livedocs.adobe.com/flex/3/html/help.html?content=createevents_1.html#110674).

"If you do not identify an event in the class file with the [Event]
metadata tag, the MXML compiler generates an error if you try to use
the event name in MXML. Any component can register an event listener
for the event in ActionScript by using the addEventListener()method,
even if you omit the [Event] metadata tag."

HTH,

Nate

On Mon, Jan 12, 2009 at 11:07 AM, flexcoder2008 wrote:

>   I have seen numerous examples of registering a dynamicEvent in a
> component's mxml such as:
>
> [Event (name="rowSelected", type="mx.events.DynamicEvent")]
>
> If I have an actionscript class that dispatches a dynamicEvent, what
> is the syntax for this?
>
> I want to dispatch a dynamicEvent from an actionscript class, and I
> want my module to listen for that event.
>
>  
>



-- 

Cheers,
Nate

http://blog.natebeck.net


Re: [flexcoders] Re: ExternalInterface erros

2009-01-12 Thread Ralf Bokelberg
Why do you want to use JSON? You can pass in plain objects instead, e.g.

ExternalInterface.call("someJSMethod", { a: 1, b: { c: true, d: "hello"} } );

Ralf.

On Mon, Jan 12, 2009 at 7:55 PM, flexaustin  wrote:
> I can't really post the code. The issue is either I think is either
> one of two things, but I can't seem to resolve either of them.
>
> #1. I am passing data to a javascript function in json format, which
> contains escaped " & \.
>
> #2. This is the issue.
> http://joshblog.net/2008/01/03/flash-player-externalinterface-variable-name-bug/
> On this one I tried putting my function call in '' to as this blog
> post suggests, but it didn't help.
>
> The JSONENcoder is escaping the " and \ on the flex/actionscript side,
> but when it is getting passed to the javascript file I don't think the
> javascript file is understanding the escaped items. I am not a JS guy
> so I don't know if JS/Broswer knows about escaped characters?
>
> TIA, J
>
> --- In flexcoders@yahoogroups.com, "Anthony DeBonis"  wrote:
>>
>> -What browser are you using - or does it happen in all browsers
>>
>> - Can you get something simple to work like this
>> ExternalInterface.call("alert('TEST')");
>>
>> -Can you post the code?
>>
>
> 


RE: [flexcoders] Re: Release a child .... again

2009-01-12 Thread Gordon Smith
Did I understand correctly that you create child2 dynamically? If so, I would 
use the following pattern in the parent's script:

// Create and add child2:
child2 = new Whatever();
addEventListener(...);
addChild(child2);

---

// Remove child2:
removeEventListener(...);
removeChild(child2);

Gordon Smith
Adobe Flex SDK Team

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of markgoldin_2000
Sent: Friday, January 09, 2009 5:40 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Release a child  again


On its (child2) creationComplete.

--- In flexcoders@yahoogroups.com, Gordon 
Smith  wrote:
>
> When does child2 call parent.addEventListener()?
>
> Gordon Smith
> Adobe Flex SDK Team
>
> From: flexcoders@yahoogroups.com
[mailto:flexcoders@yahoogroups.com] On 
Behalf Of markgoldin_2000
> Sent: Friday, January 09, 2009 7:36 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: Release a child  again
>
>
>  No, child2 adds a listener to its parent - the Container. Child1
> dispatches the event, the event bubbles up, Container handles it,
but
> sees that actual event hanlder is in child2 and lets chuld2 handle
it.
> So, where to remove the listener?
> If I have child2.removeEventListener("remoteDateEvent",
> remoteClickHandler); outide of child2 then I am getting an error
> message:
> 1120: Access of undefined property remoteClickHandler
>
> --- In 
> flexcoders@yahoogroups.com, "Paul Andrews"  wrote:
> >
> > According to your original explanation the only event handler for
> > "remoteDateEvent" is added to the parent container. All the forms
> do is
> > issue events.
> >
> > If you really are doing addEventListener to child2, then
> > child2.removeEventListener("remoteDateEvent", remoteClickHandler);
> >
> > is what you need.
> >
> > removeAllChildren should be done on the parent container.
> >
> > so, first remove handlers, then remove forms.
> >
> > Paul
> >
> >
> >
> >
> >
> > - Original Message -
> > From: "markgoldin_2000" 
> > To: 
> > mailto:flexcoders%40yahoogroups.com>>
> > Sent: Thursday, January 08, 2009 7:54 PM
> > Subject: [flexcoders] Re: Release a child  again
> >
> >
> > >I am not removing the handles at all because I dont know where to
> put
> > > code for that.
> > > I tried (child2)
> > > creationComplete="init();"
> > > ..
> > > private function init():void
> > > {
> > > parent.removeEventListener("remoteDateEvent",
remoteClickHandler);
> > > }
> > > Does not help.
> > >
> > > Children removal is removeAllChildren.
> > >
> > > --- In 
> > > flexcoders@yahoogroups.com, "Paul Andrews"  wrote:
> > >>
> > >> - Original Message -
> > >> From: "markgoldin_2000" 
> > >> To: 
> > >> mailto:flexcoders%40yahoogroups.com>>
> > >> Sent: Thursday, January 08, 2009 7:12 PM
> > >> Subject: [flexcoders] Release a child  again
> > >>
> > >>
> > >> > Still cannot get it work.
> > >> > Here is my scenario:
> > >> >
> > >> > 1. Container adds child1 to itself.
> > >> > 2. Container adds child2 to itself.
> > >> > Child2 adds a custom event listener to parent (Container):
> > >> > parent.addEventListener("remoteDateEvent",
> remoteClickHandler,
> > >> > false, 0, true);
> > >> > 3. Child1 dispatches a custom event:
> > >> > private function executeRun(event:KeyboardEvent):void
> > >> > {
> > >> > if(event.charCode == 13)
> > >> > {
> > >> > var eventObj:remoteDateRun = new remoteDateRun
> ("remoteDateEvent");
> > >> > dispatchEvent(eventObj);
> > >> > }
> > >> > }
> > >> > 4. Child2 handles custom event:
> > >> > public function remoteClickHandler(event:remoteDateRun):void
> > >> > {
> > >> > runDate = event.runDate;
> > >> > dailyJobSumaryList(lineId);
> > >> > }
> > >> > At this point everything works.
> > >> > Now, after some user action both forms are removed form the
> > > Container
> > >> > and all previous steps are repeated.
> > >> > At this point everything still works.
> > >> > Now user is going back to his initial selection. Both forms
are
> > >> > removed again and 3rd set of forms is added to the Container.
> At
> > > this
> > >> > point if a child1 dispatches a custom event then child2 form
> set
> > > #1
> > >> > will get it to handle. Can someone please just put step by
step
> > >> > instruction how to make sure that a form is released and
> > > collected?
> > >> > I have spent days if not more trying to fix the problem.
> > >>
> > >> Be better if you can make a complete example. You say that
child2
> > > handles
> > >> the event, yet you also say you add the event handler to the
> parent
> > >> container, nor do you show any code to remove the han

[flexcoders] Re: Expanding size of panel, and its contained objects.

2009-01-12 Thread aceoohay
Hello?

Is anyone out there?

Any ideas?

Paul

--- In flexcoders@yahoogroups.com, "aceoohay"  wrote:
>
> The systems that I write are traditional data entry types of 
systems. 
> I do everything within panels within modules. I have had users ask 
if 
> they could expand the size of the panel in order to read them better 
> due to poor eyesight, high res monitors and the like.
> 
> Are there any existing panel like components that allow expanding, 
> while making the contained objects larger? 
> 
> Contained objects generally include label, textinput, textarea, 
> combobox, etc... Font sizes would need to be increased, etc.
> 
> Paul
>




Re: [flexcoders] Re: Cairngorm and ChangeWatcher

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

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

Claudiu



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


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

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




  

[flexcoders] Re: How to create universal event handler?

2009-01-12 Thread Dan
> Create a custom event that uses your current event type string as a
> variable. Then your handler can look at the variable value to decide
> what to do.
> 

You mean when I do dispatchEvent, I always use the same type string,
like this?
dispatchEvent(new MyEvent(MyEvent.MY_EVENT)
dispatchEvent(new MyChildEvent(MyEvent.MY_EVENT)
dispatchEvent(new MyFutureChildEvent(MyEvent.MY_EVENT)




[flexcoders] How to register a dynamicEvent in an Actionscript class

2009-01-12 Thread flexcoder2008
I have seen numerous examples of registering a dynamicEvent in a
component's mxml such as:

[Event (name="rowSelected", type="mx.events.DynamicEvent")]

If I have an actionscript class that dispatches a dynamicEvent, what
is the syntax for this?

I want to dispatch a dynamicEvent from an actionscript class, and I
want my module to listen for that event.





Re: [flexcoders] Loading Images Using CSS

2009-01-12 Thread Manish Jethani
On Mon, Jan 12, 2009 at 1:31 AM, Dan Vega  wrote:

> main.mxml
> 
>
> stylesheet
> .logo {
> source: "assets/images/robp/rocketfm_logosmall.png";
> }

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

You have to use ".logo" (as opposed to "logo") in your call to
getStyleDeclaration.

Manish

-- 
http://manishjethani.com


[flexcoders] Re: ExternalInterface erros

2009-01-12 Thread flexaustin
I can't really post the code.  The issue is either I think is either
one of two things, but I can't seem to resolve either of them.

#1. I am passing data to a javascript function in json format, which
contains escaped " & \.

#2. This is the issue. 
http://joshblog.net/2008/01/03/flash-player-externalinterface-variable-name-bug/
 On this one I tried putting my function call in '' to as this blog
post suggests, but it didn't help.

The JSONENcoder is escaping the " and \ on the flex/actionscript side,
but when it is getting passed to the javascript file I don't think the
javascript file is understanding the escaped items.  I am not a JS guy
so I don't know if JS/Broswer knows about escaped characters?


TIA, J

--- In flexcoders@yahoogroups.com, "Anthony DeBonis"  wrote:
>
> -What browser are you using - or does it happen in all browsers
> 
> - Can you get something simple to work like this
> ExternalInterface.call("alert('TEST')");  
> 
> -Can you post the code?
>




Re: [flexcoders] Timer Solution

2009-01-12 Thread Manish Jethani
On Mon, Jan 12, 2009 at 11:09 AM, vinod kumar  wrote:
> I want an urgent help. From metadata information i got the frame rate as 15.
> So between every second i want to display the values 1 to 15 using timer.

You can listen for the enterFrame event and do it there.

Manish


Re: [flexcoders] How to create universal event handler?

2009-01-12 Thread Manish Jethani
On Mon, Jan 12, 2009 at 11:54 PM, Dan  wrote:

> If I do addEventListener(MyEvent.Evt1, handleEvt), I will handle only
> that specific  MyEvent.Evt1 event. I need to be able to handle
> MyEvent.Evt2 and MyChildEvent.Evt1 and my FutureChildEvent.EvtX.
> How can this be achieved?

You have to add a listener for each event type separately.

  obj.addEventListener("foo", commonHandler);
  obj.addEventListener("bar", commonHandler);
  obj.addEventListener("baz", commonHandler);
  ...

There's no shortcut way to listen for all events from an object.

Manish


Re: [flexcoders] Data Grid with dynamic columns ignoring % width or right style.

2009-01-12 Thread Manish Jethani
On Sun, Jan 11, 2009 at 3:51 AM, wesley.acheson
 wrote:

> I've a problem with the DataGrid ignoring the % width, while using
> Canvas as the parent.  When I dynamically create columns it stretches
> to beyond the origional area.  This behaviour has been reported as a
> bug. http://bugs.adobe.com/jira/browse/SDK-14390.  The workarround
> described in the bug setting the width to 0 works for me in a simple
> test case but doesn't appear to work within my main application.

[...]

> I would like to extend datagrid with a version that doesn't have this
> issue if I can figure out why a fixed width doesn't work.

I've left a reply on the bug:

http://bugs.adobe.com/jira/browse/SDK-14390

Basically your DataGrid's minWidth is too large for the Panel. You can
set the minWidth property to reduce it. By default the measured value
for minWidth is always going to be large enough to accommodate all the
columns.

Manish

-- 
http://manishjethani.com


Re: [flexcoders] How to create universal event handler?

2009-01-12 Thread Howard Fore
Create a custom event that uses your current event type string as a
variable. Then your handler can look at the variable value to decide
what to do.

On Mon, Jan 12, 2009 at 1:24 PM, Dan  wrote:
> I have class MyEvent extends flash.events.Event.
> I also have a second class MyEventChild extends MyEvent.
> Both classes define string constants that are used as event type.
>
> How can I add event listener to handle any of MyEvent or MyChildEvent
> events?
>
> If I do addEventListener(MyEvent.Evt1, handleEvt), I will handle only
> that specific  MyEvent.Evt1 event. I need to be able to handle
> MyEvent.Evt2 and MyChildEvent.Evt1 and my FutureChildEvent.EvtX.
> How can this be achieved?




-- 
Howard Fore, howard.f...@hofo.com
"The universe tends toward maximum irony. Don't push it." - Jeff Atwood


[flexcoders] How to create universal event handler?

2009-01-12 Thread Dan
I have class MyEvent extends flash.events.Event.
I also have a second class MyEventChild extends MyEvent.
Both classes define string constants that are used as event type.

How can I add event listener to handle any of MyEvent or MyChildEvent
events?

If I do addEventListener(MyEvent.Evt1, handleEvt), I will handle only
that specific  MyEvent.Evt1 event. I need to be able to handle
MyEvent.Evt2 and MyChildEvent.Evt1 and my FutureChildEvent.EvtX.
How can this be achieved?

Thank you!




[flexcoders] Re: get selected datagrid dynamically

2009-01-12 Thread Jason B
It's funny after i posted i tried that but then it still threw an
error, it wasn't until you posted the same thing i went back and seen
i had a lowercase I in selecteditem instead of selectedItem
:( i need some coffee


--- In flexcoders@yahoogroups.com, "Tracy Spratt"  wrote:
>
> Bracket notation replaces dot notation, so try:
> 
> create_test.text =
> parentApplication.reftables_grid.selectedItem[fieldname];
> 
>  
> 
> Tracy Spratt 
> Lariat Services 
> 
> Flex development bandwidth available 
> 
> 
> 
> From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
> Behalf Of Jason B
> Sent: Monday, January 12, 2009 10:00 AM
> To: flexcoders@yahoogroups.com
> Subject: [flexcoders] Re: get selected datagrid dynamically
> 
>  
> 
> also tried
> 
> create_test.text =
> parentApplication.reftables_grid.selecteditem.this[fieldname];
>




RE: [flexcoders] Re: geting info of a user who has loged in

2009-01-12 Thread Tracy Spratt
We will not write your application for you.  Well I will, at my hourly
rate, contact me off list if you want to hire me.

 

If you want any more help from me you will need to show what you are
doing.

 

To start with, post your login HTTPService declaration code and your
result handler code. 

 

Tracy Spratt 
Lariat Services 

Flex development bandwidth available 



From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
Behalf Of johndoematrix
Sent: Monday, January 12, 2009 4:33 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: geting info of a user who has loged in

 

am sorry for sounding naive and inexperienced, but i am stack. i have
read thru all the solutions suggested but have failed. please can
someone help with a small tutorial on how to do this. i know am asking
for too much but please help. thanks

 



RE: [flexcoders] E4X with RegExp

2009-01-12 Thread Tracy Spratt
Put that logic in a function that returns a Boolean, so you can debug
it.  Then use the function in the e4x expression.

 

Tracy Spratt 
Lariat Services 

Flex development bandwidth available 



From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
Behalf Of plugsymmv
Sent: Monday, January 12, 2009 5:28 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] E4X with RegExp

 

I'm having trouble parsing some XML. 

This works 
var xL0:XMLList=inputXML..node.(/^Gear[0-9]{2}W$/.(test(@name)));

This is apparently should work with a compiler warning

public static const GEARDEF1:RegExp=new RegExp("/^Gear[0-9]{2}$/","i");
var xL2:XMLList=inputXML..node.(GEARDEF1.test(@name));

and using square bracketing like this should work and stop the warnings.
public static const GEARDEF1:RegExp=new RegExp("/^Gear[0-9]{2}$/","i");
var xL2:XMLList=inputXML..node.(GEARDEF1["test"](@name));

Trouble is neither of the two methods using RegExp work - which if it
were that simple wouldn't matter. The reason for this is that I need
to build arrays of RegExs to loop over like this.
public static const GEARDEF1:RegExp=new RegExp("/^Gear[0-9]{2}$/","i");
public static const GEARDEF2:RegExp=new RegExp("/^Gear[0-9]{2}W$/");
public static const GEARDEF3:RegExp=new RegExp("/^Gear[0-9]{2}01Loc$/");
public static var geardefs:Array =[GEARDEF1, GEARDEF2, GEARDEF3];

Any suggestions as to why this doesn't work?

 



RE: [flexcoders] Re: get selected datagrid dynamically

2009-01-12 Thread Tracy Spratt
Bracket notation replaces dot notation, so try:

create_test.text =
parentApplication.reftables_grid.selectedItem[fieldname];

 

Tracy Spratt 
Lariat Services 

Flex development bandwidth available 



From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On
Behalf Of Jason B
Sent: Monday, January 12, 2009 10:00 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: get selected datagrid dynamically

 

also tried

create_test.text =
parentApplication.reftables_grid.selecteditem.this[fieldname];

 



Re: [flexcoders] Re: Using dispatchEvent ?

2009-01-12 Thread Manish Jethani
On Mon, Jan 12, 2009 at 8:59 PM, biosmonkey  wrote:

> The dispatched event needs to be heard by any component, anywhere, by
> setting an event listener for it at the application level.  So
> bubbling up to the app is critical.

Since your component has nothing to do with UI, strictly speaking,
making it a UI component (extending DisplayObject) seems like the
wrong thing to do. Event bubbling is typically for UI events; your
event is not a UI event, it's just that you need it to be broadcast
application-wide.

So I would consider making the event dispatcher object available
application-wide, by making it a singleton, for instance, or by making
it a property of the main application. It seems you're already doing
something to that effect -- dispatching off the main application
object.

Manish


Re: [flexcoders] DataGrid selectAll problem

2009-01-12 Thread Glenn Jones
I've tried setting just selectedIndices - same result

In my CheckBoxDataGrid.selectAll() method, I tried calling
invalidateProperties/invalidateList/validateNow - same result.

In my CheckBoxHeaderRenderer.clickHandler, I tried using callLater to
execute CheckBoxDataGrid.selectAll() - same result.

I repeated the callLater test after removing
invalidateProperties/invalidateList/validateNow - same result.

Any suggestions on which operations I should use for callLater()?

As a workaround, I added an event listener for itemEditBeginning on the
checkboxdatagrid. If the selected item count was > 1,
then I called event.preventDefault().  This actually triggers a crash
sometime later in mx:DataGrid (line 3889 - itemEditorInstance is null).



On Mon, Jan 12, 2009 at 10:07 AM, Alex Harui  wrote:

>I would not set  both selectedItems and selectedIndices.  Probably just
> selectedIndices because it should be faster.
>
>
>
> I don't think selectItem will be called if the item is already selected.
> Due to the way invalidation works, maybe it hasn't been de-selected yet.
> Sometimes, callLater can help in these situations.
>
>
>
> *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On
> Behalf Of *Glenn Jones
> *Sent:* Saturday, January 10, 2009 4:52 PM
> *To:* flexcoders@yahoogroups.com
> *Subject:* Re: [flexcoders] DataGrid selectAll problem
>
>
>
> I started with the example from your blog dated Feb 2008
> (CheckBoxListAndDataGrid).
>
> To deselect the other rows, the checkbox column header renderer calls a
> 'selectAll()' method on the CheckBoxDataGrid
> with  a flag of false.  That method builds two arrays - one for all items
> in the collection and one for all indices in the collection.
> It then replaces mx:DataGrid.selectedItems and selectedIndices with new
> arrays. In the deselect case, the new arrays are empty.
> In the select all case then have all items/indices.
>
> Visually, selectAll true/false seems to work when it's called. But in the
> use-case I describe below I'm counting on the
> mx:DataGrid.selectItem() to be called in order to deselect rows in the case
> that a single row is selected.
> Based on trace statements, I know that mx:DataGrid.selectItem() is never
> called when the problem occurs
>
> Is there something about the way I'm selecting things which causes the
> selectItem() to not be called?
>
> I tried replacing just selectedItemds or just selectedIndicies or both. it
> doesn't seem.
>
> Thanks,
> Glenn
>
> On Fri, Jan 9, 2009 at 1:11 AM, Alex Harui  wrote:
>
> Which example did you start with?  Which event do you use to deselect the
> other rows, and what does that code look like?
>
>
>
> *From:* flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] *On
> Behalf Of *Glenn Jones
> *Sent:* Thursday, January 08, 2009 9:49 PM
> *To:* flexcoders@yahoogroups.com
> *Subject:* [flexcoders] DataGrid selectAll problem
>
>
>
> Hi,
>
> I'm using Flex 3.2 and I have a DataGrid which implements a column of
> checkboxes to select rows.  I started with Alex' example.
> Then I added a header renderer on the checkbox column such that if check
> the header, then all rows are selected.
> To implement the select all behavior, I'm creating an array of indices for
> [0..n] and assigning that array to mx:DataGrid.selectedIndices.
>
> For the most part this works fine.
>
> But if the DataGrid is editable, then I sometimes have a problem. The
> problem is that if all rows are selected, and you click on
> an editable cell, sometimes the cell becomes editable without deselecting
> all of the other rows. The behavior I want is that
> if you start editing a cell, then just that row becomes selected. This
> happens some of time, but not all of the time.
>
> If the grid is non-editable, then I can't reproduce the problem.
>
> I overrode mx:DataGrid.selectItem() in order to clear the checkbox in the
> header renderer any time a single item is selected.  I've
> noticed that when the problem behavior occurs, the mx:DataGrid.selectItem()
> method is never called.
>
> It's almost like there's some race condition between selecting an item and
> starting a cell edit.
>
> Any ideas on how I could work around this?
>
> Thanks,
> Glenn
>
>
>
>   
>


Re: [flexcoders] Tweening VBox or List IndexChangedEvent

2009-01-12 Thread Manish Jethani
On Mon, Jan 12, 2009 at 10:03 PM, kylewburke  wrote:
> I've implemented a ButtonSkin for CheckBox.  I have several of them in
> a VBox.  I'm trying to tween during the IndexChangedEvent via the
> childIndexChange event, to move the selected CheckBox up to the top.

Well, actually, you can just set moveEffect on the individual children.

e.g.


http://www.adobe.com/2006/mxml";
  xmlns="*" >
  
function doThing() {
vb.setChildIndex(vb.getChildAt(0), 3);
}
  

  

  




  


Manish

-- 
http://manishjethani.com


[flexcoders] Re: ExternalInterface erros

2009-01-12 Thread Anthony DeBonis
-What browser are you using - or does it happen in all browsers

- Can you get something simple to work like this
ExternalInterface.call("alert('TEST')");

-Can you post the code?



[flexcoders] Tweening VBox or List IndexChangedEvent

2009-01-12 Thread kylewburke
I've implemented a ButtonSkin for CheckBox.  I have several of them in
a VBox.  I'm trying to tween during the IndexChangedEvent via the
childIndexChange event, to move the selected CheckBox up to the top.

I'm wondering if VBox is the right way to go or is a subclass of List
better?  

Also not sure if childIndexChange is the right way to go, since the AS
doc says:

Dispatched *after* the index of a container child changes

Thanks for any suggestions.

Kyle



[flexcoders] Re: Styling Alert box default button

2009-01-12 Thread Jason B
--- In flexcoders@yahoogroups.com, "achegedus"  wrote:
>
> I have a custom styled alert box with two buttons (ok and cancel), I'm
> trying to make the default button look slightly different, but I can't
> figure out how to do this.  Does anyone know?  The default style can
> achieve this.
>

have you looked at 
http://mfolio.wordpress.com/2008/06/07/flex-custom-popup-and-alert-box/




[flexcoders] Re: Using dispatchEvent ?

2009-01-12 Thread biosmonkey
I see.

I think the part I was missing was the fact that the class object
needed to be a child of the application to be in its display list,
instead of instantiated to a variable.

I could convert my class to a component I suppose, and place it in my
MXML but frankly I don't mind dispatching from mx..application.

I just needed to understand why I had to do it that way.

Thanks


--- In flexcoders@yahoogroups.com, "Sam Lai"  wrote:
>
> The event listener attached to the Application is not reacting to the
> event fired from your custom class because your custom class instance
> is not attached to the Application DisplayList. It is just an object
> in memory. If you want the event from your custom class instance to
> bubble up to the Application, you need to add it to the Application's
> DisplayList.
> 
> The DisplayList is typically used for UI components, i.e. when you
> click a button in the UI, it fires an event and that event propagates
> up the display list.
> 
> However, you can add non-UI components to it too. Your custom class
> just needs to extend the DisplayObject class (I think - it should have
> extended EventDispatcher already). You also need to add the instance
> to the Application object by using the addChild method on the
> Application object, e.g. application.addChild(myclass);
> 
> If you declare the custom class instance in MXML, it is automatically
> added to the Application object (well, technically, only if it is a
> loaded component in the UI).
> 
> 
> 
> 2009/1/12 biosmonkey :
> >
> > The dispatched event needs to be heard by any component, anywhere, by
> > setting an event listener for it at the application level.  So
> > bubbling up to the app is critical.
> >
> >
> > --- In flexcoders@yahoogroups.com, "Manish Jethani"
> >  wrote:
> >>
> >> On Mon, Jan 12, 2009 at 11:42 AM, biosmonkey  wrote:
> >>
> >> > In my main app, I instantiate an instance of this class.  I also
> >> > create an event listener at the application level.
> >> >
> >> > Here's the problem:
> >> >
> >> > * If I use dispatchEvent(...) inside MyClass, the event listener in
> >> > the main app never fires (the custom event *is* set to bubble)
> >>
> >> To add to Josh's response, I would say the best way to do this is to
> >> listen on the object itself.
> >>
> >> obj = new MyClass();
> >> obj.addEventListener(...);
> >>
> >> The events don't have to be bubbling then.
> >>
> >> Manish
> >>
> >
> >
> >
> > 
> >
> > --
> > 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
> >
> >
> >
> >
>




RE: [flexcoders] Error: Access of undefined property

2009-01-12 Thread Alex Harui
Change the class name, maybe it is colliding with mx.utils.StringUtils

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of freak182
Sent: Saturday, January 10, 2009 6:14 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Error: Access of undefined property


Hello,

It just kinda weird that i encounter and here is the cscenario:

I create a StringUtils.as;

package com.buspinoy.utils
{

public class StringUtils
{
public static function isEmpty(str:String):Boolean
{
return str == null || str.length == 0;
}

public static function isNotEmpty(str:String):Boolean
{
return !StringUtils.isEmpty(str);
}

public function StringUtils()
{
}

}
}

...this is based on org.apache.commons.lang, but when i put in a code like
this:

if (StringUtils.isEmpty(selectedText) )
{
comboCursor.findFirst(selectedText);
this.selectedItem = comboCursor.current;
}
...it gives me error Access of undefined property...any idea what is
happening?because i have static function working properly but not inside the
"if" condition.

btw, quick question, does AS will support method overloading in the future?

Thanks a lot.
Cheers.
--
View this message in context: 
http://www.nabble.com/Error%3A-Access-of-undefined-property-tp21388507p21388507.html
Sent from the FlexCoders mailing list archive at Nabble.com.



RE: [flexcoders] Re: Make Enter work as Tab in Flex DataGrid

2009-01-12 Thread Alex Harui
DataGrid disables focusmanager when passing tab through the cells.  You could 
override DG, trap the keyDown for ENTER, call stopImmediatePropagation so the 
DG doesn't see it, and dispatch a fake keyFocusChange event instead

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Sergey Snovsky
Sent: Saturday, January 10, 2009 7:14 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Make Enter work as Tab in Flex DataGrid


Any ideas, please?

--- In flexcoders@yahoogroups.com, "Sergey 
Snovsky" 
wrote:
>
> Hello!
>
> I'm trying to make Enter work the same as Tab in a DataGrid - commit
> changes to the edited cell and move focus to the next one to the
> right, then next row, etc.
>
> I've tried to use something like:
>
> focusManager.getNextFocusManagerComponent(true).setFocus();
>
> or
>
> focusManager.moveFocus(FocusRequestDirection.FORWARD);
>
> but I cannot seem to make it work in a DataGrid...
>
> Any help would be much appreciated!
>
> Thank you!
>
> Sergey
>



[flexcoders] Re: recompiling framework shared library?

2009-01-12 Thread Darrell Loverin
The reason you are having a problem is because of the "first in wins" 
rule that applies to loading classes. Your monkey patched VideoPlayer 
class is in your swf file, but in frame 2. The framework swz file is 
loaded in frame 1, so its definition of VideoPlayer wins.  The way to 
work around this is to create your own RSL with just your VideoPlayer 
class and its dependencies. Load this new RSL before the signed 
framework RSL and your definition of the VideoPlayer will win.

Note: the new RSL can be large in some cases, depending on the size of 
the classes the monkey patched file is dependent on.


-Darrell


--- In flexcoders@yahoogroups.com, "luvfotography"  wrote:
>
> Hi, I've made a change to mx.controls.videoClasses.VideoPlayer.as and
> placed it in my 'src' folder under the folders 'mx', then 'controls',
> then 'videoClasses' and it picks up the change no problem.
> 
> If I then change my project to use 'runtime shared library' it's not
> picking up my changes.
> 
> What do I need to do?  
> do i need to recompile the framework_3.0.0.477.swz somehow?
> thanks,
>




RE: [flexcoders] DataGrid selectAll problem

2009-01-12 Thread Alex Harui
I would not set  both selectedItems and selectedIndices.  Probably just 
selectedIndices because it should be faster.

I don't think selectItem will be called if the item is already selected.  Due 
to the way invalidation works, maybe it hasn't been de-selected yet.  
Sometimes, callLater can help in these situations.

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Glenn Jones
Sent: Saturday, January 10, 2009 4:52 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] DataGrid selectAll problem


I started with the example from your blog dated Feb 2008 
(CheckBoxListAndDataGrid).

To deselect the other rows, the checkbox column header renderer calls a 
'selectAll()' method on the CheckBoxDataGrid
with  a flag of false.  That method builds two arrays - one for all items in 
the collection and one for all indices in the collection.
It then replaces mx:DataGrid.selectedItems and selectedIndices with new arrays. 
In the deselect case, the new arrays are empty.
In the select all case then have all items/indices.

Visually, selectAll true/false seems to work when it's called. But in the 
use-case I describe below I'm counting on the
mx:DataGrid.selectItem() to be called in order to deselect rows in the case 
that a single row is selected.
Based on trace statements, I know that mx:DataGrid.selectItem() is never called 
when the problem occurs

Is there something about the way I'm selecting things which causes the 
selectItem() to not be called?

I tried replacing just selectedItemds or just selectedIndicies or both. it 
doesn't seem.

Thanks,
Glenn
On Fri, Jan 9, 2009 at 1:11 AM, Alex Harui 
mailto:aha...@adobe.com>> wrote:

Which example did you start with?  Which event do you use to deselect the other 
rows, and what does that code look like?



From: flexcoders@yahoogroups.com 
[mailto:flexcoders@yahoogroups.com] On 
Behalf Of Glenn Jones
Sent: Thursday, January 08, 2009 9:49 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] DataGrid selectAll problem



Hi,

I'm using Flex 3.2 and I have a DataGrid which implements a column of 
checkboxes to select rows.  I started with Alex' example.
Then I added a header renderer on the checkbox column such that if check the 
header, then all rows are selected.
To implement the select all behavior, I'm creating an array of indices for 
[0..n] and assigning that array to mx:DataGrid.selectedIndices.

For the most part this works fine.

But if the DataGrid is editable, then I sometimes have a problem. The problem 
is that if all rows are selected, and you click on
an editable cell, sometimes the cell becomes editable without deselecting all 
of the other rows. The behavior I want is that
if you start editing a cell, then just that row becomes selected. This happens 
some of time, but not all of the time.

If the grid is non-editable, then I can't reproduce the problem.

I overrode mx:DataGrid.selectItem() in order to clear the checkbox in the 
header renderer any time a single item is selected.  I've
noticed that when the problem behavior occurs, the mx:DataGrid.selectItem() 
method is never called.

It's almost like there's some race condition between selecting an item and 
starting a cell edit.

Any ideas on how I could work around this?

Thanks,
Glenn




RE: [flexcoders] Re: Wierd error 1067 on extended DefaultDataDescriptor

2009-01-12 Thread Alex Harui
Worthy of a bug if you have the time.  I agree it is inconsistent

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Amy
Sent: Sunday, January 11, 2009 5:47 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Wierd error 1067 on extended DefaultDataDescriptor


--- In flexcoders@yahoogroups.com, Alex 
Harui  wrote:
>
> You have to assign an instance of your class, not the class itself

Yes, I ultimately figured that out. Thanks :-). I was expecting it to
work like itemRenderers or something.



RE: [flexcoders] VO and LabelField Problem

2009-01-12 Thread Alex Harui
What happens when you use labelField=”courseName”?

From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf 
Of Berkay Unal
Sent: Sunday, January 11, 2009 9:24 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] VO and LabelField Problem


Hi,

When trying have dataprovider for a list control using remoting with VO i 
cannot set the label of the control with the labelField = "courseName".

How to achieve this, guess i am missing smthing. Any help appreciated much

result   Array (@1a522159)

[0]com.abc.courseList.VO.CourseVO (@1ee40449)
courseID 1
courseName"Course1"
[1]com.abc.courseList.VO.CourseVO (@1ee404c1)
courseID 2
courseName"Course2"
[2]com.abc.courseList.VO.CourseVO (@1ee40719)
courseID 3
courseName"Course3"
length  3

Best
Bunal




[flexcoders] ExternalInterface erros

2009-01-12 Thread flexaustin
Anyone know why I am getting this error when making an
externalinterface call?

missing ) after argument list
[Break on this error] try { __flash__toXML(Glide.onSelect(43,4...
YOU $ 'FBar'\",\"connection\":0



[flexcoders] Browser and embeded Flex scrolling together

2009-01-12 Thread bffoley
Currently I'm working on a Flex app for a client that has a VBox with
a vertical scrollbar on it.  Inside of the VBox is a long list of
custom components (based on HBox) that can be viewed by scrolling up
and down on the scrollbar.  The issue is this application is embeded
within a HTML page that has a lot of content below the application,
therefore when the user scrolls the mousewheel on my VBox, it scrolls
the main page as well.  I've noticed that most components do this as
well, with the exception being TextArea.  I've dug around the livedocs
and some forums in hope of finding a solution to make this work, but
 so far nothing.  I was wondering if perhaps anyone has come
across this issue and know a solution or a workaround, or have
suggestions on how I could better accomplish what I need to do here?



Re: [flexcoders] How to remove labels from a chart with ActionScript

2009-01-12 Thread Julien BALMONT
And FYI, the Axis Renderer was defined explicitly.

Thanks again

On Mon, Jan 12, 2009 at 4:57 PM, Julien BALMONT  wrote:

> You're a chief!!!
> I had forgotten the [0] ;(
>
> Thanks for your help, now it works
>
> Julien
>
>
> On Mon, Jan 12, 2009 at 4:54 PM, Sam Lai  wrote:
>
>>
>> AxisRenderer(myBarChart.horizontalAxisRenderers[0]).setStyle("showLabels",
>> false);
>>
>> should work. How have you defined your chart in MXML? Did you
>> explicitly define a horizontal axis renderer, or are you using the
>> internal one? Maybe try defining one explicitly, and that way you can
>> set an ID and refer to it directly.
>>
>> 2009/1/12 Julien BALMONT 
>> 
>> >:
>>
>> > Hello,
>> >
>> > i'm trying to remove the labels from the horizontal axis of a column
>> chart
>> > (and a line chart) when clicking on a button (and also add it if
>> removed).
>> > For this, i have to use ActionScript, but i'm unable to find the correct
>> > syntax and Object.
>> >
>> > Can anyone help me?
>> >
>> > I've tried myBarChart.styleName = "noAxisStyle"; (with a noAxisStyle
>> class
>> > defined with .noAxisStyle
>> > {
>> > showLabels: false;
>> > }
>> > but it doesn't work.
>> >
>> > I also tried myBarChart.setStyle("showLabels", true); but it diesn't
>> work.
>> >
>> > Finally I tried
>> > AxisRenderer(myBarChart.horizontalAxisRenderers).setStyle("showLabels",
>> > false); but it doesn't work.
>> >
>> > No other idea.
>> >
>> > Thanks!
>> >
>> >
>> >
>>  
>>
>
>
>
> --
> Julien Balmont
> Project Manager
> Tel:  +331 41 92 28 73
> Mobile: +336 32 65 17 60
>
> Echovox France
> 107 Avenue Charles de Gaulle
> 92200 Neuilly-Sur-Seine
> France
>



-- 
Julien Balmont
Project Manager
Tel:  +331 41 92 28 73
Mobile: +336 32 65 17 60

Echovox France
107 Avenue Charles de Gaulle
92200 Neuilly-Sur-Seine
France


Re: [flexcoders] How to remove labels from a chart with ActionScript

2009-01-12 Thread Julien BALMONT
You're a chief!!!
I had forgotten the [0] ;(

Thanks for your help, now it works

Julien

On Mon, Jan 12, 2009 at 4:54 PM, Sam Lai  wrote:

>
> AxisRenderer(myBarChart.horizontalAxisRenderers[0]).setStyle("showLabels",
> false);
>
> should work. How have you defined your chart in MXML? Did you
> explicitly define a horizontal axis renderer, or are you using the
> internal one? Maybe try defining one explicitly, and that way you can
> set an ID and refer to it directly.
>
> 2009/1/12 Julien BALMONT 
> 
> >:
>
> > Hello,
> >
> > i'm trying to remove the labels from the horizontal axis of a column
> chart
> > (and a line chart) when clicking on a button (and also add it if
> removed).
> > For this, i have to use ActionScript, but i'm unable to find the correct
> > syntax and Object.
> >
> > Can anyone help me?
> >
> > I've tried myBarChart.styleName = "noAxisStyle"; (with a noAxisStyle
> class
> > defined with .noAxisStyle
> > {
> > showLabels: false;
> > }
> > but it doesn't work.
> >
> > I also tried myBarChart.setStyle("showLabels", true); but it diesn't
> work.
> >
> > Finally I tried
> > AxisRenderer(myBarChart.horizontalAxisRenderers).setStyle("showLabels",
> > false); but it doesn't work.
> >
> > No other idea.
> >
> > Thanks!
> >
> >
> >
>  
>



-- 
Julien Balmont
Project Manager
Tel:  +331 41 92 28 73
Mobile: +336 32 65 17 60

Echovox France
107 Avenue Charles de Gaulle
92200 Neuilly-Sur-Seine
France


Re: [flexcoders] How to remove labels from a chart with ActionScript

2009-01-12 Thread Sam Lai
AxisRenderer(myBarChart.horizontalAxisRenderers[0]).setStyle("showLabels",
false);

should work. How have you defined your chart in MXML? Did you
explicitly define a horizontal axis renderer, or are you using the
internal one? Maybe try defining one explicitly, and that way you can
set an ID and refer to it directly.

2009/1/12 Julien BALMONT :
> Hello,
>
> i'm trying to remove the labels from the horizontal axis of a column chart
> (and a line chart) when clicking on a button (and also add it if removed).
> For this, i have to use ActionScript, but i'm unable to find the correct
> syntax and Object.
>
> Can anyone help me?
>
> I've tried myBarChart.styleName = "noAxisStyle"; (with a noAxisStyle class
> defined with .noAxisStyle
> {
> showLabels: false;
> }
> but it doesn't work.
>
> I also tried myBarChart.setStyle("showLabels", true); but it diesn't work.
>
> Finally I tried
> AxisRenderer(myBarChart.horizontalAxisRenderers).setStyle("showLabels",
> false); but it doesn't work.
>
> No other idea.
>
> Thanks!
>
>
> 


[flexcoders] Re: Flash Remoting Options

2009-01-12 Thread Amy
--- In flexcoders@yahoogroups.com, Alan K  wrote:
>
> Resonably - there are no options regarding AMFPHP.
> 
> PHP 4 is really old.  Your host should offer an upgrade to at  least  
> PHP 5.

I think it has to do with the framework they use to provide PHP on 
Windows accounts.  I'm thinking maybe I pushed the account beyond what 
they intended it to do, so I can't really complain much.

I've had someone offer me a free account to host this example, so it 
might be going online soon anyway :-).

Thanks;

Amy



[flexcoders] Re: CategoryAxis category order

2009-01-12 Thread Amy
--- In flexcoders@yahoogroups.com, "Maciek Sakrejda"  
wrote:
>
> Ok, so it looks like a (reasonably simple) way to do this is to set 
the dataProvider of the CategoryAxis to originalDataProvider.toArray
().reverse() on every update of originalDataProvider. A 
ListCollectionView to wrap originalDataProvider would have been 
cleaner, but there doesn't seem to be a simple way to say "sort the 
opposite of how this is sorted by default". I tried to extend 
ListCollectionView into a ReverseListCollectionView by overriding 
getItemAt() and itemIndex(), but it looks like CategoryAxis actually 
uses IViewCursor, and I would have had to write my own. I think this 
solution works reasonably well for now.

This might noy be "by default", but had you seen this thread:
http://tech.groups.yahoo.com/group/flexcoders/message/121765 ?

You might be able to just create a sort like that and set it to be 
the default sort of your ListCollectionView.

HTH;

Amy



Re: [flexcoders] Re: Using dispatchEvent ?

2009-01-12 Thread Sam Lai
The event listener attached to the Application is not reacting to the
event fired from your custom class because your custom class instance
is not attached to the Application DisplayList. It is just an object
in memory. If you want the event from your custom class instance to
bubble up to the Application, you need to add it to the Application's
DisplayList.

The DisplayList is typically used for UI components, i.e. when you
click a button in the UI, it fires an event and that event propagates
up the display list.

However, you can add non-UI components to it too. Your custom class
just needs to extend the DisplayObject class (I think - it should have
extended EventDispatcher already). You also need to add the instance
to the Application object by using the addChild method on the
Application object, e.g. application.addChild(myclass);

If you declare the custom class instance in MXML, it is automatically
added to the Application object (well, technically, only if it is a
loaded component in the UI).



2009/1/12 biosmonkey :
>
> The dispatched event needs to be heard by any component, anywhere, by
> setting an event listener for it at the application level.  So
> bubbling up to the app is critical.
>
>
> --- In flexcoders@yahoogroups.com, "Manish Jethani"
>  wrote:
>>
>> On Mon, Jan 12, 2009 at 11:42 AM, biosmonkey  wrote:
>>
>> > In my main app, I instantiate an instance of this class.  I also
>> > create an event listener at the application level.
>> >
>> > Here's the problem:
>> >
>> > * If I use dispatchEvent(...) inside MyClass, the event listener in
>> > the main app never fires (the custom event *is* set to bubble)
>>
>> To add to Josh's response, I would say the best way to do this is to
>> listen on the object itself.
>>
>> obj = new MyClass();
>> obj.addEventListener(...);
>>
>> The events don't have to be bubbling then.
>>
>> Manish
>>
>
>
>
> 
>
> --
> 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
>
>
>
>


[flexcoders] Re: Styling Alert box default button

2009-01-12 Thread valdhor
Checkout graphical skinning. A couple of places to start:

http://livedocs.adobe.com/flex/3/html/help.html?content=skinning_4.html
http://userflex.wordpress.com/2008/03/13/button-image-skinning/


--- In flexcoders@yahoogroups.com, "achegedus"  wrote:
>
> I have a custom styled alert box with two buttons (ok and cancel), I'm
> trying to make the default button look slightly different, but I can't
> figure out how to do this.  Does anyone know?  The default style can
> achieve this.
>




[flexcoders] Re: Using dispatchEvent ?

2009-01-12 Thread biosmonkey

The dispatched event needs to be heard by any component, anywhere, by
setting an event listener for it at the application level.  So
bubbling up to the app is critical. 


--- In flexcoders@yahoogroups.com, "Manish Jethani"
 wrote:
>
> On Mon, Jan 12, 2009 at 11:42 AM, biosmonkey  wrote:
> 
> > In my main app, I instantiate an instance of this class.  I also
> > create an event listener at the application level.
> >
> > Here's the problem:
> >
> > * If I use dispatchEvent(...) inside MyClass, the event listener in
> > the main app never fires (the custom event *is* set to bubble)
> 
> To add to Josh's response, I would say the best way to do this is to
> listen on the object itself.
> 
> obj = new MyClass();
> obj.addEventListener(...);
> 
> The events don't have to be bubbling then.
> 
> Manish
>




[flexcoders] Re: Using dispatchEvent ?

2009-01-12 Thread biosmonkey
Actually, I did think about that and tried changing from
EventDispatcher to extending UIComponent but it still does not work. I
even tried Canvas and it still does not catch it.

As an experiment, though, I tried dispatching the same event from one
of my components elsewhere in the application just to make sure the
custom event itself was OK, and that worked.

Does it make a difference that I am dispatching this event from inside
an HTTPService callback? Basically, the way this class works is that I
instantiate it with a timer value, and every x seconds it makes a call
to the server to get some data, and based on the result of that data I
dispatch an event with the payload.




--- In flexcoders@yahoogroups.com, "Josh McDonald"  wrote:
>
> Event bubbling only occurs within the display list. So your dispatching
> object must also be a child UIComponent if you want to catch bubbled
events.
> 
> -Josh
> 
> On Mon, Jan 12, 2009 at 4:12 PM, biosmonkey  wrote:
> 
> > I thought I had understood the event model, but apparently not.
> >
> > I have a custom class that extends EventDispatcher, let's call it
> > MyClass.  This class will periodically dispatch a custom event based
> > on a timer and some condition.
> >
> > In my main app, I instantiate an instance of this class.  I also
> > create an event listener at the application level.
> >
> > Here's the problem:
> >
> > * If I use dispatchEvent(...) inside MyClass, the event listener in
> > the main app never fires (the custom event *is* set to bubble)
> >
> > * The only way it will work is if I use the application object, ie
> > mx.core.Application.application.dispatchEvent(...)
> >
> > But I don't understand why I have to do this? I have used a similar
> > model just fine when dispatching events from inside components (ie I
> > use dispatchEvent and my custom event is heard at the app level via
> > bubbling).
> >
> > Can someone help me understand this?
> >
> >
> > 
> >
> > --
> > 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] Re: get selected datagrid dynamically

2009-01-12 Thread Jason B
also tried

create_test.text =
parentApplication.reftables_grid.selecteditem.this[fieldname];



[flexcoders] Lazy Loading Tree example posted

2009-01-12 Thread Amy
Several people on here have asked for example code for lazy loading 
data intended for a Tree component.  I've posted the example here:

http://flexdiary.blogspot.com/2009/01/lazy-loading-tree-example-file-
posted.html

Hope this helps someone :-)

-Amy



[flexcoders] Re: Flash Remoting Options

2009-01-12 Thread valdhor
A shot in the dark: WebORB for .NET


--- In flexcoders@yahoogroups.com, "Amy"  wrote:
>
> Hi, all;
> 
> I built a great little example file using AMFPHP.  It works great on my 
> local installation of WampServer, but when I uploaded it to my web 
> host, the Service Browser for AMFPHP wouldn't work.  I contacted my 
> host, and they said that was because my hosting is Windows (which I did 
> on purpose so I could play with ASP).  They use ASAPI or CGI to handle 
> the PHP part.
> 
> I don't want to change to a Linux account just over this one example 
> file.  Are there remoting options that can work on my existing hosting 
> plan?
> 
> Thanks;
> 
> Amy
>




[flexcoders] get selected datagrid dynamically

2009-01-12 Thread Jason B
Im trying to get the selected item value from the parent app but i
cannot seem to put the name as a variable?

var fieldname:String = columnData.field;

create_text = new TextInput();
 create_text.percentWidth = 80;
 create_text.id = "inputtext" + counter;

//***THIS LINE IS THE ISSUE
create_test.text =
parentApplication.reftables_grid.selecteditem.[fieldname];

I can alert the fieldname fine showing the data grid's field name but
i need to use it as a variable to get the selected items value from
the grid



Re: [flexcoders] Using dispatchEvent ?

2009-01-12 Thread Manish Jethani
On Mon, Jan 12, 2009 at 11:42 AM, biosmonkey  wrote:

> In my main app, I instantiate an instance of this class.  I also
> create an event listener at the application level.
>
> Here's the problem:
>
> * If I use dispatchEvent(...) inside MyClass, the event listener in
> the main app never fires (the custom event *is* set to bubble)

To add to Josh's response, I would say the best way to do this is to
listen on the object itself.

obj = new MyClass();
obj.addEventListener(...);

The events don't have to be bubbling then.

Manish


Re: [flexcoders] Multiple selection in dataGrid by dragging Mouse with left mouse key

2009-01-12 Thread Manish Jethani
On Sat, Jan 10, 2009 at 11:55 PM, Dharmendra Chauhan
 wrote:
>  Is it possible to select multiple rows in data grid by just
> dragging mouse over It. I know this can we achieved with combination
> of sift key and mouse.

[...]

> Please let me know whether it is possible  in flex or not  and if it
> is possible then please provide me some pointers.

I think you (or someone else) asked this one before and didn't get an
answer. This is possible but non-trivial. You can extend the DataGrid
to override the mouse handling and update the selection accordingly.
The pointer I can give you is the DataGrid source code itself -- look
into that.

Manish

-- 
http://manishjethani.com


[flexcoders] Re: Namespace declaration problem

2009-01-12 Thread valdhor
It is not uncommon for someone to code something that requires someone
else's code but they can't (or won't) include that code because they
don't want to go through any licensing. They should have told you that
it was required and where to go and get it. Was there ANY
documentation to that effect?


--- In flexcoders@yahoogroups.com, "brucewhealton"  wrote:
>
> I thought, when I first read this, that you were saying that it is a
> part of a normal flex installation.  The author of the text said that
> I need to download and install the auto-complete edit field component
> into my libs directory.  I wonder if that means just for this project
> or the libs directory for my Flex installation.
> 
> I don't understand why, if a 3rd party package or set of components is
> required, they were not included with the rest of the content that
> comes with the text.  It almost sounded like I should have somehow
> known to locate and install this auto-complete component and that I
> should have known how to install it into this project.  Is it just me,
> or is it strange to think that the reader of this text would have
> known to do this without even mentioning anything about needing this
> extra component, how to get it and how to install it or install it for
> this project?
> 
> So, yes, I did follow package notation, even before I asked this
> question.  I mean the explanation of it was helpful to refresh my
> memory as to how it works.  Then it just left me thinking something is
> seriously missing that I need.  Please let me know what you think... 
> Shouldn't a writer at least mention that one is going to need to
> install this component into this package?  
> Thanks,
> Bruce
> 
> --- In flexcoders@yahoogroups.com, Gordon Smith  wrote:
> >
> > It sounds like you don't have the SWC with the
> comc.adobe.flex.extras.controls.* classes (which are not part of a
> standard Flex installation) or it isn't on your library-path.
> > 
> > Gordon Smith
> > Adobe Flex SDK Team
> > 
> > From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com]
> On Behalf Of brucewhealton
> > Sent: Thursday, January 08, 2009 6:25 PM
> > To: flexcoders@yahoogroups.com
> > Subject: [flexcoders] Namespace declaration problem
> > 
> > 
> > Hello all,
> > I have this code that I copied from a text book on Flex. I'm
> > aware of package notation but I'm not sure how this works in this
> > example and what is going wrong. In the code, I have within the
> > Application tag, a namespace definition. So, the Application tag
> > opens like this:
> > http://www.adobe.com/2006/mxml";
> > layout="vertical"
> > xmlns:ec="com.adobe.flex.extras.controls.*">
> > 
> > I'm cutting out what is not relevant to the problem. The problem is
> > that this tag is not recognized by Flex 3, it gives a compile time
> error:
> > 
> > I guess I need to figure out what is inside the controls package that
> > is named above in the Application.
> > The error I get on that line is
> > 1046: Type was not found or was not a Compile time constant:
> AutoComplete.
> > How might I figure this out? The text where I found this does not
> > elaborate on this particular code. It is an example of coding that is
> > a little different then what I am familiar with.
> > 
> > Can anyone help me make sense of this, please?
> > Bruce
> >
>




  1   2   >