[flexcoders] Re: Embedded fonts in DataGrid

2008-03-31 Thread Bjorn Schultheiss
I also thought i'd add i've added 

import mx.controls.dataGridClasses.DataGridItemRenderer;

private var dgir:DataGridItemRenderer; 

to my main application, and my css is inside a swc that i'm loading
via the -theme compiler option.


Any help would be gratefully appreciated.



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

 Hey my embedded fonts are not appearing in my datagrid.
 
 They work everywhere else except the dataGrid.
 
 Any tips you guys have got to help me get this to work?
 
 
 
 btw. My datagrid is in a module, loaded by other modules.
 All modules are loading the fonts fine, except within the datagrid.
 And I'm not using Runtime CSS.





[flexcoders] Re: Embedded fonts in DataGrid

2008-03-31 Thread Bjorn Schultheiss
Blank,

embedFonts==false on a standard cell 'default dataGridItemRenderer';

how do i set the flag to true?


sorry if its sounds like a simple question...





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

 What do you get?  Blank, different font?
 
  
 
 Check to make sure the font didn't get reset in the columns or somewhere
 else along the way.  In the debugger, I step through the code that sets
 the embedFonts flag to make sure it is being set properly.
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of Bjorn Schultheiss
 Sent: Monday, March 31, 2008 9:36 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Embedded fonts in DataGrid
 
  
 
 I also thought i'd add i've added 
 
 import mx.controls.dataGridClasses.DataGridItemRenderer;
 
 private var dgir:DataGridItemRenderer; 
 
 to my main application, and my css is inside a swc that i'm loading
 via the -theme compiler option.
 
 Any help would be gratefully appreciated.
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 , Bjorn Schultheiss
 bjorn.mailinglists@ wrote:
 
  Hey my embedded fonts are not appearing in my datagrid.
  
  They work everywhere else except the dataGrid.
  
  Any tips you guys have got to help me get this to work?
  
  
  
  btw. My datagrid is in a module, loaded by other modules.
  All modules are loading the fonts fine, except within the datagrid.
  And I'm not using Runtime CSS.
 





Re: [flexcoders] Module Interfaces and Events

2008-03-27 Thread Bjorn Schultheiss

any suggestions?

On 27/03/2008, at 11:57 AM, Bjorn Schultheiss wrote:


I'm using Interfaces to define the api of my modules currently but i
also want to be able to define the event metadata as well.

What's the best way to tackle this?

At the moment i've tried extending my module interface with
IEventDispatcher and defining the Event metadata in the interface,
Except this does not provide code completion when using the
addEventListener() method on a var typed to the interface.







[flexcoders] Re: Module Interfaces and Events

2008-03-27 Thread Bjorn Schultheiss
If it worked I would not be asking.

Look Alex, I'm just looking for some support and I figured you were
the man.

This is my interface.

[Event(name=pagesRequired,
type=com.qmecom.common.events.EditItemsModuleEvent)]
public interface IEditItemsModule extends IBasicQmecomModule,
IEventDispatcher
{


I cant get Event metadata working with interfaces, only classes.

Have you guys ever had a solution for this.





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

 1)   Do not use the word modules in any question you need Flex
 Builder engineers to look at.  It tends to scare them away.
 
 2)   Make sure you've done the clean and rebuild
 
  
 
 In theory, this should work.
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of Bjorn Schultheiss
 Sent: Thursday, March 27, 2008 3:15 PM
 To: flexcoders@yahoogroups.com
 Subject: Re: [flexcoders] Module Interfaces and Events
 
  
 
 any suggestions?
 
  
 
 On 27/03/2008, at 11:57 AM, Bjorn Schultheiss wrote:
 
 
 
 I'm using Interfaces to define the api of my modules currently but i
 also want to be able to define the event metadata as well.
 
 What's the best way to tackle this?
 
 At the moment i've tried extending my module interface with
 IEventDispatcher and defining the Event metadata in the interface,
 Except this does not provide code completion when using
 theaddEventListener() method on a var typed to the interface.





[flexcoders] Module Interfaces and Events

2008-03-26 Thread Bjorn Schultheiss
I'm using Interfaces to define the api of my modules currently but i
also want to be able to define the event metadata as well.

What's the best way to tackle this?

At the moment i've tried extending my module interface with
IEventDispatcher and defining the Event metadata in the interface,
Except this does not provide code completion when using the
addEventListener() method on a var typed to the interface.



[flexcoders] cannot convert PopUpManagerImpl IPopUpManager WTF ???

2008-03-06 Thread Bjorn Schultheiss
I need some help here...

I'm getting this error at the moment.
TypeError: Error #1034: Type Coercion failed: cannot convert
mx.managers::[EMAIL PROTECTED] to mx.managers.IPopUpManager.
at mx.managers::PopUpManager$/get
impl()[E:\dev\flex_3_beta3\sdk\frameworks\projects\framework\src\mx\managers\PopUpManager.as:66]
at
mx.managers::PopUpManager$/addPopUp()[E:\dev\flex_3_beta3\sdk\frameworks\projects\framework\src\mx\managers\PopUpManager.as:167]


It doesn't make sense to me.

From the SDK
public class PopUpManagerImpl implements IPopUpManager

So how can it not convert ?!?!

Whats going on?




[flexcoders] Re: cannot convert PopUpManagerImpl IPopUpManager WTF ???

2008-03-06 Thread Bjorn Schultheiss
Thanks, 
again : )

I'm using modules and it was the shared code issue.



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

 Are you using modules and hitting the shared code issue?
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of Bjorn Schultheiss
 Sent: Thursday, March 06, 2008 3:23 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] cannot convert PopUpManagerImpl IPopUpManager WTF
 ???
 
  
 
 I need some help here...
 
 I'm getting this error at the moment.
 TypeError: Error #1034: Type Coercion failed: cannot convert
 mx.managers::[EMAIL PROTECTED] to mx.managers.IPopUpManager.
 at mx.managers::PopUpManager$/get
 impl()[E:\dev\flex_3_beta3\sdk\frameworks\projects\framework\src\mx\mana
 gers\PopUpManager.as:66]
 at
 mx.managers::PopUpManager$/addPopUp()[E:\dev\flex_3_beta3\sdk\frameworks
 \projects\framework\src\mx\managers\PopUpManager.as:167]
 
 It doesn't make sense to me.
 
 From the SDK
 public class PopUpManagerImpl implements IPopUpManager
 
 So how can it not convert ?!?!
 
 Whats going on?





[flexcoders] Re: Flex Builder 3.0 Serial No. Need

2008-03-03 Thread Bjorn Schultheiss
Classic!

I smell a chuck norris quotable coming on soon..




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

 Oooh, that's right, the dude is the owner of Magic Legs Martial Arts
 Academy. You think that academy qualifies for the education discount?
 http://www.linkedin.com/in/dangeoruskicker
 
 
 On 3/1/08, Sherif Abdou [EMAIL PROTECTED] wrote:
 
and then there is always the education version too
 
  - Original Message 
  From: ben.clinkinbeard [EMAIL PROTECTED]
  To: flexcoders@yahoogroups.com
  Sent: Saturday, March 1, 2008 10:56:45 PM
  Subject: [flexcoders] Re: Flex Builder 3.0 Serial No. Need
 
   U. There is a 60 day trial available from the Adobe site. Install
  it and start saving your money so you can buy it in 2 months.
 
  --- In [EMAIL PROTECTED] ups.com flexcoders%40yahoogroups.com,
devang
  solanki devang.flex@ ...
  wrote:
  
   Dear Friends
  
   if any one have flex builder 3.0 serial no or crack, then please
  forward to
   me, i need it
  
   Regards
   Devang
  
 
 
 
  --
  Looking for last minute shopping deals? Find them fast with Yahoo!
Search.http://us.rd.yahoo.com/evt=51734/*http://tools.search.yahoo.com/newsearch/category.php?category=shopping
 
   
 





Re: [flexcoders] CBA Choose AIR

2008-02-26 Thread Bjorn Schultheiss

I wonder who got that project.

Was it in-house?




On 27/02/2008, at 2:51 PM, Dale Fraser wrote:



http://www.australianit.news.com.au/story/0,24897,23283750-16123,00.html



Regards

Dale Fraser

http://learncf.com









Re: [flexcoders] Flex 3 and AIR 1 are now live!

2008-02-24 Thread Bjorn Schultheiss

Is there a trial download for flex 3 plugin version (mac) ?


On 25/02/2008, at 4:42 PM, Matt Chotin wrote:

No diff in upgrade path between your flex 2 versions AFAIK. Where  
are you looking? Should be $299 regardless I believe.


On 2/25/08 12:38 AM, Dale Fraser [EMAIL PROTECTED] wrote:

Cool,

I made the mistake of buying Standard for version 2 and want to  
upgrade to version 3 Pro, but there is no upgrade path.


Do I have to buy the full Pro again, or should I hang out for a  
Standard 2 - Professional 3 upgrade path.


Regards
Dale Fraser
http://learncf.com http://learncf.comhttp://learncf.com

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]  
On Behalf Of Brendan Meutzner

Sent: Monday, 25 February 2008 4:29 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Flex 3 and AIR 1 are now live!

Sweet!

Congratulations Matt, and kudos for all the hard work the team put  
in leading up to this.


Brendan

On Sun, Feb 24, 2008 at 11:24 PM, Matt Chotin [EMAIL PROTECTED]  
wrote:


http://www.adobe.com/products/flex
http://www.adobe.com/products/air

And best of all: http://opensource.adobe.com/flexsdk!

Matt







Re: [flexcoders] handling events from embedded swf assets

2008-02-07 Thread Bjorn Schultheiss

Its definitely possible.

of course you have to register to listen to it.


Its Interesting the way loading and unloading of swfs work in flash9.

You probably already know, but the swf is unloaded after it is loaded  
automatically.

watch the console.

to clean it up all you need to do is remove the references to what's  
been loaded in.




On 08/02/2008, at 10:30 AM, JWOpitz wrote:


I have a as3 swf w/ various movie clip assets in it. Some of them are
dispatching bubbling events that I want to listen for in order to
unload those assets afterwards.

In the flex app I have an AssetImporter class that has bindable prop
like so:

[Bindable]
[Embed(source=assets/swf/someSwf.swf, symbol=someMC)]
public var someSprite:Class;

Now on the end frame of the someMC, its dispatching a new
Event(movieClipEnded, true, true);

I want to be able to listen to this from the Flex app and load a
different embedded asset after the event is dispatched. On the app I
am listening for an event of the same type which is expected to be
bubbling up through the display architecture.

a) is this possible, it doesn't seem likely since Flex seems to be
ignoring it and the mc fails to stop()

b) if so, what is the syntax for doing so?







Re: [flexcoders] RPC: AsyncToken.addResponder vs addEventListener?

2008-02-06 Thread Bjorn Schultheiss
One thing i don't like about addResponder() is that there is no  
removeResponder();



On 07/02/2008, at 4:01 PM, Josh McDonald wrote:

What's the prevailing wind / general thoughts on using  
token.addResponder vs adding event listeners, beside the one  
request vs all requests nature of it? Is one faster / better /  
more common that the other?


--
Good people will do good things, and bad people will do bad things.  
But for good people to do bad things—that takes religion.


:: Josh 'G-Funk' McDonald
:: 0437 221 380 :: [EMAIL PROTECTED]






Re: [flexcoders] RPC: AsyncToken.addResponder vs addEventListener?

2008-02-06 Thread Bjorn Schultheiss

Don't quote me..
I looked into the source for the first time when blaze rc1 was released.
Its complicated.

On ResultEvent is

override mx_internal function callTokenResponders():void
{
if (token != null)
token.applyResult(this);
}

Apply result is
mx_internal function applyResult(event:ResultEvent):void
{
setResult(event.result);

if (_responders != null)
{
for (var i:uint = 0; i  _responders.length; i++)
{
var responder:IResponder = _responders[i];
if (responder != null)
{
responder.result(event);
}
}
}
}

callTokenResponders is called by abstract invoker which also  
dispatchers the result/fault events at the same time

mx_internal function dispatchRpcEvent(event:AbstractEvent):void
{
event.callTokenResponders();
if (!event.isDefaultPrevented())
{
dispatchEvent(event);
}
}


On 07/02/2008, at 4:11 PM, Josh McDonald wrote:


You're right, I hadn't noticed that. That's actually kinda strange.

When are they called, and what actually initiates the responders? Is  
it before or after the data or error events are dispatched?


-Josh


On Feb 7, 2008 3:03 PM, Bjorn Schultheiss [EMAIL PROTECTED] 
 wrote:
One thing i don't like about addResponder() is that there is no  
removeResponder();




On 07/02/2008, at 4:01 PM, Josh McDonald wrote:

What's the prevailing wind / general thoughts on using  
token.addResponder vs adding event listeners, beside the one  
request vs all requests nature of it? Is one faster / better /  
more common that the other?


--
Good people will do good things, and bad people will do bad  
things. But for good people to do bad things—that takes religion.


:: Josh 'G-Funk' McDonald
:: 0437 221 380 :: [EMAIL PROTECTED]






--
Good people will do good things, and bad people will do bad things.  
But for good people to do bad things—that takes religion.


:: Josh 'G-Funk' McDonald
:: 0437 221 380 :: [EMAIL PROTECTED]






Re: [flexcoders] RPC: AsyncToken.addResponder vs addEventListener?

2008-02-06 Thread Bjorn Schultheiss

sdks / frameworks / projects / rpc

in blaze rc1


On 07/02/2008, at 5:51 PM, Jerome Clarke wrote:

hi... sorry to be off subject... but you said source... where is the  
source... I don't see it anywhere except the JSP and Flex examples


thanks


On Feb 7, 2008 5:46 AM, Bjorn Schultheiss [EMAIL PROTECTED] 
 wrote:


Don't quote me..
I looked into the source for the first time when blaze rc1 was  
released.

Its complicated.

On ResultEvent is

override mx_internal function callTokenResponders():void
{
if (token != null)
token.applyResult(this);
}

Apply result is
mx_internal function applyResult(event:ResultEvent):void
{
setResult(event.result);

if (_responders != null)
{
for (var i:uint = 0; i  _responders.length; i++)
{
var responder:IResponder = _responders[i];
if (responder != null)
{
responder.result(event);
}
}
}
}

callTokenResponders is called by abstract invoker which also  
dispatchers the result/fault events at the same time

mx_internal function dispatchRpcEvent(event:AbstractEvent):void
{
event.callTokenResponders();
if (!event.isDefaultPrevented())
{
dispatchEvent(event);
}
}


On 07/02/2008, at 4:11 PM, Josh McDonald wrote:


You're right, I hadn't noticed that. That's actually kinda strange.

When are they called, and what actually initiates the responders?  
Is it before or after the data or error events are dispatched?


-Josh


On Feb 7, 2008 3:03 PM, Bjorn Schultheiss [EMAIL PROTECTED] 
 wrote:
One thing i don't like about addResponder() is that there is no  
removeResponder();




On 07/02/2008, at 4:01 PM, Josh McDonald wrote:

What's the prevailing wind / general thoughts on using  
token.addResponder vs adding event listeners, beside the one  
request vs all requests nature of it? Is one faster / better /  
more common that the other?


--
Good people will do good things, and bad people will do bad  
things. But for good people to do bad things—that takes religion.


:: Josh 'G-Funk' McDonald
:: 0437 221 380 :: [EMAIL PROTECTED]






--
Good people will do good things, and bad people will do bad  
things. But for good people to do bad things—that takes religion.


:: Josh 'G-Funk' McDonald
:: 0437 221 380 :: [EMAIL PROTECTED]










Re: [flexcoders] Re: ClassFactory

2008-02-04 Thread Bjorn Schultheiss
Anywhere where you want to turn a generic object into to a typed  
object instance at run-time.


On 05/02/2008, at 1:43 PM, ben.clinkinbeard wrote:


Item renderers are one place they can be used.
http://www.returnundefined.com/2006/11/creating-truly-reusable-renderers-with-classfactory/

HTH,
Ben

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

 can someone explain how to use this class, like when would i use it.
Give an example, i know it gets used in tabNavigator but i want to
know say if i am doing something when do i say ok lets use a  
ClassFactory




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








Re: [flexcoders] Re: Array vs ArrayCollection

2008-01-31 Thread Bjorn Schultheiss
I've got some scenarios where binding does not fire if I use  
ac.addItem or ac.removeItem.

But it will fire if i use ac = new ArrayCollection..

This is hard to reproduce as it only usually happens in large apps.
If i create simple test cases it usually works.

Anybody have any hints why ?


On 01/02/2008, at 5:57 AM, Alex Harui wrote:



You should use Array anywhere you don’t need binding or events that  
indicate changes to the array.




From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]  
On Behalf Of Teddy Setiawan

Sent: Thursday, January 31, 2008 8:39 AM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Re: Array vs ArrayCollection



I have the same problem regarding slower performance using  
arraycollection in some iterating process.
Then I change it to array , but I get another big  
problem..memory leak.


I use the array for small iterating process and using  
arraycollection for larga data.






To: flexcoders@yahoogroups.com
From: [EMAIL PROTECTED]
Date: Thu, 31 Jan 2008 16:18:46 +
Subject: [flexcoders] Re: Array vs ArrayCollection

This is something I too wonder about from time to time. I notice alot
of developers are using the ArrayCollection for data binding but I
can't say with 100% confidence why one would be used in any specific
problem domain opposed to a basic array. I guess if you find you want
to use the functions exposed by the ICollectionView and IList
interfaces the ArrayCollection is your tool.

Anybody have any clear examples?

Nick

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

 We have recently made some big performance gains in our product by
replacing the use of
 ArrayCollections with Arrays in some data calculation algorithms. It
appears that even
 iterating through an ArrayCollection is significantly slower than an
Array.

 My question to you all is... what have you found to be the best
place to use one of the other
 in your applications?

 Ryan





Connect and share in new ways with Windows Live. Get it now!







Re: [flexcoders] Re: Array vs ArrayCollection

2008-01-31 Thread Bjorn Schultheiss

Spot on..
Can't believed i never looked at that before.

Just check out the ListBase src and got an example of how to do it.

thanks.


On 01/02/2008, at 10:54 AM, Troy Gilbert wrote:

 I've got some scenarios where binding does not fire if I use  
ac.addItem or

 ac.removeItem.
 But it will fire if i use ac = new ArrayCollection..

Sounds like you're binding to just the ArrayCollection instance
variable and not taking the second step and listening for the
collection events. This should only happen in a custom component
because all of the Flex 2 dataProvider-based components handle this
correctly.

In a custom component/class, if you just bind myAC the binding only
fires when the instance in the myAC variable changes (when you do
new ArrayCollection()...). The right thing to do (if you want
dataProvider-like functionality) is to add a collection event listener
to your dataProvider in its setter and then handle those events.

If this is happening in apps that are only vanilla Flex components
(nothing custom), then there must be something wrong with the wiring
in your app somewhere...

Troy.






[flexcoders] ProfilerAgent.swf preventing debugging

2008-01-30 Thread Bjorn Schultheiss

Hey,

I've been getting this annoying bug where,

after debugging an app i try to profile it,
profiler throws an error 'can't profiler a non debug version', wtf!,
then i try to debug and debug session wont load!

my current workaround for getting debug to work is to rename or remove  
the ProfilerAgent.swf in

$Workspace:.metadata:.plugins:com.adobe.flash.profiler:ProfilerAgent.swf

In on mac in FB3b3

Re: [flexcoders] Re: ProfilerAgent.swf preventing debugging

2008-01-30 Thread Bjorn Schultheiss

Can you please make sure that you are trying to profile a debug
version of the swf?


I haven't created a release build in 2 months.
I dont use ant or command-line for compiling debug builds. Only the ide.


it could be due to an entry
in the mm.cfg file left behind by the profiler.


You were correct about the profile leaving behind the entry in mm.cfg




On 31/01/2008, at 3:24 PM, Gaurav Jain wrote:


Profiler is not supposed to work with release swfs.

Can you please make sure that you are trying to profile a debug
version of the swf? If the profiler is giving the error message for a
debug swf, can you please log a bug at http://bugs.adobe.com/flex with
the swf file, please?

If debug is not working after profiling, it could be due to an entry
in the mm.cfg file left behind by the profiler. So if you remove the
entry the debugger should start working again.

On OS X the mm.cfg should be in the home directory and the entry
starts with PreloadSwf=

Thanks,
Gaurav

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

 Hey,

 I've been getting this annoying bug where,

 after debugging an app i try to profile it,
 profiler throws an error 'can't profiler a non debug version', wtf!,
 then i try to debug and debug session wont load!

 my current workaround for getting debug to work is to rename or  
remove

 the ProfilerAgent.swf in
  
$ 
Workspace 
:.metadata:.plugins:com.adobe.flash.profiler:ProfilerAgent.swf


 In on mac in FB3b3








Re: [flexcoders] destructing objects / memory management best practices

2008-01-30 Thread Bjorn Schultheiss
Was weak-reference listeners for binding introduced in beta3 or an  
earlier beta?


On 24/01/2008, at 6:08 PM, Alex Harui wrote:



Pretty sure we fixed this in 3.0.  Weak-reference listeners are used  
in Binding.




You usually do not need to remove inline event listeners as the  
point back from the child to the document and therefore cannot cause  
a leak.




From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]  
On Behalf Of Bjorn Schultheiss

Sent: Wednesday, January 23, 2008 10:38 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] destructing objects / memory management best  
practices




So do we need to manually unwatch each binding statement ?



Also what about inline event listeners in mxml ?

Since we cannot manually remove them do i also need to switch to  
declaring all event listeners in AS ?




This is currently a major issue for me as in our latest Dev we are  
using modules and loading/unloading/reloading are very important  
issues to us.










On 24/01/2008, at 7:30 AM, Jerome Clarke wrote:




This is the reason why I only used Actionscript based binding  
instead of MXML... simply because you have control of that


On Jan 23, 2008 6:11 PM, Samuel R. Neff  [EMAIL PROTECTED]  
wrote:




So is it correct then that if you bind to something outside, say  
like to a singl! eton Mod el, then that binding creates a link which  
the author has no control over and can not destroy. So lets I have  
an example like:


Canvas title={Model.instance.applicationTitle} /

Then that simple binding will cause every instance of this component  
to be created and never GC'd?  We as Flex developers have no  
official way to tell this MXML based binding to unwatch and thus no  
way to clear the strong reference from the singleton Model to the  
component.  Isn't this a huge memory leak?  I don't understand how  
to reconcile this with your recommendation of being wary of reading  
outside to other parts of the app.  Are you saying we should not use  
MXML based bindings to reach outside our component at all?


Thanks,

Sam



! ---
We're Hiring! Seeking a passionate developer to join our team  
building Flex based products. Position is in the Washington D.C.  
metro area. If interested contact [EMAIL PROTECTED]







From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]  
On Behalf Of Matt Chotin


Sent: /b Wednesday, January 23, 2008 12:41 PM


To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] destructing objects / memory management  
best practices




No, you're right that binding does not use weak listeners (we tried  
at the end of Flex 2 development and found some really bad bugs if  
we did that).  So I shouldn't be making a global statement about  
don't check bindings.  But I guess my point is not that not all  
bindings are bad, especially when done within a single MXML document  
that doesn't try to reach outside.  Best practice is to be wary of  
how easily you reach out into other parts of the! app.  The more you  
can centralize that kind of thing, the easier it is to have code  
that releases listeners, references, etc.




From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]  
On Behalf Of Samuel R. N! eff

Sent: We dnesday, January 23, 2008 9:25 AM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] destructing objects / memory management  
best practices




Matt,



My understanding from reading the binding code is that bindings do  
not use a weak reference when they add an event listener, so  
bindings must be cleared (unwatched) in order for an object to be  
available for GC?  Are bindings created through MXML automatically  
unwatched at any point?  Or am I wrong about bindings using a strong  
reference?




Thanks,



Sam



---
We're Hiring! Seeking a passionate developer to join our team  
building Flex based products. Position is in the Washington D.C.  
metro area. If interested [EMAIL PROTECTED]















[flexcoders] destructing objects / memory management best practices

2008-01-23 Thread Bjorn Schultheiss

So do we need to manually unwatch each binding statement ?

Also what about inline event listeners in mxml ?
Since we cannot manually remove them do i also need to switch to  
declaring all event listeners in AS ?


This is currently a major issue for me as in our latest Dev we are  
using modules and loading/unloading/reloading are very important  
issues to us.





On 24/01/2008, at 7:30 AM, Jerome Clarke wrote:

This is the reason why I only used Actionscript based binding  
instead of MXML... simply because you have control of that



On Jan 23, 2008 6:11 PM, Samuel R. Neff  [EMAIL PROTECTED]  
wrote:


So is it correct then that if you bind to something outside, say  
like to a singleton Model, then that binding creates a link which  
the author has no control over and can not destroy. So lets I have  
an example like:


Canvas title={Model.instance.applicationTitle} /

Then that simple binding will cause every instance of this component  
to be created and never GC'd?  We as Flex developers have no  
official way to tell this MXML based binding to unwatch and thus no  
way to clear the strong reference from the singleton Model to the  
component.  Isn't this a huge memory leak?  I don't understand how  
to reconcile this with your recommendation of being wary of reading  
outside to other parts of the app.  Are you saying we should not use  
MXML based bindings to reach outside our component at all?


Thanks,

Sam


---
We're Hiring! Seeking a passionate developer to join our team  
building Flex based products. Position is in the Washington D.C.  
metro area. If interested contact [EMAIL PROTECTED]





From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]  
On Behalf Of Matt Chotin

Sent: Wednesday, January 23, 2008 12:41 PM

To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] destructing objects / memory management  
best practices


No, you're right that binding does not use weak listeners (we tried  
at the end of Flex 2 development and found some really bad bugs if  
we did that).  So I shouldn't be making a global statement about  
don't check bindings.  But I guess my point is not that not all  
bindings are bad, especially when done within a single MXML document  
that doesn't try to reach outside.  Best practice is to be wary of  
how easily you reach out into other parts of the app.  The more you  
can centralize that kind of thing, the easier it is to have code  
that releases listeners, references, etc.



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]  
On Behalf Of Samuel R. Neff

Sent: Wednesday, January 23, 2008 9:25 AM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] destructing objects / memory management  
best practices



Matt,


My understanding from reading the binding code is that bindings do  
not use a weak reference when they add an event listener, so  
bindings must be cleared (unwatched) in order for an object to be  
available for GC?  Are bindings created through MXML automatically  
unwatched at any point?  Or am I wrong about bindings using a strong  
reference?



Thanks,


Sam


---
We're Hiring! Seeking a passionate developer to join our team  
building Flex based products. Position is in the Washington D.C.  
metro area. If interested [EMAIL PROTECTED]









Re: [flexcoders] Re: Remote Objects AIR

2008-01-17 Thread Bjorn Schultheiss
Add a layer or abstraction between your service calls so you can  
switch between remote or local services, and then perform that switch  
based on the app.connected event.


regards,

Bjorn



On 18/01/2008, at 1:50 PM, lwz7512 wrote:


can anyone answer this question? I am also thinking about this! and
how to access object without server context?

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

 I have a Flex application running nicely and using Remote Objects
back to
 ColdFusion.



 I now want to make it an AIR application and make it do a couple
extra
 tricks.



 How does my AIR application talk Remote Objects, how do I tell it
what
 server to talk back to?



 Regards

 Dale Fraser








Re: [flexcoders] Imports being lost

2008-01-13 Thread Bjorn Schultheiss

Latest beta will imports protected functions for you :P

mx:HBox
xmlns:mx=http://www.adobe.com/2006/mxml; 
mx:Script
![CDATA[
import mx.core.Container.commitProperties;
override protected function commitProperties():void { }
]]
/mx:Script
/mx:HBox


On 14/01/2008, at 4:10 PM, Doug McCune wrote:

I also remember seeing this, but I don't think it has happened since  
the latest beta. If I remember correctly the issue seems to occur  
when organize imports would get run (possibly automatically) before  
I had edited the file (ie if it was just opened). I think I noticed  
that if I just hit ctrl-Z to undo it would put all the imports back,  
then if I edited the file and did an organize imports it would  
organize them correctly. I also remember seeing other weird things  
with organize imports, like the imports for things like getTimer  
would get lost, but again I think that was all with a previous beta.


So if you're not running the latest beta definitely try that.

Doug


On 1/13/08, Douglas Knudsen  [EMAIL PROTECTED] wrote:
Patrick, I have noticed this behavior.  I have not noticed since I  
upgraded to the latest beta 3 though, so far.


DK

On Jan 12, 2008 5:20 PM, Dealy, Brian  [EMAIL PROTECTED] wrote:
Patrick

this may be obvious to most, but sometimes I don't realize that  
flexbuilder collapses the imports


and represents that by putting a plus next to the first one  
indicating it can be expanded by


clicking on plus sign next to the first import…



sometimes the little things can elude us.

Brian



From: [EMAIL PROTECTED] 
 [mailto:[EMAIL PROTECTED] 
 ] On Behalf Of djhatrick

Sent: Saturday, January 12, 2008 12:15 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Imports being lost



I have noticed several times throughout my AS3 project in Flexbuilder,
with linked libraries, that sometimes a few of imports at the top of
the files, all of a sudden go missing? It's a weird bug. Anybody
notice this?

Thanks,
Patrick





--
Douglas Knudsen
http://www.cubicleman.com
this is my signature, like it?








[flexcoders] Modified version of Myriad Web Pro

2008-01-09 Thread Bjorn Schultheiss
Its seems the when you use 'Myriad Pro' in a Flex app it appears  
'raised' in all your components.
Its actually due the the glyph positioning in the font face.
Its seems that the FlexSDK has supplied a version of 'Myriad web pro'  
where the glyph position was closer to that of Verdana and looks nice  
used in flex apps.
Can anyone supply me with a similarly modified version of 'Myriad Web  
Pro Condensed' ?


Re: [flexcoders] Access Module Methods and Properties

2008-01-06 Thread Bjorn Schultheiss

You can get the module from the ModuleLoader.child property.
Depends how your loading the module i guess,

I'm using interfaces to give me strong typing between projects.
That is if i'm creating my modules in seperate projects.
I have a swc that i use as a rsl which contains my interfaces or  
psuedo-abstract classes that defines my modules (my modules extend  
these classes).


Does that help ?



On 06/01/2008, at 11:20 PM, Jávéd Hussain wrote:


Hi All,
I want to access the Public properties and Methods of Module Loaded  
in an application, is there any way to do that??? please help.


Regards,
Javed


Messenger on the move. Text MSN to 63463 now!






[flexcoders] IMXMLObject and IMXMLSupport within RSL's

2008-01-03 Thread Bjorn Schultheiss

Hi all,

I keep getting the same errors when i attempt to load a swc as a rsl  
in my app if my rsl contains any references to IMXMLSupport or  
IMXMLObject.

VerifyError: Error #1014: Class IMXMLObject could not be found
VerifyError: Error #1014: Class IMXMLSupport could not be found

If i merge it in the code it works fine.

Anyone got an explanation ?




[flexcoders] Source for rpc.swc

2007-12-13 Thread Bjorn Schultheiss
Hey all,

Where can I find the source for mx.rpc.*
in sdk/3.0/frameworks/src/mx/rpc/ it only containers IResponder.
Where's all the other classes, particularly AbstractServices.


regards,

Bjorn


Re: [flexcoders] addChild(bitmap) problems

2007-12-10 Thread Bjorn Schultheiss

Canvas.addChild() only accepts UIComponents?



On 11/12/2007, at 10:01 AM, Merrill, Jason wrote:



Can anyone see the error in this setup?

//drawTest.mxml file:

?xml version=1.0 encoding=utf-8?
mx:Application xmlns:mx=http://www.adobe.com/2006/mxml;  
layout=absolute applicationComplete=init()  
backgroundColor=0xFF

 mx:Script
  ![CDATA[
   import src.DrawBitmap;
   private function init():void
   {
var spiral:DrawBitmap = new DrawBitmap(myCanvas);
   }
  ]]
 /mx:Script
 mx:Canvas id=myCanvas x=10 y=10  width=774 height=463  
borderColor=0xD4001A borderStyle=solid/

/mx:Application

// DrawBitmap.as class:

package src
{
 import mx.containers.Canvas;
 import flash.display.BitmapData;
 import flash.display.Bitmap;
 import flash.geom.Rectangle;

 public class DrawBitmap
 {
  private var _canvas:Canvas;
  private var _bitmap:Bitmap;
  private var _imgData:BitmapData;

  public function DrawBitmap(canvas:Canvas):void
  {
   _canvas = canvas;
   _imgData = new BitmapData(20, 20, false, 0xFF00FF00);
   _imgData.fillRect(new Rectangle(5, 5, 10, 10), 0xFFFF);
   _bitmap = new Bitmap(_imgData);
   _canvas.addChild(_bitmap);  //Produces error
  }

 }
}

At runtime, I get this error in the debugger:
TypeError: Error #1034: Type Coercion failed: cannot convert  
flash.display::[EMAIL PROTECTED] to mx.core.IUIComponent.
at mx.core::Container/http://www.adobe.com/2006/flex/mx/ 
internal::addingChild()[C:\dev\GMC\sdk\frameworks\mx\core 
\Container.as:3303]


Seems to appear on the last line of the DrawBitmap class when I do  
_canvas.addChild(_bitmap).  That seems legal to me - add a bitmap  
display object to a canvas display object.  No?  What am I  
missing?  If that's not legal, then how to add my bitmap object to  
the canvas?


Thanks,

Jason Merrill
Bank of America
LLD GTO
eTools  Multimedia Research  Development







Re: [flexcoders] AS3 classes as MXML to enclose other tags

2007-12-09 Thread Bjorn Schultheiss

com.adobe.cairngorm.business.ServiceLocator

You've defined the cairngorm namespace in the base tag.





On 10/12/2007, at 10:27 AM, Chris Velevitch wrote:


I've been looking Cairngorm and I saw this:-

?xml version=1.0 encoding=utf-8?
cairngorm:ServiceLocator
xmlns:mx=http://www.adobe.com/2006/mxml;
xmlns:cairngorm=com.adobe.cairngorm.business.*
mx:RemoteObject
id=addcontactService
destination=addcontactService
showBusyCursor=true
result=event.token.resultHandler( event );
fault=event.token.faultHandler( event );
/mx:RemoteObject
/cairngorm:ServiceLocator

where ServiceLocator is a user defined class.

What is this mechanism called and where can I learn how it works?

Chris
--  
Chris Velevitch

Manager - Sydney Flash Platform Developers Group
m: 0415 469 095
www.flashdev.org.au






Re: [flexcoders] AS3 classes as MXML to enclose other tags

2007-12-09 Thread Bjorn Schultheiss
same as
mx:Button
xmlns:mx=http://www.adobe.com/2006/mxml*; 


On 10/12/2007, at 10:52 AM, Muzak wrote:

 cairngorm:ServiceLocator
 xmlns:mx=http://www.adobe.com/2006/mxml;
 xmlns:cairngorm=com.adobe.cairngorm.business.*


 That would be the same as:

 public class Services extends  
 com.adobe.cairngorm.business.ServiceLocator {}

 Where Services is the name of the mxml file that has  
 cairngorm:ServiceLocator...  defined as its base tag.
 Add the -keep argument to the compiler options to see what goes on  
 behind the scenes.

 regards,
 Muzak

 - Original Message -
 From: Chris Velevitch [EMAIL PROTECTED]
 To: flexcoders@yahoogroups.com
 Sent: Monday, December 10, 2007 12:27 AM
 Subject: [flexcoders] AS3 classes as MXML to enclose other tags


 I've been looking Cairngorm and I saw this:-

 ?xml version=1.0 encoding=utf-8?
 cairngorm:ServiceLocator
 xmlns:mx=http://www.adobe.com/2006/mxml;
 xmlns:cairngorm=com.adobe.cairngorm.business.*
 mx:RemoteObject
id=addcontactService
destination=addcontactService
 showBusyCursor=true
 result=event.token.resultHandler( event );
 fault=event.token.faultHandler( event );
/mx:RemoteObject
 /cairngorm:ServiceLocator

 where ServiceLocator is a user defined class.

 What is this mechanism called and where can I learn how it works?


 Chris
 -- 
 Chris Velevitch
 Manager - Sydney Flash Platform Developers Group
 m: 0415 469 095
 www.flashdev.org.au



 --
 Flexcoders Mailing List
 FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 Search Archives: http://www.mail-archive.com/flexcoders% 
 40yahoogroups.com
 Yahoo! Groups Links






Re: [flexcoders] AS3 classes as MXML to enclose other tags

2007-12-09 Thread Bjorn Schultheiss


On 10/12/2007, at 10:52 AM, Muzak wrote:

Add the -keep argument to the compiler options to see what goes on  
behind the scenes.



This will give you your answer.

Re: [flexcoders] AS3 classes as MXML to enclose other tags

2007-12-09 Thread Bjorn Schultheiss

Man, what concepts and philosophies are you looking for?

It's pretty simple.
Your just specifying an existing Class you wish to extend.



On 10/12/2007, at 1:37 PM, Chris Velevitch wrote:


On Dec 10, 2007 12:07 PM, Bjorn Schultheiss
[EMAIL PROTECTED] wrote:
 Add the -keep argument to the compiler options to see what goes  
on behind

 the scenes.

 This will give you your answer.

I'm looking for something at a higher level before I go for a deep
dive into the inner workings of the Flex compiler. Besides, the
compiler output won't explain the concepts and philosophy behind it.

Chris
--
Chris Velevitch
Manager - Sydney Flash Platform Developers Group
m: 0415 469 095
www.flashdev.org.au






Re: [flexcoders] Sequence Diagram for Cairngorm

2007-12-05 Thread Bjorn Schultheiss

cairngormdocs.org



On 06/12/2007, at 5:30 AM, lawriegallardo wrote:


Hi,

Just wondering if anyone has a sequence diagram for Cairngorm?

If so, I'd be ever so grateful if you could post it...

Thanks,

Lawrie







Re: [flexcoders] Re: Best Way to learn Flex

2007-12-02 Thread Bjorn Schultheiss

Set goals that interest you.
Interest and 'passion' : ) assists learning.

Ralf's url was a nice read.


regards,

Bjorn


On 03/12/2007, at 1:55 PM, DreamCode wrote:



I agree again. with everything, but unfortunately I don't have  
an IQ that breaks the bank, so in order for me to keep up with the  
talented ones I have to work harder :)


--Allan

On Dec 2, 2007 6:26 PM, aceoohay [EMAIL PROTECTED] wrote:
As long as other old timers are sittin' around the diner tellin' lies
I can add my two cents.

My first language was in High School, Burroughs B200 machine
language No assembly required.

The question is not how best to teach yourself Flex, but how best to
become a programmer. Is Flex the right tool for this? I think it is
as good as any, although the event driven model might make some
things more challenging (it still bugs the crap outa me from time to
time). I believe that teaching yourself the discipline of programming
is much more important than whatever language you use to do it.

To do this you may want to start by analyzing everyday things that
you do or see. For example the next time you go into a restaurant or
store, look at how things are laid out and look for the patterns in
workflow. Create a game out of how you would improve the systems you
see. To do this you will need to break things down into their
simplest actions and decisions, and then put them back together. Once
you do this a while you will start thinking in modular ways that will
help as you develop systems.

For me, the best way to teach myself a new language is to read a
little and check out some online tutorials until they put me to
sleep, and do a Hello World. Once through this phase, (call it the
first 2 dates) it's time to do a real program. This is the third
date, you take the language to a drive-in, and see whether you can
get to third base, or perhaps a home run. If the passion still burns
the next day, the next step is to move in together, start a real
project. This can be small, but something that is real. I am
converting a large inquiry system written in ASP to Flex for my first
project, and other than fighting over the Flex's nasty habits of
leaving the top off the toothpaste, and leaving its things all around
it's going well.

This is just how I go about it.

Paul



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

 --- In flexcoders@yahoogroups.com, Sheriff sherif626@ wrote:
 
  So I have been trying to learn flex now for almost 9 month and i
 pretty much still don't know much to get me anywhere.

 Just take the right-colored pill and enter the Matrix. Then, you
can
 download the knowledge into your brain directly ;)

 Or, you can do like most of us that have been programming for 20+
 years: work 300-hour months, forget your social life, and drink
lots
 of caffeine. Don't forget to come up for air every now and then.

 At least today's generation has google. Back in the day, all we had
 was Knuth (if you have not heard of Knuth, then it may be the
problem
 that you have not gotten it after 9 months at Flex.

 There are no shortcuts in programming -- either you spend the
 required amount of time, living through the simple and major
mistakes
 one can (and will) make, or don't bother.

 Just don't do what I did and start with Assembler. Although it was
 better in the long run, there's no need for the headaches these
days.











Re: [flexcoders] FYI: Flex video site for Aussie regional TV station

2007-11-22 Thread Bjorn Schultheiss

Congratulations!

Great to see some tight work coming out of Australia.

The HTML iframe content looks a bit dodgy on firefox mac.
But i'm not sure there's much you can do about it.


nice one!


regards,

Bjorn

On 23/11/2007, at 2:34 PM, Mailing Lists wrote:



It is a hybrid of our designs (www.webqem.com) and the clients  
thoughts ;-)




Through circumstances beyond our control it took about 2 months  
longer than needed but about 4 months all up.




Mike.



From: flexcoders@yahoogroups.com  
[mailto:[EMAIL PROTECTED] On Behalf Of Sheriff

Sent: Friday, 23 November 2007 2:17 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] FYI: Flex video site for Aussie regional  
TV station




did you design it? how long did it take?

- Original Message 
From: Mailing Lists [EMAIL PROTECTED]
To: flexcoders@yahoogroups.com
Sent: Thursday, November 22, 2007 8:01:27 PM
Subject: [flexcoders] FYI: Flex video site for Aussie regional TV  
station


Hi all,

http://canberra. iprime.com. au was released a few weeks ago and I  
thought I'd

mention it and see what you think.

Any comments greatly appreciated.

Mike.





Get easy, one-click access to your favorites. Make Yahoo! your  
homepage.









Re: [flexcoders] Re: Managing States and Cairngorm

2007-11-21 Thread Bjorn Schultheiss
It would be interesting to see a PureMVC vs Cairngorm implementation  
comparison.


But i believe this is a general MVC question.

The way i see the responsibilities in this case is you have 2 views.
(n) Components and 1 Mediator. The mediator would be responsible for  
updating your component setters and routing its dispatched events.


Your controller updates your model after receiving notification from  
the view mediator.


The model would store your property and would have the Mediator  
'bound' to that property.



regards,

Bjorn


On 22/11/2007, at 8:57 AM, Sebastian Zarzycki wrote:

Can you elaborate a bit more on this? This is in no way starting  
some kind
of flame. If you claim that such problems are solved easily, can  
you please

tell us more about it? Since you've apparently used both, some kind of
comparison would be EXTREMELY appreciated from my side. How does  
PureMVC

solves modularity, does it introduce strong coupling, does it use flex
features (binding, etc), what are drawbacks, how about changing  
states,

reusability?

I know there is a lot of documentation on the site, but I still  
value the

experienced user's opinion most.

-Original Message---
From: flexcoders@yahoogroups.com  
[mailto:[EMAIL PROTECTED] On

Behalf Of tomeuchre
Sent: Wednesday, November 21, 2007 10:15 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Managing States and Cairngorm

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

 I'm fighting with this as well.

I switched from Cairngorm to PureMVC and never looked back. It is so
much easier, logical and re-usable, and little things like this never
pop up anymore.
I'll never go back...


--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders% 
40yahoogroups.com

Yahoo! Groups Links







[flexcoders] internationalization

2007-11-14 Thread Bjorn Schultheiss
Hey,

As soon as i change my compiler settings from
-locale=en_US to -locale=es_ES i get the error
'cannot open flexsdk/locale/es_ES'.

This makes sense, but i there a way my i can just specify the locale  
for my own application and not all the imported Libraries?


regards,

Bjorn


[flexcoders] Re: internationalization

2007-11-14 Thread Bjorn Schultheiss
I just found localeChain : )


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

 Hey,
 
 As soon as i change my compiler settings from
 -locale=en_US to -locale=es_ES i get the error
 'cannot open flexsdk/locale/es_ES'.
 
 This makes sense, but i there a way my i can just specify the locale  
 for my own application and not all the imported Libraries?
 
 
 regards,
 
 Bjorn





[flexcoders] Re: internationalization

2007-11-14 Thread Bjorn Schultheiss
Sorry, this still hasn't helped me.
Can i specify a locale for my code and not the sdk?

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

 I just found localeChain : )
 
 
 --- In flexcoders@yahoogroups.com, Bjorn Schultheiss
 bjorn.mailinglists@ wrote:
 
  Hey,
  
  As soon as i change my compiler settings from
  -locale=en_US to -locale=es_ES i get the error
  'cannot open flexsdk/locale/es_ES'.
  
  This makes sense, but i there a way my i can just specify the locale  
  for my own application and not all the imported Libraries?
  
  
  regards,
  
  Bjorn
 





Re: [flexcoders] cairngorm design question , need suggestions

2007-11-13 Thread Bjorn Schultheiss

Hi Yigit,

To execute commanderB from commanderA you need to dispatch eventB  
from commanderA.
You can either pass the instance as an argument of eventB or  
reference via the model in commandB.



regards,

Bjorn



On 14/11/2007, at 9:44 AM, yigit boyar wrote:


hi all;
we have a GUI built with flex using cairngorm microarchitechture.
the GUI is quite complex, and there is an xml schema (xsd) that
represents the VO structure.
We prepared a code generator(using AIR) which parses the xsd and  
creates

vo's,commanders,events,modelfrontcontroller, so we just handcode the
view. (Vo's are serializable to XML and deserializable from XML , all
auto generated -sth like jaxb of java- )

the GUI was good for version1 but the XSD had to change a lot and  
we had

to insert hand written code into commaders and we started to have
performance issues.

now there is a new XSD, GUI will be recreated and we want to  
upgrade our

code generator to support the changes (more clever commanders  more
specific events!); so here comes my design question :

every class has it's own commander. and sometimes, when an event is
being executed, another commander should also work(sth more must be
done), and there is a specific event for that operation too.
(e.g. deletion of an instance of class A requires the update of the
instances of class B )
in this situation,
1 should commanderA dispatch an event to update class B instance
or
2 should commanderA call commanderB's execute function with the
needed event as argument
or
3 should commarderA edit B vo's . (we don't prefer this cuz it
violates the generic style of our code  cairngorm)

the second option is more efficient since it does not need to dispatch
the event and wait for it to be caught; but we wonder whether it
violates the cairngorm design pattern rules.

this is a really important project, so we'll be very pleased by taking
your comments.







Re: [flexcoders] PureMVC experts -- need assistance on mx.remoting.remoteObject calls

2007-11-06 Thread Bjorn Schultheiss

Check out the Cafe Townsend example


On 04/11/2007, at 3:10 AM, tomeuchre wrote:

I have a Flex app that interacts perfectly with my java app, when  
using

the mx:remoteOject definition and the getters and setters are in mxml
components.

However, I want to migrate to pureMVC and use ActionScript instead.

I started with the Arch101Demo example, and made a class in my java  
app

that matched the example (Employee).

However, the Arch101Demo used HTTPService, and I am using a
remoteObject call.

Do any Flex/PureMVC experts know how to modify the Arch101Demo to
properly use remoteObject calls via ActionScript instead of  
HTTPService?


I have tried a dozen different things, and while the responder does  
get

something back, it is not what it expects, apparently...







Re: [flexcoders] Trigger a function in the main applicatoin mxml from a popup window.

2007-10-28 Thread Bjorn Schultheiss
Listen to the closeEvent from the popup and call the function from  
the handler.


Bjorn


On 29/10/2007, at 12:10 PM, kalpkat9 wrote:


Hi,

This might be a really petty question to ask, but I will greatly
appreciate if someone can answer.

How can I trigger a function in my main application mxml, from a popup
window(title window/panel) after a submit button click. (I am  
trying to

change the state of my main application by clicking the submit button)

Thank you,
Kal.







Re: [flexcoders] Tween Motion along a path

2007-10-28 Thread Bjorn Schultheiss
I wasn't at Max, but have you seen this, http://labs.zeh.com.br/blog/? 
p=95 ?


Bjorn


On 29/10/2007, at 1:34 AM, snowjunkie73 wrote:


At Adobe Max 2007 I went to a session on creating custom components in
Flex. The example component used in the session was a custom carousel
component where objects would tween along a circular path. The source
for this example class was never released, but I am fairly certain
that the math for the path was done entirely in Flex, and it was not
using a Flash CS3 generated path. The movement was nice and smooth.

I'm trying to do my own tweening along a circular path but in a flat
2d manner. I've done all the math in action script 3 to find the
circular path but I am having trouble getting objects to move smoothly
along the path. Basically I pick a number of points along the path
and use Move effects from point to point. The more points I pick the
closer it appears to be on a true circle. I've tried both manually
kicking off each individual move effect from the effect end event and
also putting the move effects in a sequence effect. Both methods
cause the motion to be either extremely slow (if I set each move
duration to be large) or pretty jerky (if I set the move duration to
be very small like 0-2). It appears that there is a pause between the
end of each move effect before the next move effect starts.

The reason I want to do it all in code is that I want to be able to
vary the radius of my circular path dynamically. Anyone have ideas on
how I can get smoother motion along my path? Thanks in advance.







Re: [flexcoders] Re: Trigger a function in the main applicatoin mxml from a popup window.

2007-10-28 Thread Bjorn Schultheiss

Try from in the mainApp scope.


http://livedocs.adobe.com/labs/flex3/html/help.html? 
content=controls_22.html


?xml version=1.0?
!-- controls\alert\AlertIcon.mxml --
mx:Application xmlns:mx=http://www.adobe.com/2006/mxml;

mx:Script
![CDATA[
import mx.controls.Alert;
import mx.events.CloseEvent;

[Embed(source=assets/alertIcon.jpg)]
[Bindable]
public var iconSymbol:Class;

private function alertListener(eventObj:CloseEvent):void {
// Check to see if the OK button was pressed.
if (eventObj.detail==Alert.OK) {
myText.text = myInput.text;
}
}
]]
/mx:Script

mx:TextInput id=myInput
width=150
text=/
mx:Button id=myButton
label=Copy Text
click='Alert.show(Copy Text?, Alert,
Alert.OK | Alert.CANCEL, this,
alertListener, iconSymbol,  Alert.OK );'/
mx:TextInput id=myText/
/mx:Application



On 29/10/2007, at 1:56 PM, kalpkat9 wrote:


Thanks for taking your time to respond, Bjorn.

I am triggering a function called submitData() from the click event of
my button inside the popup window.

private function submitData():void{
mainApp.currentState.name = secondState;
}

This doesnt seem to accomplish what I wish for (of changing the state
of my mainApp.mxml)

How is that I can access a function from my main application mxml,
for example: changeState().

private function changeState():void{
currentState = secondState;
}

Please excuse my ignorance. Could you let me know what I am missing?

Thank you.

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

 Listen to the closeEvent from the popup and call the function from
 the handler.

 Bjorn


 On 29/10/2007, at 12:10 PM, kalpkat9 wrote:

  Hi,
 
  This might be a really petty question to ask, but I will greatly
  appreciate if someone can answer.
 
  How can I trigger a function in my main application mxml, from  
a popup

  window(title window/panel) after a submit button click. (I am
  trying to
  change the state of my main application by clicking the submit  
button)

 
  Thank you,
  Kal.
 
 
 








Re: [flexcoders] Re: Trigger a function in the main applicatoin mxml from a popup window.

2007-10-28 Thread Bjorn Schultheiss

