tag:robotlegs.tenderapp.com,2009-10-18:/discussions/problems/677-can-signalcontext-work-within-a-flexmobile-projectRobotlegs: Discussion 2012-11-20T11:20:51Ztag:robotlegs.tenderapp.com,2009-10-18:Comment/207865502012-11-13T18:20:55Z2012-11-13T18:20:55ZCan SignalContext work within a FlexMobile project?<div><p>I’ve just converted Joel’s RobotlegsSignalsCafe
(<a href=
"http://joelhooks.com/2010/02/14/robotlegs-as3-signals-and-the-signalcommandmap-example/">http://joelhooks.com/2010/02/14/robotlegs-as3-signals-and-the-signa...</a>)
to mobile.<br>
I didn’t have time to adjust all the components to make the
app look like the one for browser, but the signals work!</p>
<p>So, either you’re having trouble with the mobile part, or,
if you are an experienced mobile developer already, then maybe the
libraries you’re using aren’t up to date.</p></div>Ondina D.F.tag:robotlegs.tenderapp.com,2009-10-18:Comment/207865502012-11-13T20:42:30Z2012-11-13T20:42:30ZCan SignalContext work within a FlexMobile project?<div><p>Hi thanks for looking at this. The problem we noticed was when
attempting to debug on the device we got a blank screen. Do you
have a link I can download and test it out on a device?</p>
<p>thanks</p></div>miketag:robotlegs.tenderapp.com,2009-10-18:Comment/207865502012-11-14T10:46:49Z2012-11-14T10:46:49ZCan SignalContext work within a FlexMobile project?<div><p>Hi admin,<br>
No problem.</p>
<blockquote>
<p>Do you have a link I can download and test it out on a
device?</p>
</blockquote>
<p>I don’t know what you mean. If you mean an example, then
you can use the one I’ve modified yesterday (see attachment),
at your own risk ;)<br>
I can’t test it on a device, but, as I said, it works on the
desktop.</p>
<blockquote>
<p>The problem we noticed was when attempting to debug on the
device we got a blank screen.</p>
</blockquote>
<p>Have you tried to run a non-robotlegs application? If the blank
screen appears in a non-rl app, I think it’s an air bug or
something wrong with the sdk. At least I heard of such a bug a
while ago.<br>
Please let me know if the attached example is working on a device
or not.</p>
<p>Ondina</p></div>Ondina D.F.tag:robotlegs.tenderapp.com,2009-10-18:Comment/207865502012-11-14T11:08:00Z2012-11-14T11:08:00ZCan SignalContext work within a FlexMobile project?<div><p>Thanks for your help , It looks fine from here now , I think my
issue was converting a pure as3 project to flex mob Ile I needed to
convert my components</p>
<p>Sent from my HTC smartphone</p>
<p>----- Reply message ----- From: "Ondina D.F."
<a>tender+d8ef0d32056825aceda0a5c276087e374487cf2e7@tenderapp.com</a><br>
To: <a href=
"mailto:admin@orbitalmedia.com.au">admin@orbitalmedia.com.au</a><br>
Subject: Can SignalContext work within a FlexMobile project?
[Problems <a href="/discussions/problems/677" title=
"Discussion #677">#677</a>]<br>
Date: Wed, Nov 14, 2012 9:46 PM</p></div>miketag:robotlegs.tenderapp.com,2009-10-18:Comment/207865502012-11-14T16:37:20Z2012-11-14T16:37:20ZCan SignalContext work within a FlexMobile project?<div><p>Glad you sorted it out.</p></div>Ondina D.F.tag:robotlegs.tenderapp.com,2009-10-18:Comment/207865502012-11-15T23:13:27Z2012-11-15T23:13:27ZCan SignalContext work within a FlexMobile project?<div><p>Hi ondina. , I have looked at this a bit more and believe I
still have a problem. The code sample above uses mxml as the main
class , I am unable to get a pure hello world signal context demo
running in an as3 mobile project or within a flex mobile project ,
when I debug a simple demo the context view is always null , would
you be able to confirm that mxml is not needed to run signalcontext
in a mobile project ?<br>
thanks for all your help<br>
Mike</p></div>miketag:robotlegs.tenderapp.com,2009-10-18:Comment/207865502012-11-16T10:48:17Z2012-11-16T10:48:17ZCan SignalContext work within a FlexMobile project?<div><p>Hey Mike,</p>
<p>Have you tried out my example and it didn’t work?<br>
Or, you mean when you initialize the context in actionscript
instead of the declaration tag, it doesn’t work? If so, then
look at the pasted code bellow from a pure as3 mobile app, that I
just changed to make it work with SignalContext. When I debug it
(as a desktop emulation), it works fine.<br>
I have to say, I don’t use the SignalCommandMap in my own
projects, so, for the example I attached yesterday and the one I
modified today I used the old libraries, provided by Joel in his
example: as3-signals v 05, robotlegs 1.0.3. Maybe the SignalContext
has some issues when combined with the newer versions of signals
and rl?</p>
<p>All I’ve done in the pure as3 mobile version was:<br>
Main</p>
<pre>
<code>public class AsMobileSignals extends Sprite
{
private var context:ApplicationSignalContext;
public function AsMobileSignals()
{
super();
// support autoOrients
stage.align = StageAlign.TOP_LEFT;
stage.scaleMode = StageScaleMode.NO_SCALE;
addEventListener(Event.ADDED_TO_STAGE, onViewAdded);
}
protected function onViewAdded(event:Event):void
{
context = new ApplicationSignalContext(this);
}
}</code>
</pre>
<p>Context</p>
<pre>
<code>public class ApplicationSignalContext extends SignalContext
{
private var _view:Object;
public function ApplicationSignalContext(contextView:DisplayObjectContainer = null, autoStartup:Boolean = true)
{
_view = contextView;
super(contextView, autoStartup);
}
override public function startup():void
{
signalCommandMap.mapSignalClass(DoSomethingSignal, DoSomethingCommand);
}</code>
</pre>
<p>Does this help?</p>
<p>Cheers,<br>
Ondina</p></div>Ondina D.F.tag:robotlegs.tenderapp.com,2009-10-18:Comment/207865502012-11-20T10:09:37Z2012-11-20T10:09:37ZCan SignalContext work within a FlexMobile project?<div><p>Mike, you can re-open this discussion, if need be.</p></div>Ondina D.F.tag:robotlegs.tenderapp.com,2009-10-18:Comment/207865502012-11-20T10:38:03Z2012-11-20T10:38:03ZCan SignalContext work within a FlexMobile project?<div><p>Thanks once again , the enter_frame check was missing in my
sample ,.oddly this.doesn't seem to matter with flash professional
projects. Anyway its underway cheers!</p></div>miketag:robotlegs.tenderapp.com,2009-10-18:Comment/207865502012-11-20T11:20:24Z2012-11-20T11:20:24ZCan SignalContext work within a FlexMobile project?<div><p>no problem:) glad you solved it.<br>
Cheers,<br>
Ondina</p></div>Ondina D.F.