Actionscript 3 :: Pass Proxy To Loaded Module In A PureMVC MultiCore App?

Oct 24, 2011

I'm creating a flash campaign which will be loaded into a client's framework, which I have no control over. The framework will already have loaded a few things such as locale, fonts and copy, and will pass these things to my swf upon initialization.

Since the size of my swf (let's call it the shell) is restricted it will in turn display a campaign-specific preloader and then load another swf (let's call this the campaign) with the rest of the site.

The shell and the campaign will both be PureMVC modules. The shell will create a few proxies and populate these with data passed from the framework (locale constants, fonts etc), before loading in the campaign.

When the campaign is loaded it too will need locale and fonts etc. so my question is, what is the best way to pass this data along to the campaign module from the shell module?

I could create the same proxies in the campaign module and load the data again, which will be cached, but this obviously feels like the wrong way to go.I've investigated the use of the pipes utility but this seems like a bit of an overkill in my case since the communication will be one-way and will just happen once during the initialization of the campaign.

Would it be "ok" from a design pattern point of view to pass the proxies to an init method of the campaign module and then register these proxies in the campaign module startup command? This seems wrong since these proxies have references to my shell application facade through notification names. Would it be ok if I move the notification names to some "NotificationConstants" class which both modules can use?

I could create similar proxies in the campaign module but this time populate them with the data objects from my old proxies passed to the previously mentioned init method? Spontaneously this feels like the best way to do it since the data objects don't have any references to my shell module but the "old" proxies do..

View 1 Replies


Similar Posts:


Actionscript :: Flex MultiCore PureMVC Notifier Initialization Error

May 27, 2011

I am trying to write a simple multicore PureMVC helloword. I am getting Error: multitonKey for this Notifier not yet initialized!

[Code]....

View 1 Replies

Flex :: Creating RobotLegs Module Within A PureMVC Shell Application

Oct 19, 2010

I'm working on an existing modular project that was built in PureMVC. Instead of converting everything over to RobotLegs, I want to create a new module using RobotLegs and plug it into the pureMVC shell. Currently, when the module loads, I get the following flash error: ReferenceError: Error #1065: Variable IMediatorMap is not defined.

Inititally, I thought it was because my module needed a pureMVC Mediator to call the pureMVC StartupCommand to get things "hooked up" and THEN create the RobotLegs' Context. However, that didn't work and I'm still getting the error.

View 2 Replies

Flex :: 4 - Pass Data To The Module

Apr 18, 2011

I have a Flex 4 application that loads a module. Everything works fine except that I cant create and object or cast an object to a type of my module. At run time it throws an error. I'm not sure if there is an issue with modules, Flex4, and spark? I've tried many different ways to set/cast these objects, but nothing seems to work.

[Code]....

View 1 Replies

Flash :: Uploading Images With Uploadify Run Into IO Error With Local Proxy (proxy.pac)?

Feb 21, 2010

I'm trying to upload images with Uploadify but I run into IO error. I have gotdemo and it works on my computer, so I decided to implement functionality of my application to this example step by step to catch the error and discovered that the reason of IO error is my local proxy.pac (I use FF):