I guess you would have to consider coupling.
You could have your mainApp register as a listener to your popup.  
dispatch an event from your popup that triggers the method in your  
mainApp view.
I guess you could also register your mainApp as a 'mediator' of your  
component popup.


Normally i would use an MVC architecture and my currentState would be  
bound to a property on the model.



Bjorn



On 29/10/2007, at 2:25 PM, kalpkat9 wrote:


ok, I guess this will suffice if the popup was just an alert. but the
popup window i am working on is a component by itself with datagrids
and states, so i have to trigger the with button click from this
titlewindow/popup window component. how is that i could access a
function in the mainApp.mxml from my popup custom component mxml?.
Thank you again.
(sincerely appreciate your responses).

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

 Try from in the mainApp scope.


 http://livedocs.adobe.com/labs/flex3/html/help.html?
 content=controls_22.html

 ?xml version=1.0?
 !-- controls\alert\AlertIcon.mxml --
 mx:Application xmlns:mx=http://www.adobe.com/2006/mxml;

 mx:Script
 ![CDATA[
 import mx.controls.Alert;
 import mx.events.CloseEvent;

 [Embed(source=assets/alertIcon.jpg)]
 [Bindable]
 public var iconSymbol:Class;

 private function alertListener(eventObj:CloseEvent):void {
 // Check to see if the OK button was pressed.
 if (eventObj.detail==Alert.OK) {
 myText.text = myInput.text;
 }
 }
 ]]
 /mx:Script

 mx:TextInput id=myInput
 width=150
 text=/
 mx:Button id=myButton
 label=Copy Text
 click='Alert.show(Copy Text?, Alert,
 Alert.OK | Alert.CANCEL, this,
 alertListener, iconSymbol, Alert.OK );'/
 mx:TextInput id=myText/
 /mx:Application



 On 29/10/2007, at 1:56 PM, kalpkat9 wrote:

  Thanks for taking your time to respond, Bjorn.
 
  I am triggering a function called submitData() from the click  
event of

  my button inside the popup window.
 
  private function submitData():void{
  mainApp.currentState.name = secondState;
  }
 
  This doesnt seem to accomplish what I wish for (of changing the  
state

  of my mainApp.mxml)
 
  How is that I can access a function from my main application mxml,
  for example: changeState().
 
  private function changeState():void{
  currentState = secondState;
  }
 
  Please excuse my ignorance. Could you let me know what I am  
missing?

 
  Thank you.
 
  --- In flexcoders@yahoogroups.com, Bjorn Schultheiss
  bjorn.mailinglists@ wrote:
  
   Listen to the closeEvent from the popup and call the function  
from

   the handler.
  
   Bjorn
  
  
   On 29/10/2007, at 12:10 PM, kalpkat9 wrote:
  
Hi,
   
This might be a really petty question to ask, but I will  
greatly

appreciate if someone can answer.
   
How can I trigger a function in my main application mxml, from
  a popup
window(title window/panel) after a submit button click. (I am
trying to
change the state of my main application by clicking the submit
  button)
   
Thank you,
Kal.
   
   
   
  
 
 
 








Re: [flexcoders] Re: Cairngorm vs PureMVC

2007-10-23 Thread Bjorn Schultheiss

Thats what ive got.

Ideally what i'm saying is i would have a single delegate for each  
command that makes a dao call.



Bjorn


On 23/10/2007, at 10:50 PM, ben.clinkinbeard wrote:


Why not just have a DAODelegate with methods like getUserDAO(),
getProductDAO(), etc?

Ben

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

 Hey Doug,

 My backend is mainly DAO's and I've got one delegate pers DAO in my
 company lib, that gets used across multiple projects.

 But I'm pretty sure thats not Cairngorm.

 Cairngorm is 1 to 1 e-c-d.


 regards,

 Bjorn


 On 23/10/2007, at 2:33 PM, Douglas Knudsen wrote:

  me2 :) I usually use one delegate per application or major
  division of the app, eg Modules. This delegate can access how ever
  many services it needs to to do the job. Further, it can rely on
  utility classes to massage incoming data if need be too. Now if I
  have to switch from WebService to RemoteObject, only need to  
create

  one new delegate to use, eh? bamm!
 
  DK
 
 
  On 10/22/07, ben.clinkinbeard [EMAIL PROTECTED] wrote:
  Yea, I just don't buy into that. I am all for short files and  
clear

  separation of responsibilities, but I don't see what
  single-method-delegates buys you. My delegates are pretty dumb,  
they

  just contain methods that take params and pass em along to web
  methods. I don't access the model or anything inside my  
delegates. To
  each his own obviously but I just don't think I will ever be  
sold on

  that division. I guess I'm a Cairngorm rebel. :)
 
 
 
  Ben
 
  --- In flexcoders@yahoogroups.com, Bjorn Schultheiss
  bjorn.mailinglists@ wrote:
  
   Hey Ben,
  
  
   The Idea is that even if you are calling the same webservice  
you are

   to create a new delegate.
  
   The sequence is Event - Command - Delegate.
  
   Not saying that i follow it, but I'm sure in it's strictest
   implementation its 1 to 1.
  
  
   Check this
   http://jessewarden.com/2007/08/10-tips-for-working-with-
  cairngorm.html
   6. There are 3 ways to use Commands  Delegates. I prefer A  
because
   it's consistent, leads to short class files, and is very  
explicit.

   A) For every use case, you make 1 Command and 1 Event. This can
   sometimes also mean 1 Delegate. (ie, LoginEvent, LoginCommand,
   LoginDelegate)
  
  
   Anyone from AC care to confirm?
  
  
  
   On 23/10/2007, at 12:08 PM, ben.clinkinbeard wrote:
  
 the 1 to 1 event-command-delegate methodology
   
I've heard that mentioned indirectly a couple of times  
before but
don't remember ever reading it as a suggested methodology.  
Maybe I

just missed that instruction but I don't follow that practice.
  I have
one delegate per Web Service, so several Commands end up  
using the

same Delegate.
   
As a general practice, I think Commands are very often an
  appropriate
and efficient approach.
   
I haven't looked into PureMVC yet but would like to at some  
point.

That being said, I've also not really encountered any
  situations where
I felt Cairngorm was restricting me from accomplishing  
anything.

   
Ben
   
--- In flexcoders@yahoogroups.com, Bjorn Schultheiss
bjorn.mailinglists@ wrote:

 Hey All,

 I don't know if there has been a previous thread on this.  
I'm

 assuming there is but i thought i'd start one again in light
  of some
 recent blog posts about a Silvafug meeting by the assertTrue
  guys on
 frameworks.

 http://www.asserttrue.com/articles/2007/10/17/silvafug-
  application-
 frameworks-presentation
 http://probertson.com/articles/2007/10/18/flex-application-
frameworks-
 presentations/
 http://www.sephiroth.it/weblog/archives/2007/10/
  flex_frameworks.php

 I haven't used PureMVC yet but I have used Cairngorm for  
a while

 (since the flash 7 days).

 I will say I've got a few beefs with Cairngorm and from just
  looking
 at the PureMVC diagram i already see a few solutions.

 I guess my main beefs with cairngorm has been the use of
  commands.
 Specifically in creating Re-usable commands.
 the 1 to 1 event-command-delegate methodology has never  
sat well

with
 me.

 Dumb Models (vo collections) is another.

 Support for unit testing in the View is another.


 Anyone care to help start a discussion?


 regards,

 Bjorn

   
   
   
  
 
 
 
 
 
  --
  Douglas Knudsen
  http://www.cubicleman.com
  this is my signature, like it?
 
 








[flexcoders] Flex Library Project Manifest Options

2007-10-23 Thread Bjorn Schultheiss
I'm trying to build my swc from a Flex Library Project and having  
difficulty added a component manifest.

In project properties - compiler options, i added a url and manifest  
file, and i get a unknown namespace error.

Is this a bug?


[flexcoders] Cairngorm vs PureMVC

2007-10-22 Thread Bjorn Schultheiss
Hey All,

I don't know if there has been a previous thread on this. I'm  
assuming there is but i thought i'd start one again in light of some  
recent blog posts about a Silvafug meeting by the assertTrue guys on  
frameworks.

http://www.asserttrue.com/articles/2007/10/17/silvafug-application- 
frameworks-presentation
http://probertson.com/articles/2007/10/18/flex-application-frameworks- 
presentations/
http://www.sephiroth.it/weblog/archives/2007/10/flex_frameworks.php

I haven't used PureMVC yet but I have used Cairngorm for a while  
(since the flash 7 days).

I will say I've got a few beefs with Cairngorm and from just looking  
at the PureMVC diagram i already see a few solutions.

I guess my main beefs with cairngorm has been the use of commands.
Specifically in creating Re-usable commands.
the 1 to 1 event-command-delegate methodology has never sat well with  
me.

Dumb Models (vo collections) is another.

Support for unit testing in the View is another.


Anyone care to help start a discussion?


regards,

Bjorn


Re: [flexcoders] Re: Cairngorm vs PureMVC

2007-10-22 Thread Bjorn Schultheiss

Hey Ben,


The Idea is that even if you are calling the same webservice you are  
to create a new delegate.


The sequence is Event - Command - Delegate.

Not saying that i follow it, but I'm sure in it's strictest  
implementation its 1 to 1.



Check this
http://jessewarden.com/2007/08/10-tips-for-working-with-cairngorm.html
6. There are 3 ways to use Commands  Delegates. I prefer A because  
it’s consistent, leads to short class files, and is very explicit.
A) For every use case, you make 1 Command and 1 Event. This can  
sometimes also mean 1 Delegate. (ie, LoginEvent, LoginCommand,  
LoginDelegate)



Anyone from AC care to confirm?



On 23/10/2007, at 12:08 PM, ben.clinkinbeard wrote:


 the 1 to 1 event-command-delegate methodology

I've heard that mentioned indirectly a couple of times before but
don't remember ever reading it as a suggested methodology. Maybe I
just missed that instruction but I don't follow that practice. I have
one delegate per Web Service, so several Commands end up using the
same Delegate.

As a general practice, I think Commands are very often an appropriate
and efficient approach.

I haven't looked into PureMVC yet but would like to at some point.
That being said, I've also not really encountered any situations where
I felt Cairngorm was restricting me from accomplishing anything.

Ben

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

 Hey All,

 I don't know if there has been a previous thread on this. I'm
 assuming there is but i thought i'd start one again in light of some
 recent blog posts about a Silvafug meeting by the assertTrue guys on
 frameworks.

 http://www.asserttrue.com/articles/2007/10/17/silvafug-application-
 frameworks-presentation
 http://probertson.com/articles/2007/10/18/flex-application- 
frameworks-

 presentations/
 http://www.sephiroth.it/weblog/archives/2007/10/flex_frameworks.php

 I haven't used PureMVC yet but I have used Cairngorm for a while
 (since the flash 7 days).

 I will say I've got a few beefs with Cairngorm and from just looking
 at the PureMVC diagram i already see a few solutions.

 I guess my main beefs with cairngorm has been the use of commands.
 Specifically in creating Re-usable commands.
 the 1 to 1 event-command-delegate methodology has never sat well  
with

 me.

 Dumb Models (vo collections) is another.

 Support for unit testing in the View is another.


 Anyone care to help start a discussion?


 regards,

 Bjorn








Re: [flexcoders] Cairngorm vs PureMVC

2007-10-22 Thread Bjorn Schultheiss

Hey Shaun,


It took me a while to grapple with but thats how it's been explained  
to me.


VO's. Thats it.
All logic is in the commands.

Now excuse me if I'm wrong and I'll be happy to be proven so.

In terms of event handling well, if a VO is Bindable is that the same?
Do you mean listening to the view or commands?

I'll quote Jesse again.

http://jessewarden.com/2007/08/10-tips-for-working-with-cairngorm.html
3. Only Commands set data on the Model; you can break this, just  
don’t if you can help it.
In Model View Controller, only the Controller sets data on the Model.  
In this case, the Commands are the Controller (usually), and as such,  
setting ModelLocator data is their job, and their job alone. If data  
is getting f’d up, you immediately know it’s in the Command. You  
never have to question “who’s setting my data, where, and when?”.



regards,

Bjorn



On 23/10/2007, at 12:00 PM, shaun wrote:


Hey Bjorn,

Bjorn Schultheiss wrote:
 Hey All,

 I don't know if there has been a previous thread on this. I'm
 assuming there is but i thought i'd start one again in light of some
 recent blog posts about a Silvafug meeting by the assertTrue guys on
 frameworks.

 http://www.asserttrue.com/articles/2007/10/17/silvafug-application-
 frameworks-presentation
 http://probertson.com/articles/2007/10/18/flex-application- 
frameworks-

 presentations/
 http://www.sephiroth.it/weblog/archives/2007/10/flex_frameworks.php

 I haven't used PureMVC yet but I have used Cairngorm for a while
 (since the flash 7 days).

 I will say I've got a few beefs with Cairngorm and from just looking
 at the PureMVC diagram i already see a few solutions.

 I guess my main beefs with cairngorm has been the use of commands.
 Specifically in creating Re-usable commands.
 the 1 to 1 event-command-delegate methodology has never sat well  
with

 me.

 Dumb Models (vo collections) is another.

I am wondering what makes you think that the CG models need to be  
dumb?


Why can't your CG model be a domain model? Then a ModelLocator simply
holds a reference to an object which forms part of a complex object
graph. The Objects are not just simple VOs(DTOs) but have state,
behaviour, event listeners and handlers.

cheers,
- shaun






Re: [flexcoders] Cairngorm vs PureMVC

2007-10-22 Thread Bjorn Schultheiss
Hey Shaun,


I'm not trying to play the Cairngorm Don here, but thats how i  
understood it.

I agree with placing logic around the model, especially for work with  
Data-Services.

As i understand 'currently' the only logic in the Model is getters  
and initialization of the defined structure via the Singleton.


regards,

Bjorn



On 23/10/2007, at 2:49 PM, shaun wrote:

 Hey Bjorn,

 Bjorn Schultheiss wrote:

 It took me a while to grapple with but thats how it's been  
 explained  to
 me.

 VO's. Thats it.
 All logic is in the commands.

 Now excuse me if I'm wrong and I'll be happy to be proven so.

 Interesting, but that doesnt really meet the definition of MVC does  
 it.

 I'll quote the Java BluePrints:
 http://java.sun.com/blueprints/patterns/MVC-detailed.html

 . Model - The model represents enterprise data and the business rules
 that govern access to and updates of this data. Often the model serves
 as a software approximation to a real-world process, so simple
 real-world modeling techniques apply when defining the model.

 As you can see that is quite different from the DTO/VO pattern(which
 should be used for coarse grained data transfer).

 I'll quote the Java BluePrints again:
 http://java.sun.com/blueprints/corej2eepatterns/Patterns/ 
 TransferObject.html

 . Clients usually require more than one value from an enterprise bean.
 To reduce the number of remote calls and to avoid the associated
 overhead, it is best to use Transfer Objects to transport the data  
 from
 the enterprise bean to its client.


 In terms of event handling well, if a VO is Bindable is that the  
 same?
 Do you mean listening to the view or commands?


 I do make by domain objects Bindable and non Dynamic.  But I'll try  
 and
 give a simple example of what I meant.

 My Model classes handle the propertyChange event so when a  
 proprerty of
 the object changes I can set a dirty flag to indicate that the  
 object
 has been changed and is unsaved.

 I also use event listeners on a collection object within a model  
 object.

 Object A has many B objects(stored in an arraycollection in object A).
 When a B object is added to the collection, A should be flagged as  
 unsaved.

 The A object needs to know when a B object has been added or  
 removed so
 it can set its own dirty flag.

 Object A adds a  changeevent listener to its arraycollection of B
 objects, A handles the collection change events dispatched by the
 collection of B objects by setting its own dirty flag.

 Right or wrong, this is an approach I have used in the past.


 I'll quote Jesse again.

 http://jessewarden.com/2007/08/10-tips-for-working-with- 
 cairngorm.html
 3. Only Commands set data on the Model; you can break this, just   
 don’t
 if you can help it.
 In Model View Controller, only the Controller sets data on the Model.
 In this case, the Commands are the Controller (usually), and as such,
 setting ModelLocator data is their job, and their job alone. If  
 data  is
 getting f’d up, you immediately know it’s in the Command. You  never
 have to question “who’s setting my data, where, and when?”.

 I think this type of rule might be more beneficial if you have a VO
 only model, as it makes sure your logic is in one spot, the command
 class rather than the view.
 So it seems like all the Event/Command classes have to be created to
 make up for the deficit of logic in the actual Model - where it should
 be IMO.
 It seems like the Command, which is meant to be a Controller?  
 according
 to the quote above (although we have a Front Controller aswell!  
 Whats up
 with that picture?) is playing the role that the model should be.

 Seems bogus to me.. :)

 cheers,
   - shaun






 --
 Flexcoders Mailing List
 FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 Search Archives: http://www.mail-archive.com/flexcoders% 
 40yahoogroups.com
 Yahoo! Groups Links






--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* Your email settings:
Individual Email | Traditional

* To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

* To change settings via email:
mailto:[EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/
 


Re: [flexcoders] Re: Cairngorm vs PureMVC

2007-10-22 Thread Bjorn Schultheiss

Hey Doug,

My backend is mainly DAO's and I've got one delegate pers DAO in my  
company lib, that gets used across multiple projects.


But I'm pretty sure thats not Cairngorm.

Cairngorm is 1 to 1 e-c-d.


regards,

Bjorn


On 23/10/2007, at 2:33 PM, Douglas Knudsen wrote:

me2 :)  I usually use one delegate per application or major  
division of the app, eg Modules.  This delegate can access how ever  
many services it needs to to do the job.  Further, it can rely on  
utility classes to massage incoming data if need be too.  Now if I  
have to switch from WebService to RemoteObject, only need to create  
one new delegate to use, eh?  bamm!


DK


On 10/22/07, ben.clinkinbeard [EMAIL PROTECTED] wrote:
Yea, I just don't buy into that. I am all for short files and clear
separation of responsibilities, but I don't see what
single-method-delegates buys you. My delegates are pretty dumb, they
just contain methods that take params and pass em along to web
methods. I don't access the model or anything inside my delegates. To
each his own obviously but I just don't think I will ever be sold on
that division. I guess I'm a Cairngorm rebel. :)



Ben

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

 Hey Ben,


 The Idea is that even if you are calling the same webservice you are
 to create a new delegate.

 The sequence is Event - Command - Delegate.

 Not saying that i follow it, but I'm sure in it's strictest
 implementation its 1 to 1.


 Check this
 http://jessewarden.com/2007/08/10-tips-for-working-with- 
cairngorm.html

 6. There are 3 ways to use Commands  Delegates. I prefer A because
 it's consistent, leads to short class files, and is very explicit.
 A) For every use case, you make 1 Command and 1 Event. This can
 sometimes also mean 1 Delegate. (ie, LoginEvent, LoginCommand,
 LoginDelegate)


 Anyone from AC care to confirm?



 On 23/10/2007, at 12:08 PM, ben.clinkinbeard wrote:

   the 1 to 1 event-command-delegate methodology
 
  I've heard that mentioned indirectly a couple of times before but
  don't remember ever reading it as a suggested methodology. Maybe I
  just missed that instruction but I don't follow that practice.  
I have

  one delegate per Web Service, so several Commands end up using the
  same Delegate.
 
  As a general practice, I think Commands are very often an  
appropriate

  and efficient approach.
 
  I haven't looked into PureMVC yet but would like to at some point.
  That being said, I've also not really encountered any  
situations where

  I felt Cairngorm was restricting me from accomplishing anything.
 
  Ben
 
  --- In flexcoders@yahoogroups.com, Bjorn Schultheiss
  bjorn.mailinglists@ wrote:
  
   Hey All,
  
   I don't know if there has been a previous thread on this. I'm
   assuming there is but i thought i'd start one again in light  
of some
   recent blog posts about a Silvafug meeting by the assertTrue  
guys on

   frameworks.
  
   http://www.asserttrue.com/articles/2007/10/17/silvafug- 
application-

   frameworks-presentation
   http://probertson.com/articles/2007/10/18/flex-application-
  frameworks-
   presentations/
   http://www.sephiroth.it/weblog/archives/2007/10/ 
flex_frameworks.php

  
   I haven't used PureMVC yet but I have used Cairngorm for a while
   (since the flash 7 days).
  
   I will say I've got a few beefs with Cairngorm and from just  
looking

   at the PureMVC diagram i already see a few solutions.
  
   I guess my main beefs with cairngorm has been the use of  
commands.

   Specifically in creating Re-usable commands.
   the 1 to 1 event-command-delegate methodology has never sat well
  with
   me.
  
   Dumb Models (vo collections) is another.
  
   Support for unit testing in the View is another.
  
  
   Anyone care to help start a discussion?
  
  
   regards,
  
   Bjorn
  
 
 
 






--
Douglas Knudsen
http://www.cubicleman.com
this is my signature, like it?






[flexcoders] custom mxml-manifest file updates not noticed in F3B2

2007-10-21 Thread Bjorn Schultheiss
Hey,

Has anyone else experienced this.
I've added components to my custom mxml-manifest file which is loaded  
into the compiler via a modified flex-config file.
I do not get any compiler error from the other components listed in  
the manifest.
But i'm getting 'Could not resolve' erros from the new entries.

Also i do not get any errors if I rename an existing entry in the  
manifest to an invalid name.


regards,

Bjorn


Re: [flexcoders] Re: Mock objects in AS3

2007-10-18 Thread Bjorn Schultheiss

Hey Dave and Adam,


That way a quick reply i sent yesterday without much thought.
Currently to convert a generic object to a typed instance i've been  
using a utility provided by Darron Schall.

http://www.darronschall.com/weblog/archives/000247.cfm

basically the method looks like this,

public static function objectToInstance( object:Object, clazz:Class ):*
{
var bytes:ByteArray = new ByteArray();
bytes.objectEncoding = ObjectEncoding.AMF0;

// Find the objects and byetArray.writeObject them, adding in 
the
		// class configuration variable name -- essentially, we're  
constructing

// and AMF packet here that contains the class information so 
that
// we can simplly byteArray.readObject the sucker for the 
translation

// Write out the bytes of the original object
var objBytes:ByteArray = new ByteArray();
objBytes.objectEncoding = ObjectEncoding.AMF0;
objBytes.writeObject( object );

// Register all of the classes so they can be decoded via AMF
var typeInfo:XML = describeType( clazz );
		var fullyQualifiedName:String = [EMAIL PROTECTED]().replace 
( /::/, . );

registerClassAlias( fullyQualifiedName, clazz );

		// Write the new object information starting with the class  
information

var len:int = fullyQualifiedName.length;
		bytes.writeByte( 0x10 );  // 0x10 is AMF0 for typed object (class  
instance)

bytes.writeUTF( fullyQualifiedName );
// After the class name is set up, write the rest of the object
bytes.writeBytes( objBytes, 1 );

// Read in the object with the class property added and return 
that
bytes.position = 0;

// This generates some ReferenceErrors of the object being 
passed in
		// has properties that aren't in the class instance, and generates  
TypeErrors
		// when property values cannot be converted to correct values (such  
as false
		// being the value, when it needs to be a Date instead).  However,  
these
		// errors are not thrown at runtime (and only appear in trace ouput  
when
		// debugging), so a try/catch block isn't necessary.  I'm not sure  
if this
		// classifies as a bug or not... but I wanted to explain why if you  
debug

// you might seem some TypeError or ReferenceError items appear.
var result:* = bytes.readObject();
return result;
}


regards,

Bjorn





On 18/10/2007, at 10:40 AM, dave_defusion wrote:


Bjorn,

I have been looking at this (as I would like a mocking framework for
Flex too) this evening and I've had no luck either.

The the registerClassAlias() does add the alias to a given class I
can't then get anything to accept it as being of that type
- I'm not sure what the alias is, but dumping the describeType()
results shows it as an alias property on the type and not as an
implementsInterface node, which is what we need.

I may not have been fully understood what registerClassAlias though.

But it looks (ok, it's late and I'm tired so it may just be that which
is causing my negativity) as if trying to get a class to implement an
interface (or at least appear to implement an interface) dynamically
at run time is a futile effort.

Any thoughts?

-D

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

 try add
 flash.net.registerClassAlias( attempt.TestInterface,  
TestInterface );

 prior to your cast attempt.


 regards,

 Bjorn


 On 17/10/2007, at 1:06 PM, aduston1976 wrote:

  lus I see a number of places on the web where the idea is  
mentioned,
  e.g. http://www.herrodius.com/blog/?m=200704 . However I cannot  
find

  any mock frameworks for AS3.
 
  This evening I spent some time trying to mock one up on my own  
(ok,
  sorry for the pun!) but I ran into troubles. Is anyone  
interested in

  thinking about this problem with me?
 
  Here is what I did during my 20 minutes of playing:
 
  Define an interface:
 
  public interface TestInterface
  {
  function setSomething(something : String) : void;
  }
 
  Run the following code:
 
  public function flexmock() {
  var i : TestInterface;
  var c : Class =
  flash.utils.getDefinitionByName(attempt.TestInterface) as Class;
  var desc : XML = flash.utils.describeType(c);
  var str : String = desc.toString();
  var a : Object = new Object();
  a[setSomething] = function(something : String) : void {
  trace(something); };
  // will fail on the following line, since a does not implement
  TestInterface.
  i = TestInterface(a);
  i.setSomething(blah);
  }
 
  AS3 doesn't support duck typing like Ruby, and I believe there  
is no

  way to get an object in memory that implements the TestInterface

Re: [flexcoders] Validation border doesn't update

2007-10-17 Thread Bjorn Schultheiss

I logged a bug recently on this topic.
vote for it
http://bugs.adobe.com/jira/browse/SDK-13005

The workaround is there as well


On 18/10/2007, at 10:15 AM, Richard Rodseth wrote:


I'm following the recipe described here:

http://www.adobe.com/devnet/flex/quickstart/validating_data/

In the last example on the above page (at least in Firefox), the  
validation borders don't seem to update correctly. In particular,  
when you type the character that makes an e-mail address valid, the  
red border does not disappear, but if you cover and uncover the  
window, it re-renders correctly.






Re: [flexcoders] Anyone reading Paul Williams blogging about Presentation Patterns?

2007-10-16 Thread Bjorn Schultheiss

cool, it seems comments are now on.
I've got to say I'm pretty interested to read your upcoming posts.

regards,

Bjorn

On 16/10/2007, at 5:14 PM, Paul Williams wrote:



Hi Bjorn,



Thanks for the feedback. I didn’t realize comments were not active  
on these entries; I’ve corrected this and will make sure that they  
are open for future entries.




Paul



From: flexcoders@yahoogroups.com  
[mailto:[EMAIL PROTECTED] On Behalf Of Bjorn Schultheiss

Sent: Monday, October 15, 2007 7:05 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Anyone reading Paul Williams blogging about  
Presentation Patterns?




Hey all,



I'm attempting to get a discussion going here on this topic since  
Paul disabled comments on his blog.




Is anyone else here reading this series?



In particular his last post.

Supervising Presenter

http://weblogs.macromedia.com/paulw/archives/2007/10/ 
presentation_pa_2.cfm




One of the benefits he speaks about with using this pattern is,

Improved separation of concerns

Following the Supervising Presenter pattern should yield an  
application-specific class hierarchy that is separated from the  
view classes, but coupled to them. Common presentation concerns can  
be refactored into Presenter base classes, and this should help to  
reduce code-duplication and improve consistency across an application.




This concern is of huge importance to me as a flex dev.



During dev one of the main issues i run into is what will be an  
'application-specific view' as opposed to a 'reusable-component' as  
abstraction can be a time-consuming exercise.


I've never been a fan of code behind but i think the 'Presenter'  
does bring in a useful and easy to implement application level of  
abstraction that can ease development.




btw I also like his use of Binding.





regards,



Bjorn














Re: [flexcoders] Mock objects in AS3

2007-10-16 Thread Bjorn Schultheiss

try add
flash.net.registerClassAlias( attempt.TestInterface, TestInterface );
prior to your cast attempt.


regards,

Bjorn


On 17/10/2007, at 1:06 PM, aduston1976 wrote:


lus I see a number of places on the web where the idea is mentioned,
e.g. http://www.herrodius.com/blog/?m=200704 . However I cannot find
any mock frameworks for AS3.

This evening I spent some time trying to mock one up on my own (ok,
sorry for the pun!) but I ran into troubles. Is anyone interested in
thinking about this problem with me?

Here is what I did during my 20 minutes of playing:

Define an interface:

public interface TestInterface
{
function setSomething(something : String) : void;
}

Run the following code:

public function flexmock() {
var i : TestInterface;
var c : Class =
flash.utils.getDefinitionByName(attempt.TestInterface) as Class;
var desc : XML = flash.utils.describeType(c);
var str : String = desc.toString();
var a : Object = new Object();
a[setSomething] = function(something : String) : void {
trace(something); };
// will fail on the following line, since a does not implement
TestInterface.
i = TestInterface(a);
i.setSomething(blah);
}

AS3 doesn't support duck typing like Ruby, and I believe there is no
way to get an object in memory that implements the TestInterface
interface that my other objects can use as a mock.

Any thoughts about this? Am I doomed to use elbow grease or code
generation to create these things?

BTW, this message is also posted on the ActionScript 3 FlexUnit
Library forum in Google Groups. Hopefully that isn't some kind of
forum faux pas.

Thank you for any comments,
Adam







[flexcoders] Anyone reading Paul Williams blogging about Presentation Patterns?

2007-10-15 Thread Bjorn Schultheiss

Hey all,

I'm attempting to get a discussion going here on this topic since  
Paul disabled comments on his blog.


Is anyone else here reading this series?

In particular his last post.
Supervising Presenter
http://weblogs.macromedia.com/paulw/archives/2007/10/ 
presentation_pa_2.cfm


One of the benefits he speaks about with using this pattern is,
Improved separation of concerns
Following the Supervising Presenter pattern should yield an  
application-specific class hierarchy that is separated from the view  
classes, but coupled to them. Common presentation concerns can be  
refactored into Presenter base classes, and this should help to  
reduce code-duplication and improve consistency across an application.


This concern is of huge importance to me as a flex dev.

During dev one of the main issues i run into is what will be an  
'application-specific view' as opposed to a 'reusable-component' as  
abstraction can be a time-consuming exercise.
I've never been a fan of code behind but i think the 'Presenter' does  
bring in a useful and easy to implement application level of  
abstraction that can ease development.


btw I also like his use of Binding.


regards,

Bjorn





Re: [flexcoders] Multiple IFrames in Flex

2007-10-15 Thread Bjorn Schultheiss
Use ExternalInterface to call js methods on the html page that loads  
your Flex app.

Forgive me for the lack of detail in my explanation.




On 16/10/2007, at 11:50 AM, [EMAIL PROTECTED] wrote:


Right.



On 10/16/07, Dimitrios  
Gianninas[EMAIL PROTECTED] wrote:


Are you using the Iframe trick to show HTML with a Flex app? is  
that what you are doing and are asking how to show multiple ones?


Dimitrios Gianninas
Development Team Lead
Optimal Payments Inc.


From: flexcoders@yahoogroups.com  
[mailto:[EMAIL PROTECTED] On Behalf Of Flexing...

Sent: Monday, October 15, 2007 12:17 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Multiple IFrames in Flex

Hi All,

I am building an application which require me to show
multiple IFrame based banners on a Panel.

Is their a way to achieve this in Flex ?
Is Adobe doing something in the direction to support IFrames in Flex ?

Currently I am using a servlet based solution i..e create a single
servlet based HTML page containing all IFrame banners
and serve this HTML page as IFrame in Flex.

Because of this limitation I have to provide the support of editing
of all the information related to those banners also in servlet.

Anybody has a better solution please share.

Thanks
Bhuvan

AVIS IMPORTANT

WARNING

Ce message électronique et ses pièces jointes peuvent contenir des  
renseignements confidentiels, exclusifs ou légalement privilégiés  
destinés au seul usage du destinataire visé. L'expéditeur original  
ne renonce à aucun privilège ou à aucun autre droit si le présent  
message a été transmis involontairement ou s'il est retransmis sans  
son autorisation. Si vous n'êtes pas le destinataire visé du  
présent message ou si vous l'avez reçu par erreur, veuillez cesser  
immédiatement de le lire et le supprimer, ainsi que toutes ses  
pièces jointes, de votre système. La lecture, la distribution, la  
copie ou tout autre usage du présent message ou de ses pièces  
jointes par des personnes autres que le destinataire visé ne sont  
pas autorisés et pourraient être illégaux. Si vous avez reçu ce  
courrier électronique par erreur, veuillez en aviser l'expéditeur.


This electronic message and its attachments may contain  
confidential, proprietary or legally privileged information, which  
is solely for the use of the intended recipient. No privilege or  
other rights are waived by any unintended transmission or  
unauthorized retransmission of this message. If you are not the  
intended recipient of this message, or if you have received it in  
error, you should immediately stop reading this message and delete  
it and all attachments from your system. The reading, distribution,  
copying or other use of this message or its attachments by  
unintended recipients is unauthorized and may be unlawful. If you  
have received this e-mail in error, please notify the sender.










Re: [flexcoders] Re: Anyone reading Paul Williams blogging about Presentation Patterns?

2007-10-15 Thread Bjorn Schultheiss

Do you guys use Cairngorm at all?

It will be interesting to see how Paul brings it all together in  
later posts.




On 16/10/2007, at 6:45 AM, aduston1976 wrote:


One other detail about our implementation: Because there is no
dependency injection in AS3 (that I know of), I have an Abstract
Factory generate the View components. This way I can just swap out my
Abstract Factory with one that generates Mock Views for testing by
altering a Boolean constant in the main startup class.

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

 In our Flex projects we typically use the Passive View pattern (
 http://martinfowler.com/eaaDev/PassiveScreen.html). Probably I
should blog
 about my experience with this, but I am pathologically lazy and  
terribly

 selfish, so I don't have a blog. The applications I'm creating
involve a lot
 of bidirectional server communication and real-time multiuser
interaction,
 so using this pattern enables me to create View test doubles that  
use

 LocalConnection to communicate with a central admin testing flex app
that
 runs test harness scripts. For example, a simple test would be: Have
user 1
 login, and make sure the name appears in user 2's screen. But we can
 essentially replicate arbitrary user interactions using this setup,
and test
 the application end-to-end modulo Views. We can also substitute
mocks for
 View classes to test the Controllers. I should mention that  
coding these

 mocks in AS3 is a bit of a PITA. Can anyone think of a way to create
a flex
 mock test framework? Message me off-list please! Another advantage
of this
 approach is that my View (i.e. MXML) classes contain very little
code, just
 setter methods and calls to the Controller. That makes the software
text for
 these less intimidating to graphic designers.

 We are actually looking for someone to help us part-time with our  
Flex

 coding. We can only afford $20 per hour right now, but email me
off-list if
 you are interested! We are making some pretty cool applications!

 Adam


 On 10/15/07, Paul Dale [EMAIL PROTECTED] wrote:
 
 
  I think the principle of extracting everything that can't be
expressed as
  a simple data binding is solid.
 
  That makes it easy to inject a test data object (or series of data
or data
  objects) to automate running through each presentation  
possibility.

 
  ...paul
 
 
  On 10/15/07, Bjorn Schultheiss [EMAIL PROTECTED] wrote:
  
   Hey all,
  
   I'm attempting to get a discussion going here on this topic
since Paul
   disabled comments on his blog.
  
   Is anyone else here reading this series?
  
   In particular his last post.
   Supervising Presenter
  
  
http://weblogs.macromedia.com/paulw/archives/2007/10/ 
presentation_pa_2.cfm

  
   One of the benefits he speaks about with using this pattern is,
   Improved separation of concerns
   Following the Supervising Presenter pattern should yield an
   application-specific class hierarchy that is separated from  
the view

   classes, but coupled to them. Common presentation concerns can
be refactored
   into Presenter base classes, and this should help to reduce
code-duplication
   and improve consistency across an application.
  
   This concern is of huge importance to me as a flex dev.
  
   During dev one of the main issues i run into is what will be an
   'application-specific view' as opposed to a 'reusable- 
component' as

   abstraction can be a time-consuming exercise.
   I've never been a fan of code behind but i think the 'Presenter'
does
   bring in a useful and easy to implement application level of
abstraction
   that can ease development.
  
   btw I also like his use of Binding.
  
  
   regards,
  
   Bjorn
  
  
  
  
 
 








[flexcoders] swc question

2007-10-02 Thread Bjorn Schultheiss
Just to confirm, in regards to include swc files in your swc, the  
docs say,


In most cases, the symbols defined in the SWF file that are  
referenced by the application are embedded in the Flex application at  
compile-time. This is known as static linking. The application  
compiler only includes those classes that are used by your  
application, and dependent classes, in the final SWF file.


My question, does the compiler include dependant classes from the swc  
that are already included in the swf, for example if UIComponent is  
used in the swc will it add it again to my swf unnecessarily adding  
to the file size?



regards,

Bjorn



Re: [flexcoders] swc question

2007-10-02 Thread Bjorn Schultheiss

Hey Pat,

I was more interested of the contents of the swf that includes the swc.

Say i create a custom button and compc it to swc.
Then include that swc into my flex app.
Can the flex compiler work out that some of the classes in my swc,
are already in my flex app and therefore not 'duplicate' them in the  
compiled end swf?


I guess i'm mainly interested in the flex framework classes.



regards,

Bjorn


On 03/10/2007, at 1:51 PM, Patrick Lemiuex wrote:



Actually, I don't know the answer to your question Bjorn but you  
can inspect the contents of a swc  by renaming the extension to zip  
and then browsing the contents after you unzip it with winzip (or  
winrar).   The swc is just a wrapper.


Hope this helps.
Patrick



On Oct 2, 2007, at 6:16 PM, Bjorn Schultheiss wrote:

Just to confirm, in regards to include swc files in your swc, the  
docs say,



In most cases, the symbols defined in the SWF file that are  
referenced by the application are embedded in the Flex application  
at compile-time. This is known as static linking. The application  
compiler only includes those classes that are used by your  
application, and dependent classes, in the final SWF file.


My question, does the compiler include dependant classes from the  
swc that are already included in the swf, for example if  
UIComponent is used in the swc will it add it again to my swf  
unnecessarily adding to the file size?



regards,

Bjorn










Re: [flexcoders] Flex 3 beta 2 - Black Background on Initialize!?

2007-10-01 Thread Bjorn Schultheiss

Use the background-color compiler setting/option


cheers,

Bjorn

On 02/10/2007, at 11:36 AM, herklano wrote:


hi,

why is the background black on initialize in the Flex 3 Beta 2 ???

anyone knows how to get rid of this?

cheers,
herculano







Re: [flexcoders] How to get all children in Application?

2007-10-01 Thread Bjorn Schultheiss

I dont think there is a built-in function that returns all children.
It wouldn't be difficult to write a recursive function that recurses  
through the display list and gets all child display objects though.


regards,
Bjorn

On 02/10/2007, at 12:11 PM, flexawesome wrote:


Hi there,

is there a way to get all children in application? in the following
code, I can get the button_1, panel_1 only. However, can't get the
button_2 inside the panel.

can I get all children in whole application without knowing the
container structure?

THANKS

===
?xml version=1.0?
mx:Application xmlns:mx=http://www.adobe.com/2006/mxml;
creationComplete=init();

mx:Script
![CDATA[

import mx.core.UIComponent;

private var childrenLength:Number;
private var targetObj:Object;
private var targetType:String;
private var startPos:Number;
private var endPos:Number;  

private function init():void {
addEventListener(MouseEvent.MOUSE_OVER, getNum);
}

private function getNum(event:MouseEvent):void{
event.preventDefault();

checkContainer(event);
}


private function checkContainer(event:MouseEvent):void{
childrenLength = UIComponent(event.currentTarget).numChildren;

for (var i:uint=0; i  childrenLength; i++) {
targetObj = UIComponent(event.currentTarget).getChildAt(i);
targetType = getQualifiedClassName(targetObj);
trace(targetObj);
}   
}

]]
/mx:Script

mx:Button id=Button_1 label=Button1/

mx:Panel id=Panel_1 width=250 height=200 layout=absolute
mx:Button id=Button_2 x=79 y=35 label=Button2/
/mx:Panel

/mx:Application
===







Re: [flexcoders] Re: How to get all children in Application?

2007-10-01 Thread Bjorn Schultheiss

http://en.wikipedia.org/wiki/Recursion

On 02/10/2007, at 12:23 PM, flexawesome wrote:


I think so, and I creates function below. but don't know how to
implement and writes the recursive function in this case, would u
please show me an example?

THANKS

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

 I dont think there is a built-in function that returns all children.
 It wouldn't be difficult to write a recursive function that recurses
 through the display list and gets all child display objects though.

 regards,
 Bjorn

 On 02/10/2007, at 12:11 PM, flexawesome wrote:

  Hi there,
 
  is there a way to get all children in application? in the  
following

  code, I can get the button_1, panel_1 only. However, can't get the
  button_2 inside the panel.
 
  can I get all children in whole application without knowing the
  container structure?
 
  THANKS
 
  ===
  ?xml version=1.0?
  mx:Application xmlns:mx=http://www.adobe.com/2006/mxml;
  creationComplete=init();
 
  mx:Script
  ![CDATA[
 
  import mx.core.UIComponent;
 
  private var childrenLength:Number;
  private var targetObj:Object;
  private var targetType:String;
  private var startPos:Number;  
  private var endPos:Number;
 
  private function init():void {
  addEventListener(MouseEvent.MOUSE_OVER, getNum);
  }
 
  private function getNum(event:MouseEvent):void{
  event.preventDefault();
 
  checkContainer(event);
  }
 
 
  private function checkContainer(event:MouseEvent):void{
  childrenLength = UIComponent(event.currentTarget).numChildren;
 
  for (var i:uint=0; i  childrenLength; i++) {
  targetObj = UIComponent(event.currentTarget).getChildAt(i);
  targetType = getQualifiedClassName(targetObj);
  trace(targetObj);
  } 
  }
 
  ]]
  /mx:Script
 
  mx:Button id=Button_1 label=Button1/
 
  mx:Panel id=Panel_1 width=250 height=200 layout=absolute
  mx:Button id=Button_2 x=79 y=35 label=Button2/
  /mx:Panel
 
  /mx:Application
  ===
 
 
 








Re: [flexcoders] How to clone object?

2007-06-14 Thread Bjorn Schultheiss

There's some info here

http://livedocs.adobe.com/flex/2/docs/wwhelp/wwhimpl/common/html/ 
wwhelp.htm?context=LiveDocs_Partsfile=1882.html


On 15/06/2007, at 12:04 PM, williamkusumo wrote:


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

Any help is greatly appreciated.

Thanks!








[flexcoders] Validation drama

2007-06-05 Thread Bjorn Schultheiss

I just want to say validators in Flex 2 are the worst!
Why is something as simple as updating the border focus color on a  
component so difficult.


Fair enough i may be a little upset at the moment and not venting on  
a public forum, but please have some sort of update for this Flex 3.


As far as i am concerned why include it in the framework if it  
doesn't work.



example
http://www.adobe.com/devnet/flex/quickstart/validating_data/
play with the bottom example,
count how many times you can get a red border with blue focus or the  
opposite incorrect value.


Regards,

Bjorn Schultheiss 

Re: [flexcoders] Validation drama

2007-06-05 Thread Bjorn Schultheiss
and btw thanks for making Validator._source private so i cant even  
override the source setter without copy and pasting the entire class.


On 05/06/2007, at 4:25 PM, Bjorn Schultheiss wrote:



I just want to say validators in Flex 2 are the worst!
Why is something as simple as updating the border focus color on a  
component so difficult.


Fair enough i may be a little upset at the moment and not venting  
on a public forum, but please have some sort of update for this  
Flex 3.


As far as i am concerned why include it in the framework if it  
doesn't work.



example
http://www.adobe.com/devnet/flex/quickstart/validating_data/
play with the bottom example,
count how many times you can get a red border with blue focus or  
the opposite incorrect value.


Regards,

Bjorn Schultheiss







[flexcoders] Re: Disable Clicks while on busyCursor

2007-06-01 Thread Bjorn Schultheiss
This is quite slow.
I wait for the app to disable, then any animations running while the
app is disabled lag.



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

 Did you try Application.application.enabled = false?
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of Troy Gilbert
 Sent: Thursday, May 31, 2007 10:19 AM
 To: flexcoders@yahoogroups.com
 Subject: Re: [flexcoders] Disable Clicks while on busyCursor
 
  
 
 Is it just me, or is it a bit surprising that we've got to hack
 something together to handle this? Come on, Adobe... what's a proper
 solution (and why wasn't it built into the CursorManager!)? I've got
 enough asynchronous problems to deal with than have to worry that the
 user's going to go off willy-nilly clicking buttons while the busy
 cursor is being shown. I understand that some folks may not want it to
 *always* prevent mouse clicks, but a little boolean flag (or two) in the
 CursorManager that prevents mouse clicks and/or focus changes/keyboard
 events would be very, very nice. 
 
 Troy.
 
 
 
 On 5/31/07, Anthony Lee [EMAIL PROTECTED]
 mailto:[EMAIL PROTECTED]  wrote:
 
  - Make all your active components register themselves then loop
 through 
  and disable/enable them according to your busy state 
 
  Too taxing on cpu...
 
 How many components are we talking about?
 
 Hack #3
 Generate an Alert and position it outside the viewable area. They're
 modal by default... meaning the user shouldn't be able to click on
 anything till you clear it. 
 
 Anthony





Re: [flexcoders] Disable Clicks while on busyCursor

2007-06-01 Thread Bjorn Schultheiss

This is quite slow.
I wait for the app to disable, then any animations running while the  
app is disabled lag.





On 01/06/2007, at 3:51 AM, Alex Harui wrote:



Did you try Application.application.enabled = false?



From: flexcoders@yahoogroups.com  
[mailto:[EMAIL PROTECTED] On Behalf Of Troy Gilbert

Sent: Thursday, May 31, 2007 10:19 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Disable Clicks while on busyCursor



Is it just me, or is it a bit surprising that we've got to hack  
something together to handle this? Come on, Adobe... what's a  
proper solution (and why wasn't it built into the CursorManager!)?  
I've got enough asynchronous problems to deal with than have to  
worry that the user's going to go off willy-nilly clicking buttons  
while the busy cursor is being shown. I understand that some folks  
may not want it to *always* prevent mouse clicks, but a little  
boolean flag (or two) in the CursorManager that prevents mouse  
clicks and/or focus changes/keyboard events would be very, very nice.


Troy.


On 5/31/07, Anthony Lee [EMAIL PROTECTED] wrote:

 - Make all your active components register themselves then loop  
through

 and disable/enable them according to your busy state

 Too taxing on cpu...

How many components are we talking about?

Hack #3
Generate an Alert and position it outside the viewable area.  
They're modal by default... meaning the user shouldn't be able to  
click on anything till you clear it.


Anthony








Regards,

Bjorn Schultheiss
Senior Developer

Personalised Communication Power

Level 2, 31 Coventry St.
South Melbourne 3205,
VIC Australia

T:  +61 3 9674 7400
F:  +61 3 9645 9160
W:  http://www.qdc.net.au

((This transmission is confidential and intended solely  
for the person or organization to whom it is addressed. It may  
contain privileged and confidential information. If you are not the  
intended recipient, you should not copy, distribute or take any  
action in reliance on it. If you believe you received this  
transmission in error, please notify the sender.---))




[flexcoders] Re: Disable Clicks while on busyCursor

2007-06-01 Thread Bjorn Schultheiss
Al, 

you mentioned the 'mouse shield' in the modal situation.
This is cool, but does the alpha setting of this shield have an affect
on the application rendering speed?
Hence, animations running behind this shield slowing in performance?




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

 Try calling validateNow after setting enabled to false.
 
  
 
 Animations can shut down validatiom.  If you can disable and re-validate
 before the animations start, that would be best.
 
  
 
 However, what it does, and what modal dialogs do is put up a mouse
 shield over the whole app.  It's a relatively easy thing to do, and I
 wouldn't want to put it in CursorManager as it really doesn't have
 anything to do with cursors.  You could have a progress bar and no busy
 cursor and still want to block.  Maybe we need to see if we can come up
 with a best practice for how to use application.enabled.
 
  
 
 -Alex
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of Bjorn Schultheiss
 Sent: Thursday, May 31, 2007 11:13 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Disable Clicks while on busyCursor
 
  
 
 This is quite slow.
 I wait for the app to disable, then any animations running while the
 app is disabled lag.
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 , Alex Harui aharui@ wrote:
 
  Did you try Application.application.enabled = false?
  
  
  
  
  
  From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 [mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 ] On
  Behalf Of Troy Gilbert
  Sent: Thursday, May 31, 2007 10:19 AM
  To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com 
  Subject: Re: [flexcoders] Disable Clicks while on busyCursor
  
  
  
  Is it just me, or is it a bit surprising that we've got to hack
  something together to handle this? Come on, Adobe... what's a proper
  solution (and why wasn't it built into the CursorManager!)? I've got
  enough asynchronous problems to deal with than have to worry that the
  user's going to go off willy-nilly clicking buttons while the busy
  cursor is being shown. I understand that some folks may not want it to
  *always* prevent mouse clicks, but a little boolean flag (or two) in
 the
  CursorManager that prevents mouse clicks and/or focus changes/keyboard
  events would be very, very nice. 
  
  Troy.
  
  
  
  On 5/31/07, Anthony Lee anthony.f.lee@
  mailto:anthony.f.lee@  wrote:
  
   - Make all your active components register themselves then loop
  through 
   and disable/enable them according to your busy state 
  
   Too taxing on cpu...
  
  How many components are we talking about?
  
  Hack #3
  Generate an Alert and position it outside the viewable area. They're
  modal by default... meaning the user shouldn't be able to click on
  anything till you clear it. 
  
  Anthony
 





Re: [flexcoders] Disable Clicks while on busyCursor

2007-05-31 Thread Bjorn Schultheiss

I'm looking over this problem again

It seems with the previous suggestions i've run into a couple of  
problems.


 - How about stage.mouseChildren = false ?
stage or Application.application don't seem to work, as in disabling  
the entire displayList()...


 - Enable/disable a transparent button that's as big as the stage  
and has the greatest z depth / lowest childIndex...

This slows down any rendering running behind the button.

 - Make all your active components register themselves then loop  
through and disable/enable them according to your busy state

Too taxing on cpu...


Are there any other methods you guys use for this?


regards,

Bjorn



On 05/03/2007, at 5:23 PM, Bjorn Schultheiss wrote:


Hey,

Is there a way to disable all mouse clicks while CursorManager is set
to busyCursor?

Regards,

Bjorn







Re: [flexcoders] sandbox error

2007-05-28 Thread Bjorn Schultheiss
A swf www.abc.com cannot dl data from localhost without a policyFile  
on localhost.
If you place a policyFile on the server hosting mysql and allow the  
server where your swf resides you 'should' be alright.


regards,

Bjorn


On 28/05/2007, at 6:23 PM, li.wen wrote:



Hello,

Such as, mysql server I am using is localhost:3066 in my server.  
And my server has address www.abc.com. The swf file runs as  
www.abc.com/abc/abc.swf. Does it count in same domain?


Regards,
Joe
- Original Message -
From: John Robinson
To: flexcoders@yahoogroups.com
Sent: Monday, May 28, 2007 2:00 AM
Subject: Re: [flexcoders] sandbox error

I'm not quite sure what it is you're doing, but it sounds like  
you're talking directly to mysql over a socket connection. I'd be  
very careful in doing so in that all of your mysql authentication  
info is included in the swf file. The swf can be easily decompiled  
and your database compromised.



I'd look into using server-side technology to handle the mysql  
interaction CF/PHP/etc.


Aside from that, you're swf once uploaded is running in whatever  
domain you uploaded it to. If you want to disregard the above, and  
just get it working, make sure mysql and the swf are running on the  
EXACT same domain.



John Robinson - Flash/Flex Developer at large
Blog: http://jrobinsonmedia.wordpress.com


On May 27, 2007, at 5:03 AM, li.wen wrote:


Hello all,

I am using flash.net.Socket class to connect mysql database. And I  
always meet sandbox violation error. I have some questions  
regarding this problem.


1) When I develop the flex application and mysql database  
(localhost:3066 is used) in same machine, there is no sandbox   
violation box error, since they are considered as in the same  
domain. Am I correct?
2) After I upload the flex application the server which is  
equipped with mysql, I access the flex application from client  
machine. Firstly the flex application will be downloaded to the  
client machine's cache, then start to execute. Now flex  
application and mysql database are considered as in different  
domain, and the sandbox violation may happen?
3) In order to solve it, I need to enable mysql remote access? Set  
mysql server address to digital format (xxx.xxx.xxx.xxx) to  
instead of localhost?

4) Or alternative way to solve it is to set crossdomain.xml file?
Thank you.

Regards,
Joe









Regards,

Bjorn Schultheiss
Senior Developer

Personalised Communication Power

Level 2, 31 Coventry St.
South Melbourne 3205,
VIC Australia

T:  +61 3 9674 7400
F:  +61 3 9645 9160
W:  http://www.qdc.net.au

((This transmission is confidential and intended solely  
for the person or organization to whom it is addressed. It may  
contain privileged and confidential information. If you are not the  
intended recipient, you should not copy, distribute or take any  
action in reliance on it. If you believe you received this  
transmission in error, please notify the sender.---))




Re: [flexcoders] Re: FileReference upload request does not get to the servlet in Unix comp

2007-05-24 Thread Bjorn Schultheiss

Make sure you're using a fully qualified path name.

Also I believe it makes a test post first, if that post fails it  
doesn't make the actual upload call.
Although the server guys here do not believe me as they do not see  
any reference of a test post made in the servlet logs.

But I'm sure it happens.


On 25/05/2007, at 11:36 AM, Bjorn Schultheiss  wrote:


Usually the upload will not take place if the player detects a
 possible error prior to making the upload..





Re: [flexcoders] FileReference upload request does not get to the servlet in Unix comp

2007-05-23 Thread Bjorn Schultheiss

There may be characters in the image filename that need to be escaped?
Do you make the upload call in a try catch block?

Usually the upload will not take place if the player detects a  
possible error prior to making the upload..



regards,

Bjorn


On 24/05/2007, at 2:40 PM, ivansebastiansurya wrote:


Hi everyone,

I've got a funny problem with my Flex application.
I've got a client that lets user upload File to a Java servlet (image
file).
It works fine when I run it in WIndows machine using any browser.
But when I run it in Unix/Linux machine, it seems that the upload
request never reaches the server.
Does anyone know what to do here? Any help is greatly appreciated.
Thanks a lot in advance.

Thanks,

Ivan.








[flexcoders] Sound Security Errors

2007-05-18 Thread Bjorn Schultheiss
When loading sound files from a remote domain without a policyfile  
how do I catch security errors.

I cant find any help in the documentation.


Regards,

Bjorn Schultheiss 

Re: [flexcoders] tree event using cairngorm

2007-05-17 Thread Bjorn Schultheiss
You can call methods on the tree via binding by using the observe tag  
discussed by Alex Ulhmann



On 18/05/2007, at 12:15 PM, Thind, Aman wrote:



Hey Adam,

Maintain the state of the tree in your model and map this state to  
the tree in your View using Data Binding.


The command changes the state and the bindings refresh your view.

You don't need to explicitly call methods on the tree.

Cheers,
Aman

From: flexcoders@yahoogroups.com  
[mailto:[EMAIL PROTECTED] On Behalf Of achegedus

Sent: Thursday, May 17, 2007 10:28 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] tree event using cairngorm

Hi Everyone!

I'm trying to write a dynamic tree using cairngorm, and I ran into  
a problem. I want to be
able to expand a node, have it go to my webservice, return the xml  
and open the node. In
the command that is handling the response to the webservice, i need  
to call the expandItem

method of the tree. And there's the trouble...

How do I call a method for a flex tree from a cairngorm command?

Any suggestions??

Thanks,
Adam


- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -  
- - - - - - - - - - This message is intended only for the personal  
and confidential use of the designated recipient(s) named above. If  
you are not the intended recipient of this message you are hereby  
notified that any review, dissemination, distribution or copying of  
this message is strictly prohibited. This communication is for  
information purposes only and should not be regarded as an offer to  
sell or as a solicitation of an offer to buy any financial product,  
an official confirmation of any transaction, or as an official  
statement of Lehman Brothers. Email transmission cannot be  
guaranteed to be secure or error-free. Therefore, we do not  
represent that this information is complete or accurate and it  
should not be relied upon as such. All information is subject to  
change without notice.





Regards,

Bjorn Schultheiss
Senior Developer

Personalised Communication Power

Level 2, 31 Coventry St.
South Melbourne 3205,
VIC Australia

T:  +61 3 9674 7400
F:  +61 3 9645 9160
W:  http://www.qdc.net.au

((This transmission is confidential and intended solely  
for the person or organization to whom it is addressed. It may  
contain privileged and confidential information. If you are not the  
intended recipient, you should not copy, distribute or take any  
action in reliance on it. If you believe you received this  
transmission in error, please notify the sender.---))




Re: [flexcoders] XMLNS to use same components in multiple projects

2007-05-16 Thread Bjorn Schultheiss
you can refer to your mxml-manifest.xml file found in the {FlexSDK}/ 
frameworks dir.

that way you can use xmlns:myComps=http://whatever.com/mxml/;

So basically you set your compiler to also read your new manifest file.


Bjorn

On 17/05/2007, at 1:53 AM, boy_trike wrote:

I have a few custom componets that I want to use in multiple  
projects. How can I set up a
nameSpace in each application that will reference a specific folder  
on my computer? Sort of

like XMLNS:myComps=c:\flex\mycomponents\*

Thanks
Bruce








Re: [flexcoders] Why no scroll bar?

2007-05-16 Thread Bjorn Schultheiss
I think its due to the way your application swf is inserted into the  
html.


It might pay to create a container within mx:Application that has  
its minWidth set.
That way you will still get your application scope scroll bars when  
the window is resized below 1024 width.



Bjorn


On 17/05/2007, at 1:51 AM, Ian Skinner wrote:

I have my base mx:Application... tag set with a minWidth=1024.  
When
the browser is less this this width no scroll bars are available  
leaving
the hidden content unaccessible. Why is this and how can I allow  
access

to the hidden content?

mx:Application xmlns:mx=http://www.adobe.com/2006/mxml;
layout=absolute
creationComplete=getCalendar()
minWidth=1024
verticalScrollPolicy=off horizontalScrollPolicy=on
xmlns:mcViews=Flex.Views.*







Re: [flexcoders] Blue-Green Background color / image

2007-05-16 Thread Bjorn Schultheiss

I think the blue-green background is set in your application scope.
For example if you set Application.backgorundColor to #FF you  
should get a white screen flicker.


Bjorn

On 17/05/2007, at 2:31 AM, bsausser wrote:


Tried LiveDocs: but flickers the blue-green color and/or image.
styleName=plain
mx:Style ... /mx:Style

How can I set 1) my own color; 2) my own image; or 3) transparency
where it will not flicker the blue-green background?

Brian








Re: [flexcoders] Communication of data between parent and child movie.

2007-05-16 Thread Bjorn Schultheiss

Using the inbuilt event dispatching system is your best bet.
That way you can have your parent(s) and child(s) loosely coupled.

There are particular design patterns that also deal with this issue.
Personally i like the combination of DataBinding, ModelLocator 
(Singleton) and Commands, ala Cairngorm :)



Bjorn


On 17/05/2007, at 8:58 AM, ivansebastiansurya wrote:


Hi everyone,

Currently I have to write a Flex application that holds other swf
application within it (I will have a skeleton swf movie with menu on
the left hand side and when a menu item is clicked, the corresponding
sub application is loaded on the right hand side, onto an Image
control).

The problem is that how can we propagate information from the child
movie to the parent movie and vice versa? Say the sub movie does the
login procedure and return the authentication information, how can I
pass this information to the parent movie so that it can be used to
control the access given to this particular user?


Re: [flexcoders] Equivalent of Application.application.globalVar in a Module

2007-05-16 Thread Bjorn Schultheiss
Without testing, i'm pretty sure even parentApplication refers to  
Application so you might be out of luck.
You could have a shell singleton and then register each module  
singleton via a string reference.
so you could use something like var s:ModuleSingleton =  
ShellSingleton.getInstance().getSingleton('module1');

registerSingleton();
removeSingleton();
hasSingleton();

Thats one solution, perhaps not the most elegant.


Bjorn


On 17/05/2007, at 7:49 AM, passive_thoughts wrote:


To create 'global' variables in flex without resorting to using a
singleton, the 'recommended way' seems to be using public variables in
the mx:application and then accessing them via
Application.application, as outlined here
http://livedocs.macromedia.com/flex/2/docs/0843.html

When using modules, Application.application will always refer to the
shell application not to mx:modulehas anyone figured out how to
create quasi module scoped global variables? (I can't use a singleton
since I will be loading multiple instances of the same module)

V








Re: [flexcoders] Filtering Best Practices Question

2007-05-16 Thread Bjorn Schultheiss

With a complex objects list this is difficult.
I would suggest doing it server side.

If the lists contained numerical or string items  you could rely on  
sorting to make your iteration process shorter.



Bjorn


On 17/05/2007, at 4:36 AM, Nate Pearson wrote:


What's the best practice when you have to compare two large lists? My
main list is 9000 objects long. I have to compare this to another
list which might have 4000 objects in it.

Right now I'm doing it the WRONG way. For each row in the Main list i
iterate through every item in the 4000 objects. As soon as I hit a
match I return a true and that exits the iteration. This is still a
very slow process.

Both lists are dynamic.

Any ideas on the right way to do this?

Thanks,

Nate








[flexcoders] Remote crossdomain issues

2007-05-14 Thread Bjorn Schultheiss

Hey,

When i attempt to load remote assets from a remote domain and specify  
the port as part of the url the load seems to break.


For example if i specify
http://remotedomain/asset.png //works fine
but
http://remotedomain:8080/asset.png //dies

my crossdomain file is,

cross-domain-policy
allow-access-from domain=* to-ports=* secure=false /
/cross-domain-policy


Is this a known issue?
Is there a work around?

regards,

Bjorn

Re: [flexcoders] AVM1Movie wrong size

2007-05-08 Thread Bjorn Schultheiss
The stage object of the AVM1Movie object may have the values your  
looking for.



On 09/05/2007, at 3:32 AM, Alex Harui wrote:



If you are using SWFLoader, make sure scaleContent=false

From: flexcoders@yahoogroups.com  
[mailto:[EMAIL PROTECTED] On Behalf Of richard druce

Sent: Monday, May 07, 2007 6:59 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] AVM1Movie wrong size

Hi,

I am loading an swf as an AVM1Movie from an external site. It  
appears as
though its coming out larger than its width and height indicate it  
should
be. I've tried drawing a rectangle over the top of it using the  
same width

and height but it appears to be smaller. I'm sure this shouldn't be
happening so I was wandering if anyone had encountered a similar issue
before (the scaleX and scaleY are 1 also). Any help is much  
appreciated.


cheers,
Richard.

__
Advertisement: Win a trip to the exquisite Daintree Ecolodge  Spa in
Cairns, QLD!
http://ninemsn.com.au/share/redir/adTrack.asp? 
mode=clickclientID=781referral=hotmailtaglineMayURL=http:// 
music.ninemsn.com.au/compIntro.aspx?compId=2386







Regards,

Bjorn Schultheiss
Senior Developer

Personalised Communication Power

Level 2, 31 Coventry St.
South Melbourne 3205,
VIC Australia

T:  +61 3 9674 7400
F:  +61 3 9645 9160
W:  http://www.qdc.net.au

((This transmission is confidential and intended solely  
for the person or organization to whom it is addressed. It may  
contain privileged and confidential information. If you are not the  
intended recipient, you should not copy, distribute or take any  
action in reliance on it. If you believe you received this  
transmission in error, please notify the sender.---))




Re: [flexcoders] Can I just bypass Cairngorm events?

2007-05-08 Thread Bjorn Schultheiss

Hey Mike,

It helps decouple the view and controller.
If you hard hard-wire your view to controller you are essentially  
adding just  logic to your view.


There's been talk around 'ditching' the controller out of MVC and a  
lot of developers have.
Check this post, http://weblogs.macromedia.com/sho/archives/2005/08/ 
flexflash_archi.cfm



In terms of Delegates i find it a useful link between commands and  
remote services.
Although i haven't yet applied this to FDS, or a 'producer, consumer'  
process.



regards,

Bjorn


On 09/05/2007, at 1:51 PM, munkydung wrote:


I've currently building a medium-large size application in Flex using
Cairngorm. I've already decided not to use 'delegates'. Instead, I'm
just updating the 'model' from within 'commands'. Now I'm seeing a
pattern where each 'event' I create is just a container for a data
structure to a 'command'. Also, it seems the mapping of 'events' is
one-to-one for 'commands'.

So, my question is, why not just do away with the 'events' and have
views call 'command.execute()'?

Someone talk me out of this...

thanks,
Mike








[flexcoders] Loader and cross-domain

2007-05-07 Thread Bjorn Schultheiss

Hey,

I'm loading jpg's from a remote domain and wish to perform extract  
pixel data from the loaded assets.


I have specified a loaderContext object in the Loader.load().

something like:
var lc:LoaderContext = new LoaderContext();
lc.checkPolicyFile = true;
_loader = new Loader();
_loader.load( new URLRequest(_dataProvider), lc);

When the executes load process totally fails, no events are  
dispatched from the loader object.


If i comment out the checkPolicyFile line my image loads fine.
var lc:LoaderContext = new LoaderContext();
//lc.checkPolicyFile = true;
_loader = new Loader();
_loader.load( new URLRequest(_dataProvider), lc);

I have a crossdomain file at the root of the domain that i am loading  
the image from.

I can see in serviceCapture that this is actually getting loaded.

This is the crossdomain file i am currently testing with.
?xml version=1.0?
cross-domain-policy
  allow-access-from domain=* /
/cross-domain-policy


Can anyone tell me why the remote asset does not load when i specify  
checkPolicyFile to equal true?






regards,

Bjorn

Re: [flexcoders] Loader and cross-domain

2007-05-07 Thread Bjorn Schultheiss

My bad...
Tests proved this not the case.




On 08/05/2007, at 3:06 PM, Bjorn Schultheiss wrote:


Hey,


I'm loading jpg's from a remote domain and wish to perform extract  
pixel data from the loaded assets.


I have specified a loaderContext object in the Loader.load().

something like:
var lc:LoaderContext = new LoaderContext();
lc.checkPolicyFile = true;
_loader = new Loader();
_loader.load( new URLRequest(_dataProvider), lc);

When the executes load process totally fails, no events are  
dispatched from the loader object.


If i comment out the checkPolicyFile line my image loads fine.
var lc:LoaderContext = new LoaderContext();
//lc.checkPolicyFile = true;
_loader = new Loader();
_loader.load( new URLRequest(_dataProvider), lc);

I have a crossdomain file at the root of the domain that i am  
loading the image from.

I can see in serviceCapture that this is actually getting loaded.

This is the crossdomain file i am currently testing with.
?xml version=1.0?
cross-domain-policy
  allow-access-from domain=* /
/cross-domain-policy


Can anyone tell me why the remote asset does not load when i  
specify checkPolicyFile to equal true?






regards,

Bjorn




Regards,

Bjorn Schultheiss
Senior Developer

Personalised Communication Power

Level 2, 31 Coventry St.
South Melbourne 3205,
VIC Australia

T:  +61 3 9674 7400
F:  +61 3 9645 9160
W:  http://www.qdc.net.au

((This transmission is confidential and intended solely  
for the person or organization to whom it is addressed. It may  
contain privileged and confidential information. If you are not the  
intended recipient, you should not copy, distribute or take any  
action in reliance on it. If you believe you received this  
transmission in error, please notify the sender.---))




Re: [flexcoders] Re: Will Microsoft's new Silverlight Player Kill our beloved Flex ?

2007-05-03 Thread Bjorn Schultheiss

Time to go home... Never!

I'm with Weyert on this one as well, Browser restrictions make my job  
difficult.



Bjorn

On 03/05/2007, at 5:52 PM, Weyert de Boer wrote:


No problem! You got my email address. Remind me offlist and I will
respond tomorrow. Time to go home. :)







Re: [flexcoders] Loading Fonts at runtime on OSX?

2007-05-01 Thread Bjorn Schultheiss

Depends what you ate or drank the night before,
I mean the smell is probably interesting than what it looks like.

What it tastes like is a whole other story ;)

Just kidding, Alex...


On 01/05/2007, at 4:24 PM, Alex Harui wrote:



What does the vomit look like?  And what does the FontHolder class  
look like?




From: flexcoders@yahoogroups.com  
[mailto:[EMAIL PROTECTED] On Behalf Of joshuajnoble

Sent: Monday, April 30, 2007 6:29 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Loading Fonts at runtime on OSX?



Wondering if anyone else has run into this: I'm loading fonts at
runtime via a swf that has a font embedded in it. I can't get the font
embedded on my OSX machine, so I compile the font swf on my pc and
then bring it over to my OSX machine and try to load it into the
application swf like so:

private function fontSWFLoaded(event:Event):void
{
var holder:Class =
event.target.applicationDomain.getDefinition(FontHolder) as Class;
Font.registerFont( holder.Kartika );
videoOverlay.overlay.fontLoaded();
}

It vomits every time on Font.registerFont. This exact same code works
fine on my PC. Now, I don't have Kartika
installed on my mac, which could be part of the problem I suppose so
my next is going to be trying with Arial, but does anyone have any  
ideas?










Re: [flexcoders] Deploying Flex Applications

2007-04-30 Thread Bjorn Schultheiss

The bin folder should be enough.

The error says your application is trying to reference your local  
filesystem.

Not sure why?


On 30/04/2007, at 4:04 PM, dexsense wrote:


Hi,

How are all of you? Many thanks for past answers. Wel thanks God, I
have completed my first application. Now I just want to know how to
deploy it on my remote server. I try to copy the bin folder and run
the application but it gave me error. I also try to copy the whole
project folder to my remote server. Nothing works. It keeps giving the
following error:

Error #2148: SWF file
file:///C|/phpdev/www/healthinn/MyFirstProject.swf cannot access local
resource file:///C|/phpdev/www/healthinn/Data/headerAnimData.xml. Only
local-with-filesystem and trusted local SWF files may access local
resources.

Although the error definition is too long. But I think that the above
given error is enough. If you need further information, pleae let me
know. But kindly help me with this. I badly need it.

I shall be very thankful to you.

Best Regards
..::DW





Regards,

Bjorn Schultheiss
Senior Developer

Personalised Communication Power

Level 2, 31 Coventry St.
South Melbourne 3205,
VIC Australia

T:  +61 3 9674 7400
F:  +61 3 9645 9160
W:  http://www.qdc.net.au

((This transmission is confidential and intended solely  
for the person or organization to whom it is addressed. It may  
contain privileged and confidential information. If you are not the  
intended recipient, you should not copy, distribute or take any  
action in reliance on it. If you believe you received this  
transmission in error, please notify the sender.---))




Re: [flexcoders] Error: default arguments may not be interspersed with other options

2007-04-30 Thread Bjorn Schultheiss
I copied my SDK into /Library/Flex2SDK/ therefore removing any folder  
name issues.


Hopefully thats your only issue..


On 30/04/2007, at 2:03 PM, Shailesh Mangal wrote:

I am trying to run my command line ant build (working on windows)  
on my mac. I got following error.

Error: default arguments may not be interspersed with other options


Wondering if there mac geeks out there who have already solved  
this. I looked for thishere , but couldnt figure out. I believe its  
something to do with the space in the path. I am using default  
installation location for Flex SDK


/Applications/Adobe\ Flex\ Builder\ 2\ Plug-in/Flex\ SDK\ 2/

and my project doesnt have any path in it. Any suggestions?




Regards,

Bjorn Schultheiss
Senior Developer

Personalised Communication Power

Level 2, 31 Coventry St.
South Melbourne 3205,
VIC Australia

T:  +61 3 9674 7400
F:  +61 3 9645 9160
W:  http://www.qdc.net.au

((This transmission is confidential and intended solely  
for the person or organization to whom it is addressed. It may  
contain privileged and confidential information. If you are not the  
intended recipient, you should not copy, distribute or take any  
action in reliance on it. If you believe you received this  
transmission in error, please notify the sender.---))




Re: [flexcoders] Re: Will Microsoft's new Silverlight Player Kill our beloved Flex ?

2007-04-29 Thread Bjorn Schultheiss
Title: QDC - Bjorn Signature
Hey Jason,Even if 90% of internet's users are running Windows, how many millions aren't..If you can deploy applications that is guaranteed to only be used by Windows users, well good luck to you.Here we target creatives in the advertising industry and I don't have that luxury.Regards, Bjorn Schultheiss Senior Developer Personalised Communication Power Level 2, 31 Coventry St.South Melbourne 3205,VIC AustraliaT:  +61 3 9674 7400F:  +61 3 9645 9160W:  http://www.qdc.net.au ((This transmission is confidential and intended solely for the person or organization to whom it is addressed. It may contain privileged and confidential information. If you are not the intended recipient, you should not copy, distribute or take any action in reliance on it. If you believe you received this transmission in error, please notify the sender.---))One person wrote: Everybody uses Windows, almost all the workstations are windows. Macs have IE working OK. Another responded:Think again."Think again?"  What kind of an argument is that?  People keep brining up certain technlogies not working on Mac OS or Linux as a bad thing.  Personally, I've never bought into the, "that technology does not support obscure browser "X" or non-Windows operating system "Y" and therefore is doomed to fail" argument.  As much as I wish it were not true, Microsoft is one example of a company who has time and again developed solutions for Windows only and been quite successful at it.  Not supporting Mac or Linux WILL hurt you a little, but it's still a Windows world (unfortunately) and thus there is a huge market there to tap.   The world is changing, sure, but very very slowly in this regard. At the same time, I think Silverlight is coming out a little too late - the RIA runtime has already left the barn IMO. Jason Merrill Bank of America  GTO Learning  Leadership Development eTools  Multimedia Team  

Re: [flexcoders] Rumor of the day: Silverlight sourcode public

2007-04-29 Thread Bjorn Schultheiss

http://www.codeplex.com/Project/ProjectDirectory.aspx?TagName=WPF


Would be nice if they came with their own runtime for MacOSX and Linux


That would be major!




On 30/04/2007, at 8:12 AM, Weyert de Boer wrote:


see:
http://www.infoworld.com/article/07/04/27/MS-open-source- 
Silverlight_1.html?source=rssurl=http://www.infoworld.com/article/ 
07/04/27/MS-open-source-Silverlight_1.html


Sounds like a good idea for MSFT but not sure if this is a good  
plan for

Adobe, though. Anyways this is a rumor lets see if it can be falsified
next week ;) Now still we need to run VMWare to get the Expression
software running... I haven't spotted any plans for a MacOSX or Linux
tool...

Would be nice if they came with their own runtime for MacOSX and Linux
g Not that Mono ain't kicking ass !!

Yours,
Weyert







Re: [flexcoders] Re: Will Microsoft's new Silverlight Player Kill our beloved Flex ?

2007-04-29 Thread Bjorn Schultheiss

I am of the same opinion.
At the recent WebDU conference I spotted 1 presenter with a PC  
notebook, all the rest were macbooks.


I am quite a fan of a lot of non-windows based software, and i enjoy  
building flash-based applications that can be deployed on either OS.




regards,

Bjorn

On 30/04/2007, at 1:00 PM, dorkie dork from dorktown wrote:

the problem with microsoft is they live in a bubble. they live in  
their own little world where only windows exists. well, at the  
college i visit half the people have macs. i am in a college  
coffee / study shop with about 150 people and half have macs. this  
all changed when the mac books came out last year. long time  
windows users switched. my roomate uses a mac and loves it. not  
everyone uses windows.


i dont' trust their cross compatible promises either. what if they  
do make version on mac. anyone remember ie on mac? they need to  
prove they have changed the way they do things (and think) before i  
would ever trust them.


since i'm ranting, it seems, that users opinions don't matter. all  
they need to do is listen to their users and i do not get that from  
them. vista is an example of them living in a bubble. so as the web  
changes i do not think silverlight will progress when they do not  
listen to the users.




On 4/29/07, simonjpalmer [EMAIL PROTECTED] wrote:
Does C# kill Java?
Does IE kill Firefox?
Does SQLServer kill Oracle?
Does Windows kill UNIX?
Will Silverlight kill Flex?

From my 20 odd years of software development, during which time the
Microsoft hegemony has been at its apogee, none of the above are true.
In fact if you want a really scalable enterprise platform you would
choose the right hand side of the list above rather than the left.

Where Microsoft win hands down is in Office Applications and desktop
operating systems. Excel is quite possibly the best piece of desktop
software ever written (Word being the worst) and long may it reign as
such. Windows is crap, but it's more than good enough for your
average user and most Microsoft desktop products are actually pretty
good (c'mon, be generous).

I regret deeply that the rest of the world doesn't have a house full
of beautiful, stable, simple Macs like I do, but the reality is that
they don't as Jason points out. Instead the three or four computers
the normal person interacts with in their daily lives are almost
exclusively running Windows (even the ATM machines and tills at the
supermarket). Not a pleasant truth, but a truth nonetheless. If you
are looking for broad adoption and commercial success as a software
company you start with Windows.

The wonderful reality, however, is that the software industry, like
all others in the history of human endeavour, thrives on competition
and there is space for more than one company/product/offering to
survive. Adobe are not going to be Microsoft. THANK GOD! They have
and in my opinion will always have, a distinct and separate offering.
If they can't retain that differentiation then they don't deserve to
remain in business and the market will take care of them.

So this is a bit of a silly thread as far as I am concerned. The
answer for me is clearly No for all the same reasons that Microsoft
haven't killed any of the other things on the list at the top. They
might try, but I think they should be more worried about Google and
web based desktop software than Adobe and the flash player.

Simon

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





 Hey Jason,

 Even if 90% of internet's users are running Windows, how many
 millions aren't..
 If you can deploy applications that is guaranteed to only be used by
 Windows users, well good luck to you.

 Here we target creatives in the advertising industry and I don't  
have

 that luxury.




 Regards,

 Bjorn Schultheiss
 Senior Developer
 
 Personalised Communication Power

 Level 2, 31 Coventry St.
 South Melbourne 3205,
 VIC Australia

 T: +61 3 9674 7400
 F: +61 3 9645 9160
 W: http://www.qdc.net.au

 ((This transmission is confidential and intended solely
 for the person or organization to whom it is addressed. It may
 contain privileged and confidential information. If you are not the
 intended recipient, you should not copy, distribute or take any
 action in reliance on it. If you believe you received this
 transmission in error, please notify the sender.---))



 One person wrote:
  Everybody uses Windows, almost all the workstations are  
windows. Macs

  have IE working OK.

 Another responded:
 Think again.
 Think again? What kind of an argument is that? People keep
 brining up certain technlogies not working on Mac OS or Linux as a
 bad thing. Personally, I've never bought into the, that technology
 does not support obscure browser X or non-Windows operating system
 Y and therefore is doomed to fail argument. As much as I wish it
 were not true, Microsoft is one example of a company who has time  
and

 again developed

Re: [flexcoders] Re: Will Microsoft's new Silverlight Player Kill our beloved Flex ?

2007-04-29 Thread Bjorn Schultheiss

Yeah, I was using Windows on my MBP ;-)


Yes i noticed. mbp is the nicest notebook IMO.



Indeed! Developing GUI components for Windows is fun too, though.
Creating Grid components and such!


WPF is cool for sure, silverlight not so much.
At the moment Flash 9 and PV3D seems more interesting than silverlight.


regards,

Bjorn





On 30/04/2007, at 2:11 PM, Weyert de Boer wrote:


Bjorn Schultheiss wrote:


 I am of the same opinion.

 At the recent WebDU conference I spotted 1 presenter with a PC  
notebook,

 all the rest were macbooks.

Yeah, I was using Windows on my MBP ;-)

 I am quite a fan of a lot of non-windows based software, and i enjoy
 building flash-based applications that can be deployed on either OS.

Indeed! Developing GUI components for Windows is fun too, though.
Creating Grid components and such!

Yours,
Weyert de Boer







Re: [flexcoders] Re: Will Microsoft's new Silverlight Player Kill our beloved Flex ?

2007-04-27 Thread Bjorn Schultheiss

Which department?

Development.
Creative.

Windows does not have a monopoly.


On 27/04/2007, at 12:34 PM, Jeffry Houser wrote:



I think this is true for many enterprises. Not true for a lot of
developers.

At 09:41 PM 4/26/2007, Bjorn Schultheiss wrote:

Think again.



On 27/04/2007, at 11:26 AM, mvbaffa wrote:

Everybody uses Windows, almost all the workstations are windows.  
Macs

have IE working OK.

--
Jeffry Houser, Software Developer, Writer, Songwriter, Recording  
Engineer

AIM: Reboog711 | Phone: 1-203-379-0773
--
My Company: http://www.dot-com-it.com
My Podcast: http://www.theflexshow.com
My Blog: http://www.jeffryhouser.com
Connecticut Macromedia User Group: http://www.ctmug.com





Regards,

Bjorn Schultheiss
Senior Developer

Personalised Communication Power

Level 2, 31 Coventry St.
South Melbourne 3205,
VIC Australia

T:  +61 3 9674 7400
F:  +61 3 9645 9160
W:  http://www.qdc.net.au

((This transmission is confidential and intended solely  
for the person or organization to whom it is addressed. It may  
contain privileged and confidential information. If you are not the  
intended recipient, you should not copy, distribute or take any  
action in reliance on it. If you believe you received this  
transmission in error, please notify the sender.---))




Re: [flexcoders] FF and Java sessions

2007-04-26 Thread Bjorn Schultheiss

Dimitrios,

I actually get the same JSESSIONID value when i make an upload  
request to a servlet.
Although i am making a POST request and send vars via the  
URLVariables object.


example:
var req:URLRequest = new URLRequest 
( config_model.userConfig.datasetUpPath + /upload );

var urlVars:URLVariables = new URLVariables();
urlVars.id = upload_model.fileID;
urlVars.username = config_model.userConfig.username;
urlVars.password = config_model.userConfig.password;
req.data = urlVars;
req.method = URLRequestMethod.POST;

upload_model.artworkFileRef.upload( req );


Bjorn.


On 27/04/2007, at 7:38 AM, Dimitrios Gianninas wrote:



As some of you may already know, when performing a file upload with  
Flex to a Java servlet, a new session is created not matching the  
existing session the user has with the server when their Flex app  
actually loads.


I've read some posts and see that ppl are appending the JSESSIONID  
to the url to get the same session to be used by the server when an  
upload request is sent by a Flex app. By doing:


var req:URLRequest = new URLRequest(/billing/servlet/ 
FileSvlt;JSESSIONID= + jSessionId);


But this doesnt work for me any reason why? something I am  
doing wrong?


Dimitrios Gianninas
Developer
Optimal Payments Inc.

AVIS IMPORTANT

WARNING

Ce message électronique et ses pièces jointes peuvent contenir des  
renseignements confidentiels, exclusifs ou légalement privilégiés  
destinés au seul usage du destinataire visé. L’expéditeur original  
ne renonce à aucun privilège ou à aucun autre droit si le présent  
message a été transmis involontairement ou s’il est retransmis sans  
son autorisation. Si vous n’êtes pas le destinataire visé du  
présent message ou si vous l’avez reçu par erreur, veuillez cesser  
immédiatement de le lire et le supprimer, ainsi que toutes ses  
pièces jointes, de votre système. La lecture, la distribution, la  
copie ou tout autre usage du présent message ou de ses pièces  
jointes par des personnes autres que le destinataire visé ne sont  
pas autorisés et pourraient être illégaux. Si vous avez reçu ce  
courrier électronique par erreur, veuillez en aviser l’expéditeur.


This electronic message and its attachments may contain  
confidential, proprietary or legally privileged information, which  
is solely for the use of the intended recipient. No privilege or  
other rights are waived by any unintended transmission or  
unauthorized retransmission of this message. If you are not the  
intended recipient of this message, or if you have received it in  
error, you should immediately stop reading this message and delete  
it and all attachments from your system. The reading, distribution,  
copying or other use of this message or its attachments by  
unintended recipients is unauthorized and may be unlawful. If you  
have received this e-mail in error, please notify the sender.






Regards,

Bjorn Schultheiss
Senior Developer

Personalised Communication Power

Level 2, 31 Coventry St.
South Melbourne 3205,
VIC Australia

T:  +61 3 9674 7400
F:  +61 3 9645 9160
W:  http://www.qdc.net.au

((This transmission is confidential and intended solely  
for the person or organization to whom it is addressed. It may  
contain privileged and confidential information. If you are not the  
intended recipient, you should not copy, distribute or take any  
action in reliance on it. If you believe you received this  
transmission in error, please notify the sender.---))




Re: [flexcoders] Re: Will Microsoft's new Silverlight Player Kill our beloved Flex ?

2007-04-26 Thread Bjorn Schultheiss

Think again.



On 27/04/2007, at 11:26 AM, mvbaffa wrote:


Everybody uses Windows, almost all the workstations are windows. Macs
have IE working OK.





Re: [flexcoders] DeepCopy Built In?

2007-04-25 Thread Bjorn Schultheiss

There's an example in the docs.


On 26/04/2007, at 10:43 AM, Persaud, Anthony wrote:



Is there a built-in function to deep-copy an object?






Regards,

Bjorn Schultheiss
Senior Developer

Personalised Communication Power

Level 2, 31 Coventry St.
South Melbourne 3205,
VIC Australia

T:  +61 3 9674 7400
F:  +61 3 9645 9160
W:  http://www.qdc.net.au

((This transmission is confidential and intended solely  
for the person or organization to whom it is addressed. It may  
contain privileged and confidential information. If you are not the  
intended recipient, you should not copy, distribute or take any  
action in reliance on it. If you believe you received this  
transmission in error, please notify the sender.---))




<    1   2   3   4   5   >