What class are you subclassing to make your component? UIComponent defines
a protected measure() function which some other internals use to figure out
how big a component is. Maybe you need to implement an override of that?
The docs show InteractiveObject having a "focusRect" property, but they
;
>> then
>>
>> -1,-1,27
>> -1,01,04
>> -1,27,04
>>
>> then
>>
>> -1,-1,27
>> -1,01,04
>> 01,27,04
>>
>> then
>>
>> -1,36,27
>> -1,01,04
>> 01,27,04
>>
>> then
>>
>> -1,36,2
Jonathan,
When you "match" a pair, you pull them off the grid. Therefore after
removing the pair of 2s, there are only empty squares in the path between
the 1s.
Dave
On Wed, Mar 11, 2009 at 10:43 AM, jonathan howe wrote:
> Hi, Paul,
>
> Can you explain what you mean by a "clear path".
> For ex
mouseX and mouseY are member variables of the Sprite class. You don't need
to import member variables, only classes. Once you import the Sprite class,
all the members come with it.
replace your mouseX and mouseY imports with:
import flash.display.Sprite;
and you'll be golden.
Dave
On Wed, Ma
My first thought for your algorithm is to essentially follow the solution
path that your user might end up taking. Your user will be clearing areas
out, opening them up. Your algorithm could start with an empty grid and
fill in around a starting seed, growing the tile array outward.
1) empty gri
You can filter XML with arbitrary boolean functions, so the answer is
definitely yes.
See http://livedocs.adobe.com/flex/3/html/13_Working_with_XML_08.html#131880
One of the examples there shows XML stored in var x with a list of type elements, and you can use this syntax to get an XMLList of
em
oops, forgot about the comparison operator being optional. New version:
/(((<|>)=?)|==)?(-?\d+)/
hot darn.
Dave
On Thu, Mar 5, 2009 at 10:44 AM, David Hershberger wrote:
> How's this?
>
> /(((<|>)=?)|==)(-?\d+)/
>
> Then the comparison operator is in result[1]
How's this?
/(((<|>)=?)|==)(-?\d+)/
Then the comparison operator is in result[1] and the number is in
result[4]. You said "integer", so I threw in the optional negative sign. :)
Dave
On Thu, Mar 5, 2009 at 10:02 AM, Glen Pike wrote:
> Hi,
>
> How about:
>
> /([=><]+)([0-9]+)/
>
> Check
In Flex Builder, you can go into the "Flex Navigator" window (the
tree-layout project-contents window), select a directory (like .svn),
right-click it, choose "properties" from the resulting menu, then check the
box which says "derived". Once you do that, I believe it will recognize
that files in
My preference is usually option 3, using an event. It means you can use
your ball in other situations, where that "call" back to the root may or may
not be necessary. Regarding cleaning up references in event listeners, you
can use a "weak reference" when you call addEventListener(). Also, I oft
I may be misunderstanding the trouble you are having, but are you looking
for sine and cosine?
var velocity: Number = 3; // Absolute velocity, regardless of direction
speedX = velocity * Math.cos( cursorAngle ); // X component of velocity
speedY = velocity * Math.sin( cursorAngle ); // Y component
private function assignContent( parentObject: *, memberName: String ): void
is what your function needs to take, and you would call it like:
assignContent( msg, "ONE" );
With assignContent( msg.ONE ) as you have it, the reference to the object
stored in msg.ONE is read
from msg before and only t
Dunno if you're going to implement [Bindable], which is I guess part of
Flex, but if you do...
https://bugs.adobe.com/jira/browse/SDK-14475 and
https://bugs.adobe.com/jira/browse/SDK-9804
describe the fact that we can't use data-binding to watch the changes of
read-only properties. This ability w
I use custom events mostly when I have data to pass through the event which
doesn't fit nicely into some pre-defined one. For instance, we have a
HighScoreEvent which has the number of points and the time it took to finish
the game.
Also, it is good practice to define your own Event subclass(es)
An event is just a message object. Just because one gets created
successfully does not mean it is being delivered. dispatchEvent() is a
method of the EventDispatcher class, which is a superclass of many classes,
including DisplayObject. You need to listen for the event (with
addEventListener())
We had a similar issue triggered by scaling. When we rescaled objects with
Advanced Anti-Aliasing text, they wouldn't recompute their size properly and
would truncate themselves with "..." at the end at some scales but not at
others. We ended up just turning it off. It's true that it looks bette
Also Flex supports PNG and JPEG:
mx.graphics.codec.PNGEncoder and mx.graphics.code.JPEGEncoder.
Dave
On 12/3/08, Ian Thomas <[EMAIL PROTECTED]> wrote:
>
> If you mean 'how do I encode a bitmap into an image format' e.g. PNG
> or JPEG, check out this library:
> http://code.google.com/p/as3corelib/
http://box2dflash.sourceforge.net/
Good stuff.
Dave
On 12/1/08, allandt bik-elliott (thefieldcomic.com) <[EMAIL PROTECTED]>
wrote:
>
> hi guys
>
> could anyone point me in the right direction to do the following, please?
>
> I'd like an object that is dragged to correctly respond to being pulled
Ooh! Ooh! I just wrote this a few days before you asked. Here's my
solution:
public function call( rpcName: String, responder: Responder,
rpcArgs: Array ): void {
// NetConnection.call() takes a variable number of arguments after the
// RPC call
You want ApplicationDomain.getDefinition(className: String)
and also ApplicationDomain.hasDefinition(className: String) is handy.
Dave
On Thu, Nov 20, 2008 at 1:52 PM, Merrill, Jason <
[EMAIL PROTECTED]> wrote:
> Refersh my memory. What was the name of that AS3 class method to get a
> class def
Actually, Cairngorm does allow arbitrary mappings from events to commands,
it does not require 1-to-1.
The FrontController's addCommand() function takes an event name (String) and
a Command class. In our app I have used the same event with different
name-constants to run different commands, like
If you are building an application-like user interface with buttons, forms,
dialog boxes, etc, I would really recommend Flex. MXML lets you write such
things very concisely. It has a powerful layout engine and a nice set of
containers which automate a lot of stuff you'd have to write by hand
othe
>
> This should also be informative.
> http://www.insideria.com/2008/11/new-poll-which-flex-framework.html
>
>
>
> On Fri, Nov 14, 2008 at 1:52 PM, David Hershberger <[EMAIL PROTECTED]
> >wrote:
>
>
> > We have been using Adobe Flex for the past year and have
We have been using Adobe Flex for the past year and have really liked it.
It would be hard to call it "blazing" and "bloat" does seem like it might
apply to some extent, but on the other hand it does so many nice things for
us it is hard to argue with. MXML is very powerful, but there is certainly
escriptions on the web.
Dave
On 11/12/08, Latcho <[EMAIL PROTECTED]> wrote:
>
> Hi Joel, Jonathan anf Dave for your answers
> Dave could you explain what you mean with a binary search ?
> Stijn
>
> David Hershberger wrote:
>
> Text flow of variable-width fonts with
Text flow of variable-width fonts with word-wrapping is inherently messy...
there's no way to compute the number of lines with some nice math, you just
have to run the text-flow machinery and measure the result, which is exactly
what you have suggested. I'm pretty certain there is nothing built in
Hi all,
I ran into an issue with keyboard focus which I don't understand, and I
don't see detailed in the docs anywhere.
We have a site that has games in it as well as forms, so sometimes we want
game-style key handling and sometimes we want the form style, where tab or
mouse clicks change focus.
27 matches
Mail list logo