function FindProxyForURL(url, host) {
if (shExpMatch(host, "*.app.local*")) {
return "PROXY 127.0.0.1:3000";

[code]....

View 1 Replies

Media Server :: Way To Pass Rtmp Call For A Live Stream Through A Proxy Server?

Mar 4, 2011

Somebody I know can't watch because they have a proxy server.The nc.connect() call to get the live stream fails because it goes direct from AS3 to FMS and doesn't go through the proxy server.

View 1 Replies

ActionScript 3.0 :: Loaded Swf Module Has No Stage Of It's Own?

Jun 10, 2010

I was unable to solve it, so I bought a module from the net that is AS3, and now guess what, the module is build around the stage-object (enterframe events, framerate,...). that's all fine when it is ran as standalone, but as loaded swf (into as3site) flash says the stage is NULL ??! How could i work around that, or I need to set it's stage to something, OR I need to attach enterframe-events to something else (but what then)?

View 2 Replies

Actionscript 3 :: Flex: Are Unused Module Project Files Included In The Module Swf's

Jan 11, 2011

Currently optimizing an application at work. There are many files in some of the module projects that are not used by the exported (release build) Module.swf's. Are these unused files included in the swf's?

View 1 Replies

ActionScript 3.0 :: MOUSE_MOVE Events Not Being Dispatched From Loaded Module?

Oct 3, 2009

I have a module, which is a simple swf file to load.

Inside there, in a modules document class I have a code like:

ActionScript Code:
buttonMode = true;
useHandCursor = true;

[Code]....

When I load the module, I can see the drawn background with proper sizes. However, the cursor is not hand (useHandCursor) and mouse events are not dispatched. They are only dispatched on some children of the document class, not on itself, on its own background. ANd the hand cursor is only over the children, not over the document class' background itself again.

The document class of the module extends Sprite.

View 9 Replies

Actionscript 3 :: Send Custom Event From One Module To Another Module?

Jan 2, 2012

I have created a modular application. I have two modules, for example Module1 and Module2.I have loaded these modules in my application. I am using Parsley in my application. I have loaded separate different context builder in both modules.

But when I am dispatching event from Module1, I am able to listen that event in that Module1 but I am trying to listen that event in another Module2. I am not able to listen that event in that Module2 through Parsley.

View 2 Replies

Flex :: Proper Method To Stop Loading A Module Before It Has Completely Loaded?

Jun 17, 2010

I seem to recall that Loader.unload() could once be used to stop loading a swf before it had finished loading. I can no longer find documentation or the blog where I read this. Perhaps it was an unofficial feature. Anyhow, IModuleInfo, returned by ModuleManager.getModule() has an unload() method. If I want to halt loading a Flex Module that is in progress, do I just call iModuleInfo_instance.unload()?

View 1 Replies

AS3 :: Flex - Module No More A Module When Extended?

Jan 25, 2010

I have created a module in Flex like below:

modules/ModuleBase.mxml
<?xml version="1.0" encoding="utf-8"?>
<mx:Module xmlns:mx="http://www.adobe.com/2006/mxml">

[code].....

View 1 Replies

Actionscript 3 :: Pass FlashVars To Loaded Swf?

Feb 20, 2010

I have a A.swf which loads B.swf onto a movieclip and needs to pass it some FlashVars. When loading B.swf with html, I can pass FlashVars fine. When passing from A.swf, it gets a

Error #2044: Unhandled ioError:. text=Error #2032: Stream Error. URL: file:

The code in A.swf is

var request:URLRequest = new URLRequest ("B.swf");
var variables : URLVariables = new URLVariables();
variables.xml = "test.xml";

[code]...

In B.swf, it is checking the Flashvars like so. It works fine from html side

this.loaderInfo.parameters.xml

View 4 Replies

ActionScript 3.0 :: Pass Parameters To A Loaded Swf?

Jan 26, 2009

I tried to find an answer here, but haven't.i am loading an AS2 swf inside an AS3 swf.the AS2 file needs some initial properties to get started (used to pass them through the flashVars).in Flex i used the SWFLoader.load() method and passed in the parameters through the url. (url..).since the flex swf output is heavy i would like to use the flash Loader class.is there a way to pass the parameters with the Loader class?or should i use LocalConnection methods to start the process externally?

View 2 Replies

ActionScript 3.0 :: How To Pass Parameters To Loaded Swf

Aug 28, 2010

I have installed DfGallery2 in my server and I would like to load it into my other swf. There's html version generated by the gallery : Quote:

<embed src="Gallery.swf" quality="high"width="500" height="500" FlashVars="xmlUrl=gallery/api/rest/get_gallery/1/json" allowFullScreen="true" type="application/x-shockwave-flash" />

What I want is to load Gallery.swf into Main.swf and see all the images. So how do I pass FlashVars from Main.swf to Gallery.swf?

View 5 Replies

ActionScript 2.0 :: Pass Variables To A Loaded Swf?

Apr 25, 2004

Is it possible to pass variables to a swf that is being loaded from another swf without using GET or POST or loadVariables?Maybe a function? If so what is the code?

View 6 Replies

ActionScript 2.0 :: Pass Flashvars To A Loaded Swf In A Target_mc?

Dec 25, 2008

I have a flash mp3 player that loads its info from an xml file and it works great. I'm trying to load this same player onto another website and have changed the domains, xml info, etc to load new songs. I want to have this swf be integrated into a larger site and not just loaded at the bottom of an html page.[code]...

View 3 Replies

ActionScript 3.0 :: Preloader To Pass Variable To Loaded Swf

Nov 21, 2008

I know this has been covered, I've read every post on this forum but I just can't make sense of it. I would like to pass a string variable from a preloader swf to the loaded one. My code's on the first frame on the timeline on both swfs and I'm not using classes. Here's my code for the preloader:

[Code]...

View 7 Replies

ActionScript 3.0 :: Pass A Variable To An Externally Loaded Swf?

Jan 19, 2009

In my main swf I set a string variable containing the name of the xml file that needs to load into an externally loaded swf file. How do I then pass that information into the external swf once it's loaded into the main swf? Is this possible?

View 4 Replies

ActionScript 3.0 :: How To Pass Parameter To Loaded Child

Dec 16, 2009

I have two movie clips:
1.main.swf
2.inner.swf
I'm adding the inner.swf somewhere in the main.swf using addChild (and it's added successfully).
all I want to do is to pass a parameter to the inner.swf or make the inner.swf reads a root value from main.swf.

View 4 Replies

ActionScript 3.0 :: Pass The Loaded Value To A Textfield Within The Parent Object?

Sep 23, 2008

I have instantiated an instance of a class that performs a URLload action. When that is complete I want to pass the loaded value to a textfield within the parent object. How do I pass the value out of the instantiated object to the parent object's textfield ?

View 3 Replies

Actionscript 3 :: Pass A Base Path To A Swf Loaded At Runtime?

Nov 11, 2010

I have a main.swf which loads a module.swf and the module.swf loads some assets.The module.swf works standalone and also needs to work when loaded by main.swf.But unfortunately the module.swf can't find the assets when loaded by main.swf because the assets aren't located relative to the main.swf, but are located relative to the module.swf.As I can't touch the module.swf and I'm also unwilling to change the directory structure, I am looking for a solution close to the a "base" parameter which can be used when a swf is embedded into html

View 3 Replies

ActionScript 3.0 :: Pass Parameters To A Function In Main Class From Loaded SWF?

Aug 15, 2011

I've got a main.as that loads SWF to the stage. the loaded SWF seppoused to pass a link to the main.as and trigger a javascript function to popUp that photo from that link.

I know there are two ways:
 
((root as MovieClip).parent.parent as Object).somefunction(parameters);
 
and to dispatch an event. inorder to pass parameters throug the event i need to extend it with another class.
 
isnt the (root as... )  more efficient if all i need is to pass a link?

View 7 Replies

Flash :: Pass Data Via Event From Swf1 To Swf2 Where Former Is Loaded In Later

Nov 30, 2010

I have a swf(Swf1)that dispatches a CustomEvent

[code]....

View 1 Replies

Actionscript :: Where To Register Mediator In Puremvc

Mar 17, 2010

Currently I am working on flex using puremvc framework. Actually my question is related to where to register mediator in puremvc framework. One of my colleague is registering mediator in views(components) creationComplete method only (inside view). While my preference is send some notification from creationComplete method which could be handle by some command and command will register mediator. So which one is better approach in terms of best practice ?

View 3 Replies

Flex :: BlazeDS/PureMVC And Shared Vos?

Apr 21, 2010

I'm building modular application with 2 modules which share common vo: ShopRegionVO

This vo is also a BlazeDS entity and is mapped to a remote java object. When shell loads first module everything is ok. The second module is a list of ShopRegionVOs and item change is handled with the following code:

sendNotification(CoverageConstants.SET_SELECTED_REGION_COMMAND, ShopRegionVO(List(e.target).selectedItem));

The exception is thrown right here:

Main Thread (Suspended: Error #1034: Type Coercion failed: cannot convert model.vo::ShopRegionVO@14961809 to model.vo.ShopRegionVO.)
view.list::RegionListMediator/onChange
flash.events::EventDispatcher/dispatchEventFunction [no source][code].....

View 1 Replies

Actionscript 3 :: One Way Deep Linking In PureMVC?

Sep 2, 2010

A project requirement is that it be 1 way deeplinkable(a specific query string will load a section within the swf).I have a URLProxy that I use for all external linking. It makes sense to me to put the query string logic in this proxy. So in the constructor, I check for a querystring, and then send a notification if it equals a predefined value.One problem with this is that I'd like to predefine this query string key value I am checking against in an external xml file. So another proxy, loads-parses this config xml, then the URL proxy checks against this.

View 1 Replies

Actionscript 3 :: PureMVC For Flash Games

Oct 20, 2011

I dont have any experiencie using this pattern when developing a game, except on a data driven website made mostly in Flex.The question is, are there any drawbacks of this pattern?, let say, performance for example?If anyone implemented a game using this framework.

View 1 Replies

ActionScript 3.0 :: PureMVC Or Gaia Framework?

Apr 19, 2010

Which framework is the best one to execute Website projects? I was researching around Flash website blogs and articles talking about the great advantage at daily production with these frameworks.In my case i'm used to get basic/intermediate projects that consists in Animations, Transitions between swf pages and at the most important point: liquid layouts.Gaia Framework seems to help a lot at organization and singular work time reduction spent.

View 4 Replies

Flex :: PureMVC: Unique Mediator For Each Tab In An Interface?

Oct 12, 2009

I am building a tabbed interface for switching between various similar layers. Each layer will have a number of graphs. By dragging with the mouse the graphs can be rearranged or even moved between layers. My question is, is it best practice to register a unique mediator for each layer that keeps track of the layers content / organization, or should i keep track of it all with one central mediator.some considerations:

the layer contents and organization will be saved(in a db) so that it can be restored when a user comes back to the app.the layers themselves are functionally identical.the user can add and remove layers at will.

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved