[Flashcoders] shared local object, or XML export? or other?

2007-03-19 Thread kent humphrey

For an upcoming project, I have to investigate whether to use a shared
localobject for storing user data, or exporting XML.

This is for a cd based app, not a website. A shared localobject would be my
first choice, except that we want to be able to access the saved data from a
second release of the cd. My understanding of the security of local objects
is that they are only accessible from the app that created them. Is that
correct? Or is it possible to work around that?

If the second release would not be able to retrieve the data, I thought
maybe exporting XML would be an option. But from my searches, all the ways
of doing that involve sending to a server, and we wont be able rely on net
access being available. Are there any other ways of exporting xml?

Or is there a method I haven't thought of? The basic requirement is that
user data can be saved to the local machine, and then read in again by the
same app, and any other subsequent apps. Ideally we don't want to have to do
a local install, but would consider it if there is no other way.

Thanks for your time.
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] migrating to Flex

2006-11-26 Thread Kent Humphrey



Millie Niss wrote:

Am I the only one on this list who (still) uses the Flash IDE (Flash 8 Pro) and
hasn't migrated to AS 3.0 or any version of Flex? 


I'm still using Flash 8, but am itching to get into a Flex project.



I am interested in
both but do not want to fork over any more $$ to ex-Macromedia.  (I feel 
cheated by having paid for many versions of the educational versions because 
they don't upgrade then many versions of full software because the Macromedia 
packages I had didn't have an upgrade path to the newer bundled Adobe products 
such as Creative Suite 2 or the Adobe Video Bundle.)

What
is the minimum cost to start using Flex?  (I mean in a production
version.  I do not want to start using a beta or a trial of something
and then have it break and be stuck.)  What are the ongoing costs to
deploy Flex apps?  I have looked at the website but found it confusing
and they keep changing pricing...   I want a rough idea of what it
actually costs developers to switch to Flex and deploy the apps etc.


At its cheapest, Flex 2 is free. There is a free SDK which will compile .swfs 
and that costs nothing. What you pay for is the nice IDE, Flex Builder, and the 
optional Flex Data Services (FDS) and stuff. As for deployment, all you're doing 
is publishing .swf files, just like Flash. The power in Flex is when you're 
dealing with dynamic data, but it will happily connect with free databases such 
as MySQL etc. For more advanced stuff - such as real-time user to user 
messaging, collaborative stuff etc - you will need FDS.


That is my understanding anyway :


What if anything will I lose by switching to Flex?  I use the Flash IDE a lot 
for design now but most projects have extensive coding as well.  Can I use Flex 
for the code and still use the IDE for design?


Flex uses AS3, so you will need to get the preview update to Flash9 to combine 
the two I believe.

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Acronym for Actionscript/Flash/Flex

2006-11-26 Thread Kent Humphrey



chris daubney wrote:
In the same way that AJAX stands for Javascript/XML, can anyone come up 
with or has heard an appealing acronym for Actionscript/Flex/Flash?


As long as it doesn't turn into FAF...


Why?
Perhaps in small part due to their heritage, the Actionscript/Flex/Flash 
core set of technologies are often referred to as Flash (as is the Flash 
Player at times). I find this poses all sorts of interesting questions:-

- is it a Flash project?
- is it an Actionscript project?
- is it a Flex project?
- what do we say when the Flash/Flex IDE are out of the picture but 
still work with Actionscript using other tools?

...and so on


It is all delivered with the Flash plugin, so I would stick with Flash. Although 
Adobe might prefer it is called the Flash Platform or some-such :



Maybe Flash or FLASH is enough.


Please, not FLASH! Ugh. Like PLAYSTATION3 and so on. What is the attraction of 
all caps? Is it a reaction to the days of all lowercase?

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] access included .as of parent movie

2006-11-23 Thread Kent Humphrey
Hi there, I haven't been around for a while, but I'm getting to do  
some fun flash stuff again - so I need some help :


I find myself using the excellent mc_tween2.as quite abit, and on the  
current project I have a parent movie that loads 2 sub movies, and  
I'd like to use the methods in the class in these sub movies.


At the moment I am including them in the sub movies directly, but  
surely there's a way of only including the class once, at the top  
level, and having the sub movies access that? The class adds about  
10k to the compiled .swf, so it isn't huge, but it is still redundant  
code.


I have tried doing just that, but nothing happens so I'm guessing  
there is some trick to it.


I have searched the archive here but haven't come across anything  
that helps me.


Any ideas?

Thanks.
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] access included .as of parent movie

2006-11-23 Thread Kent Humphrey

Thanks for that, knowing what to look for makes a big difference.

In case someone else needs it later, there's a good link about having  
an external class swf on the adobe forum here:


http://www.adobe.com/cfusion/webforums/forum/messageview.cfm? 
forumid=15catid=288threadid=1088462highlight_key=ykeyword1=intrinsic


On 23 Nov 2006, at 13:15, Ian Thomas wrote:


Have a hunt for the word 'intrinsic' - either in this list archives or
on the Adobe site.

HTH,
 Ian

(Sorry, too busy to write more detail. :-) It comes up fairly often.)

On 11/23/06, Kent Humphrey [EMAIL PROTECTED] wrote:

Hi there, I haven't been around for a while, but I'm getting to do
some fun flash stuff again - so I need some help :

I find myself using the excellent mc_tween2.as quite abit, and on the
current project I have a parent movie that loads 2 sub movies, and
I'd like to use the methods in the class in these sub movies.

At the moment I am including them in the sub movies directly, but
surely there's a way of only including the class once, at the top
level, and having the sub movies access that? The class adds about
10k to the compiled .swf, so it isn't huge, but it is still redundant
code.

I have tried doing just that, but nothing happens so I'm guessing
there is some trick to it.

I have searched the archive here but haven't come across anything
that helps me.

Any ideas?

Thanks.
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] use of embedded font = blank text?

2006-06-02 Thread Kent Humphrey

Kevin Newman wrote:
I had a problem recently embedding ComicSans MS (it was a comic app, so 
it was ok ;-) ). The problem turned out to be related to my use of Faux 
Bold. Just unchecking the Faux Bold box fixed it up. So maybe it's a 
formatting problem?


OK, I'll look into that.

In the code that you provided question_fmt is not defined anywhere. I 
guess it was defined in code that you didn't post?


Correct, it is defined at the top of the script.

Thanks.



Kent Humphrey wrote:

http://devqa.exnis.net/vanclarke.com/www/test.html

Can someone tell me what I am doing wrong here?

What you can't see on that test page is the questions, which are being 
pulled in with identical code, but have been set to use an embedded 
font. Here is my code:


q_mc = content_mc.createTextField(question+i, 
content_mc.getNextHighestDepth(), 0, 0, 385, 20);

q_mc.autoSize = left;
q_mc.wordWrap = true;
q_mc.antiAliasType = advanced;

q_mc.embedFonts = true;

q_mc.selectable = false;
// assign text format defined above
q_mc.setTextFormat(question_fmt);
   q_mc.text = questions[i];

If I comment out the embedFonts line, the text is visible.

I have tried embedding different fonts, different font weights, 
different linkage names, htmltext vs text and so on.


The text is currently being pulled from a list, but testing with 
straight text has the same effect.


I am using this same code to pull text into the swf that this swf is 
loaded into, and it works fine there. This swf doesn't work as a 
standalone or as part of the larger app.


Anyone got any ideas?


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] flickering components, depth issue?

2006-06-01 Thread Kent Humphrey

http://devqa.exnis.net/vanclarke.com/www/index.html

Go to News  PR/Fashion Shows and News  PR/Photo Gallery

The Fashion Shows page is using the FLV Playback from Flash 8, the  
Photo Gallery is using thumbgallery from www.flashrelief.com


Perhaps foolishly, I have been developing this on a Mac with the  
Flash 9 plugin installed, and these 2 components behave perfectly.  
But it seems for anyone else they don't. I have since reinstalled  
Flash Player 8 and I too get the flickering issue.


The pages above are external .swfs that are loaded into a parent swf  
with .loadClip. I am guessing the problems I have are due to using  
getNextHighestDepth() rather than the depthManager class, is that  
right? Can anyone point me to a tutorial on how to use it? I've done  
some googling and found nothing : 
___

Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] flickering components, depth issue?

2006-06-01 Thread Kent Humphrey
I can understand perhaps that components get picky about getting  
moved around, but I am loading these components in as part of a  
normal .swf - surely that's ok?


There is no funky changing of depths going on, they get loaded in,  
they then get removed when another one is loaded.


Can anyone confirm that this IS what happens when you use  
getNextHighestDepth() with components instead of the depthManager class?


On 1 Jun 2006, at 12:11, Ramon Miguel M. Tayag wrote:


I use getNextHighest and it has always worked fine.  I don't see why
it should be a problem - unless you change your depths in the middle
of the movie for some reason.

On 6/1/06, Kent Humphrey [EMAIL PROTECTED] wrote:

http://devqa.exnis.net/vanclarke.com/www/index.html

Go to News  PR/Fashion Shows and News  PR/Photo Gallery

The Fashion Shows page is using the FLV Playback from Flash 8, the
Photo Gallery is using thumbgallery from www.flashrelief.com

Perhaps foolishly, I have been developing this on a Mac with the
Flash 9 plugin installed, and these 2 components behave perfectly.
But it seems for anyone else they don't. I have since reinstalled
Flash Player 8 and I too get the flickering issue.

The pages above are external .swfs that are loaded into a parent swf
with .loadClip. I am guessing the problems I have are due to using
getNextHighestDepth() rather than the depthManager class, is that
right? Can anyone point me to a tutorial on how to use it? I've done
some googling and found nothing :
___


--
Ramon Miguel M. Tayag
Managing Director
Quirkworks
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com




___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] flickering components, depth issue?

2006-06-01 Thread Kent Humphrey
I just turned off the mask that was cropping the loaded .swf to the  
correct size, and now things are working fine:


http://devqa.exnis.net/vanclarke.com/www/index2.html

Is there something special I need to do to use a mask with a  
loaded .swf that has a component in it?


On 1 Jun 2006, at 12:11, Ramon Miguel M. Tayag wrote:


I use getNextHighest and it has always worked fine.  I don't see why
it should be a problem - unless you change your depths in the middle
of the movie for some reason.

On 6/1/06, Kent Humphrey [EMAIL PROTECTED] wrote:

http://devqa.exnis.net/vanclarke.com/www/index.html

Go to News  PR/Fashion Shows and News  PR/Photo Gallery

The Fashion Shows page is using the FLV Playback from Flash 8, the
Photo Gallery is using thumbgallery from www.flashrelief.com

Perhaps foolishly, I have been developing this on a Mac with the
Flash 9 plugin installed, and these 2 components behave perfectly.
But it seems for anyone else they don't. I have since reinstalled
Flash Player 8 and I too get the flickering issue.

The pages above are external .swfs that are loaded into a parent swf
with .loadClip. I am guessing the problems I have are due to using
getNextHighestDepth() rather than the depthManager class, is that
right? Can anyone point me to a tutorial on how to use it? I've done
some googling and found nothing :
___


--
Ramon Miguel M. Tayag
Managing Director
Quirkworks
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com




___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] use of embedded font = blank text?

2006-06-01 Thread Kent Humphrey

http://devqa.exnis.net/vanclarke.com/www/test.html

Can someone tell me what I am doing wrong here?

What you can't see on that test page is the questions, which are  
being pulled in with identical code, but have been set to use an  
embedded font. Here is my code:


q_mc = content_mc.createTextField(question+i,  
content_mc.getNextHighestDepth(), 0, 0, 385, 20);

q_mc.autoSize = left;
q_mc.wordWrap = true;
q_mc.antiAliasType = advanced;

q_mc.embedFonts = true;

q_mc.selectable = false;
// assign text format defined above
q_mc.setTextFormat(question_fmt);

q_mc.text = questions[i];

If I comment out the embedFonts line, the text is visible.

I have tried embedding different fonts, different font weights,  
different linkage names, htmltext vs text and so on.


The text is currently being pulled from a list, but testing with  
straight text has the same effect.


I am using this same code to pull text into the swf that this swf is  
loaded into, and it works fine there. This swf doesn't work as a  
standalone or as part of the larger app.


Anyone got any ideas?
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] xpath xml strangeness

2006-05-15 Thread Kent Humphrey

I'm using SEPY on OSX, good enough for you? ;

On 11 May 2006, at 14:06, Johannes Nel wrote:


get a proper as editor i would say


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] xpath xml strangeness

2006-05-15 Thread Kent Humphrey

fdt?

Can it really notice the wrong case of a 3rd party class/function?

On 15 May 2006, at 13:10, Johannes Nel wrote:

then obvisouly not. sepy is not a bad editor, but it should surely  
point out

things like that. fdt is the way :)


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] xpath xml strangeness

2006-05-11 Thread Kent Humphrey

ok, been banging my head against a wall for ages on this one.

These lines of code work:

menu_root = XPath.selectNodes(this, root/menu/item/@name);
trace('menu_root: ' + menu_root);

These don't:

perm_items = Xpath.selectNodes(this, root/perm/item/@name);
trace('perm_items: ' + perm_items);

The trace returns undefined.

Here is  the XML, trimmed down to the vitals:

root
menu
item name=Profiles colour=0x73556b
	item name=The Salon type=content colour=0x7797ac  
height=400 filename=profiles-the-salon/
			item name=Meet Michael Van Clarke type=content  
colour=0x7797ac height=400 filename=profiles-mvc/

item name=Team Profiles /
item name=Testimonials type=content height=400  
colour=0x7797ac /

/item
item name=Book Online colour=0x73
item name=Booking Form /
/item
etc etc
/menu
perm
item name=Special Offers /
item name=Book an Appointment /
item name=Register for Newsletter /
/perm
/root



Anyone have any ideas what the problem is?
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] xpath xml strangeness

2006-05-11 Thread Kent Humphrey

Unbelievable!

Thanks a lot Serge, you're a lifesaver :

On 11 May 2006, at 13:50, Serge Jespers wrote:


Could it be just a plain old typo?
XPath is with capital X and capital P.

In the perm_items line you wrote Xpath

Serge




These lines of code work:

menu_root = XPath.selectNodes(this, root/menu/item/@name);
trace('menu_root: ' + menu_root);

These don't:

perm_items = Xpath.selectNodes(this, root/perm/item/@name);
trace('perm_items: ' + perm_items);


___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com




___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] Is a colour stated as 0xFF00FF an object?

2006-04-27 Thread Kent Humphrey

Is a colour stated as 0xFF00FF an object?

I am getting a colour from an xml attribute with XPath  
(colour=0xFF00FF), and then trying to use that colour with the mc  
tween class - my_mc.colorTo(bgColour, 1). But it always changes to  
black.


If I trace() the bgColour, it has the correct value.

If I trace the typeof() the bgColour, it returns object.

What should the type be for this to work?

Thanks for your time.
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: AW: [Flashcoders] Is a colour stated as 0xFF00FF an object?

2006-04-27 Thread Kent Humphrey

slaps forehead of course...

so the return from XPath is an object/array containing a string, and  
I need it as a number.


trace(bgColour[0]) returns the correct value, but

trace(Number(bgColour[0])) returns NaN - so how do I make it a real  
number?


The help docs say that a string that starts with 0x will be treated  
as hexadecimal.




On 27 Apr 2006, at 13:11, Kerem Gülensoy wrote:


Number

cheers | kerem

-Ursprüngliche Nachricht-
Von: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Im Auftrag von Kent
Humphrey
Gesendet: Donnerstag, 27. April 2006 13:54
An: Flashcoders mailing list
Betreff: [Flashcoders] Is a colour stated as 0xFF00FF an object?

Is a colour stated as 0xFF00FF an object?

I am getting a colour from an xml attribute with XPath  
(colour=0xFF00FF),

and then trying to use that colour with the mc tween class -
my_mc.colorTo(bgColour, 1). But it always changes to black.

If I trace() the bgColour, it has the correct value.

If I trace the typeof() the bgColour, it returns object.

What should the type be for this to work?

Thanks for your time.
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training http:// 
www.figleaf.com

http://training.figleaf.com

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com




___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: AW: [Flashcoders] Is a colour stated as 0xFF00FF an object?

2006-04-27 Thread Kent Humphrey


On 27 Apr 2006, at 15:00, Zeh Fernando wrote:


trace(bgColour[0]) returns the correct value, but
trace(Number(bgColour[0])) returns NaN - so how do I make it a  
real  number?
The help docs say that a string that starts with 0x will be  
treated  as hexadecimal.


Use parseInt() to convert a string into a number



That is exactly what it does, eg 0x73 becomes 7558485, but that's  
not what I need. I need it to stay hexadecimal, but to be recognised  
as a number type. It shouldn't be converted, its type needs to be  
changed.


Hey, it's Zeh, it's your mc tween class I'm using isn't it? :  
Fantastic script...


The docs only have hex numbers used in the colorTo() function, so I  
assumed that's what I needed - can I use a normal int too?

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: AW: [Flashcoders] Is a colour stated as 0xFF00FF an object?

2006-04-27 Thread Kent Humphrey
Cool, thanks for that. It's strange the holes you find in your AS  
knowledge sometimes...


On 27 Apr 2006, at 15:29, Zeh Fernando wrote:

That is exactly what it does, eg 0x73 becomes 7558485, but  
that's  not what I need. I need it to stay hexadecimal, but to be  
recognised  as a number type. It shouldn't be converted, its type  
needs to be  changed.


Well, a number is a number - 0xff *is* 255. If you need it to be  
hexadecimal for some visual or string reason, you need to convert  
it back to an hex string - with .toString(16).



Hey, it's Zeh, it's your mc tween class I'm using isn't it? :   
Fantastic script...


Yes, it probably is. Thanks!


The docs only have hex numbers used in the colorTo() function, so  
I assumed that's what I needed - can I use a normal int too?


Sure, you can. Like I said, a number is a number - whether you're  
seeing it as F or 15 is just a matter of visual representation  
under a certain base. If you want to write something using hex  
numbers, you can use, say, 0xff2101 because it's easier; but if you  
pass the parameter as being 16720129 instead, it's the same thing.  
You could even use 077620401 as an octal number, it's no different  
to Flash. The same applies to any method or function that 'usually'  
an hex number as input - say, the setRGB method (colorTo uses the  
same color input parameter).


In the end,

trace (0xff === 255);

Traces true.


- Zeh
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com




___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] Flash MX2004, Video CD with auto-play {Director v. Flash??}

2006-03-19 Thread Kent Humphrey

Michael Bedar wrote:
Just for the record, there is no autoplay on OSX, if you are  supporting 
mac.


It's also worth noting that Autoplay on Windows is able to be turned off - and 
many people do, therefore you cannot rely on it being on.

___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


Re: [Flashcoders] FF Seattle Report

2006-03-06 Thread Kent Humphrey


On 6 Mar 2006, at 13:33, Nick Weekes wrote:

The point is Flex is a completely separate technology Adobe are  
actively
pushing forward, and they're trying to get me in on it by teasing  
me with a
preview of AS3 ;P Conspiracy! Aiee!! But seriously. It smacks of a  
form of
early brand imprinting. I don't see Flex murdering AJAX or sparkle  
in the
same way Flash has murdered SVG for online vector dominance, and as  
such i

don't see it's worth my time without going full-time.


But you want the benefits of AS3 right? So you wait until the public  
alpha of Flash 9 is on the Labs site, which was announced as  
happening sometime right?


No one is forcing you to learn Flex, you will still get all the fun  
of AS3 in due course while sticking with Flash.



under $1000 is not necessarily cheap by the way.


How much did Flash cost you the first time you bought it?
___
Flashcoders@chattyfig.figleaf.com
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com


[Flashcoders] xpath - returning object not string?

2006-02-03 Thread Kent Humphrey

Continuing my further adventures in xpath land:

clientList = XPath.selectNodes(this, root/clients/client/@name);

trace(typeof(clientList[0]));

That trace statement returns object, so my array is an array of  
objects, not the strings I was after.


WIll I have to String(clientList[0]) everytime I need the string  
value, or is there some other way?

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] xpath - returning object not string?

2006-02-03 Thread Kent Humphrey
But doesn't that object get put into the array (clientList - declared  
as an array earlier), and I'm targeting a single item in the array?


On 3 Feb 2006, at 12:16, Alias wrote:


Your query will return a list of objects which have the attribute
name. There may be more than one of them, hence you get the object.

HTH,
Alias

On 2/3/06, Kent Humphrey [EMAIL PROTECTED] wrote:

Continuing my further adventures in xpath land:

clientList = XPath.selectNodes(this, root/clients/client/@name);

trace(typeof(clientList[0]));

That trace statement returns object, so my array is an array of
objects, not the strings I was after.

WIll I have to String(clientList[0]) everytime I need the string
value, or is there some other way?
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders




___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] xpath / xpath4as2 beginners question

2006-02-02 Thread Kent Humphrey
I'm trying to figure out how to use xfactorstudios xpath4as2 class,  
but I can't seem to get over the first hurdle! Can anyone tell me why  
this isn't working?


import com.xfactorstudio.xml.xpath.*;

myDoc = new XML();
myDoc.onLoad = function(){
var products = XPath.selectNodes(this,/product/products);
trace(Products: +products);
trace(this);
}
myDoc.load(../xml/test.xml);

The above code is from the xfactostudios site (http:// 
www.xfactorstudio.com/ActionScript/AS2/XPath/) and the xml file I am  
loading is also from that page. What I have added is the two trace()  
statements to see if things are working.


The first trace doesn't give me anything, but the second shows the  
whole xml file, so I know that at least the load is working.


I have the class files located in Mac HD/Users/Username/Library/ 
Application Support/Macromedia/Flash 8/en/Configuration/Classes/com/ 
xfactorstudio/xml/xpath/ - that's correct isn't it?


Any ideas? And does anyone know some good tutorials for this class?

Thanks.
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] xpath / xpath4as2 beginners question

2006-02-02 Thread Kent Humphrey


On 2 Feb 2006, at 15:48, Merrill, Jason wrote:


However, not a good idea to have a child node be the same name as the
parent node (though it's OK in the sense it that won't screw up  
Xpath).


Would you believe my problem was I had product/products instead of  
product/products ?!


Sheesh...

Thanks for the help.

Can I have some general XML help too please? : Does this XML file  
make sense, is it well formed?


root
clients
client name=Borgo di Colleoli
sectorProperty/sector
disciplineDirect Mail/discipline
disciplineAdvertising/discipline
/client
client name=Royal Bank of Scotland
sectorFinance/sector
disciplineInteractive Design/discipline
disciplineStrategy/discipline
/client
/clients
sectors
sector name=Property
clientBorgo di Colleoli/client
disciplineDirect Mail/discipline
disciplineAdvertising/discipline
disciplineChannel and Sales/discipline
disciplineInteractive Design/discipline
/sector
/sectors
disciplines
discipline name=Direct Mail
sectorProperty/sector
clientBorgo di Colleoli/client
/discipline
/disciplines
/root

I know I'm in danger of repeating my first mistake by doing something  
like client/clients instead of clients/client - but I can't think of  
another way to organise it.


Observant readers may recognise this as an xml sample of my matrix/ 
relationships questions from a few days ago :

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] avoiding a stack of lists

2006-01-31 Thread Kent Humphrey

Nathan Derksen wrote:

Sorry for the delayed response, it's been a busy day.


Not a problem at all.


I hope this helps.


That looks great, an improvement over what I've already done, but it wont 
require a full rewrite. Thanks a lot.

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] targetting a mc from a list

2006-01-30 Thread Kent Humphrey
Thanks, but that doesn't work either. It looks like it should, but  
I'm still getting undefined.


On 30 Jan 2006, at 13:31, Adrian Lynch wrote:


Try:

parent_mc[listWhatever[0]];

Ade

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Behalf Of Kent
Humphrey
Sent: 30 January 2006 13:25
To: Flashcoders mailing list
Subject: [Flashcoders] targetting a mc from a list


I have a list:
(code is example only)

listWhatever = [mc1, mc2];

This list is cycled through to generate some mcs inside parent_mc.
I now want to target one of those mcs again. Lets say I want to
target the first one in my list. I thought I could use eval() to
generate the statement, like so:

eval(parent_mc.+listWhatever[0]);

But trace() that returns undefined. How do I do it?

Thanks.
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders




___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] targetting a mc from a list - solved

2006-01-30 Thread Kent Humphrey
ok, found the problem, my actual list has strings with spaces in  
them, which is what is making it not work.
So I guess I'll fill them with _ and then replace them with
when I need the string with spaces.


Thanks for the help guys.


On 30 Jan 2006, at 14:00, Adrian Lynch wrote:


Are you sure you're creating the nested MC as you think you are?

What do you get if you do:

trace(parent_mc.mc1);

???

Ade


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] targetting a mc from a list - solved

2006-01-30 Thread Kent Humphrey
Well, yeah, these list items need to be client names and that kinda  
thing, so might be a single word, might be 3 or 4 words.


String wrangling to the rescue.

On 30 Jan 2006, at 15:10, Adrian Lynch wrote:


Ah, so you had a [mc 1, mc 2] type thing going on?

Ade


___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] avoiding a stack of lists

2006-01-30 Thread Kent Humphrey

Here's more of a higher-level problem for you helpful people :

Imagine 3 lists, someListA, anotherListB, and lastListC. When I  
rollover something in someListA, I want the items in anotherListB and  
lastListC to highlight. And the same for rolling over something in  
anotherListB or lastListC.


So rolling over an item in any list makes N items in the other lists  
highlight.


I've made a single item work with my initial solution, which was to  
have a list for each item that lists which items in the other lists  
should highlight. But by the time I've made 25 lists for my 25  
(current) items, that seems like a lot of redundant and duplicated  
data somehow.


Anyone got any ideas?
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] avoiding a stack of lists

2006-01-30 Thread Kent Humphrey


On 30 Jan 2006, at 16:30, Alan MacDougall wrote:

I've made a single item work with my initial solution, which was  
to  have a list for each item that lists which items in the other  
lists  should highlight. But by the time I've made 25 lists for my  
25  (current) items, that seems like a lot of redundant and  
duplicated  data somehow.


That sounds to me like you want to use events -- the items which  
light up should listen to the items that trigger them. When the  
triggering item gets moused over, the listening item(s) can decide  
whether to react. This might just take your redundancy and put it  
somewhere else, but it keeps you from writing and checking a ton of  
different lists.


Yeah, that sounds good. I haven't used events and listeners much, so  
upfront it might take me longer than my first approach. But let me  
see if I have the theory right.


Each item in the lists is assigned a listener object as it is  
created, which would be a list of the possible events that will  
trigger it. Each item also has an event object that fires when rolled  
over.


Rolling over item A fires an event that all the other items hear,  
each other item checks its list of events that will trigger it, and  
if it finds the event that was fired, it does its thing.


Does that sound about right?
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] avoiding a stack of lists

2006-01-30 Thread Kent Humphrey


On 30 Jan 2006, at 17:12, Alan MacDougall wrote:

Close. Let's assume you're using mx.events.EventDispatcher. Your  
event broadcaster class starts like this:


Wow. Thanks for all that. I'm not using classes so that's another  
thing I'll have to study up on...


I've filed your post away for future reference, when I've got to  
grips with the whole OOP thing :

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] avoiding a stack of lists

2006-01-30 Thread Kent Humphrey


On 30 Jan 2006, at 17:13, Nathan Derksen wrote:

Well, regardless of whether or not you use listeners, you still  
need to create the data relationship. I don't think encoding the  
relationships into 25 listeners is necessarily a good idea, either.  
An associative array, indexed by ID, could store the IDs of the  
other list items that are related, all in a single data structure.  
So for instance:


listRelationships[itemID1] = [itemID2, itemID3];
listRelationships[itemID2] = [itemID1];
listRelationships[itemID3] = [itemID2];

This allows you to store arbitrary relationships between each list  
item. When a list item is moused over, just grab listRelationships 
[itemID] and you will get a corresponding array of list items to  
highlight.


Nathan
http://www.nathanderksen.com


That sounds a bit more like where I'm at. Not that I've used  
associative arrays before, but they're basically the same as property  
lists in Lingo right?


In your above example, wont I still need a listRelationships 
[itemID1] = [whatever] line for each item I'm wanting to reference?  
Or have I totally misunderstood what's going on there?

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] ActionScript Cheatsheet Update (new URL)!

2006-01-27 Thread Kent Humphrey
That's cool, would be great to print onto A3 and stick on the wall  
next to my desk. Any chance of a printable PDF version or something?

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] ActionScript Cheatsheet Update (new URL)!

2006-01-27 Thread Kent Humphrey

Sander wrote:

  http://www.actionscriptcheatsheet.com

What a nice reference card!

It's much faster to glimpse at the wall to lookup code than to use  
autocomplete! Oh wait, it's not.


I don't know about others, but sometimes I get lazy and don't use :Array or 
whatever_mc, which means autocomplete doesn't always kick in.


Is it less work to look at a poster than to use correct programming techniques? 
Yeah, probably :

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] nested MC not firing event

2006-01-26 Thread Kent Humphrey
This is a problem that has always plagued me, and I usually end up  
just using the timeline to get around it, but this time I want to do  
it properly!


The situation is, I have a partially masked MC that on (rollOver)  
tweens to be fully revealed. on (rollOut) does the opposite, hiding  
it again.


What I can never manage to do is put buttons inside the revealing MC.  
Even a simple test like trace(this) does nothing. I think it's  
because the (rollOver)/(rollOut) script on the parent of the button  
is conflicting with the event being sent by the child. The mouse  
cursor certainly remains the same (finger) over the whole revealed  
shape.


Now I'm sure that most of you gurus out there don't use the timeline  
to get around this problem, so what do you do?


I'd really appreciate any help on this, thanks.
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] nested MC not firing event

2006-01-26 Thread Kent Humphrey


On 26 Jan 2006, at 11:01, Roman Blöth wrote:

Yes, that unfortunately is the only way to go - Director btw does  
this much better: With Lingo you can pass every event, so it  
reaches all objects that want to receive them...


I'm a Lingo refugee, feel my pain...



But one more comment on the method above:

Assume you have a onMouseEnter/onMouseLeave method on a background  
mc within your container mc, and then place button mcs above this  
background mc which want to receive on release events, then when  
the mouse pointer hovers over such a button mc, the background mc  
will receive a onMouseLeave-event, even though in fact the pointer  
still is within the background area...


Which is what I just discovered with my test. So what is the  
solution? Surely thing kind of thing is overcome every time someone  
codes a simple dropdown kinda thing?___

Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] nested MC not firing event

2006-01-26 Thread Kent Humphrey


On 26 Jan 2006, at 11:38, Roman Blöth wrote:

g - well, in my case I switched to a onEnterFrame-method checking  
the _mousex and _mousey relative to the mc itself (i.e. the  
background-mc) and only when the mouse is outside the mc's  
coordinates I let Flash do what else would be in a onMouseLeave- 
method. Not the smartest way, maybe, but it works as intended.



I was really hoping to avoid that kinda thing.


Andreas:

There is no quick solution. If clip A contains clip B and both have  
mouse events, clip A takes precedence. Period. Use xmouse/ymouse vs  
the clip width and height. That's the extent of it. Or use a  
different nesting order, using levels instead of depth for  
instance. But a clip with mouse events containing a button will  
take precedence until those events are removed.


Can you please explain how I would use Levels instead of Depth?


Tom:

one way is to change your hit areas dependent on state, if you know  
what I

mean.


I think that is what I will try next. Pretty much what I used to do  
when I timelined it instead.


or you can use a bit of AS to do a simple hitTest against the mouse  
instead

of using a hitArea at all


Can explain this to me please? And I would be doing the hitTest  
onEnterFrame right?



more than one way to skin this particular cat...


Great, the more the merrier. It seems like one of those simple issues  
that should have been worked out by now. Every method suggested so  
far sounds like a workaround. Anything coming in AS3 that will make  
things easier?


Thanks a lot for all your help 
guys.___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] OT: Mac Mini as (L)AMP+CFMX dev server...

2005-11-03 Thread Kent Humphrey

Weyert de Boer wrote:

Hi!

I just ordered a new Powerbook G4 15 for the design work. My experience 
is that the Apple PowerPC are way faster in
graphics then a pc. 10-15secs for gradient fills. Hopefully the 
Powerbook G4 1.67ghz  is fast enough for the PhotoShop and Flash work.


My experience is the opposite. The Dual 2.5 ghz G5 on my desk at work is barely 
faster than the AMD64 2800 at home. The G5 was crazy money, my AMD64 cost me £600.


Laptops are another issue though, I believe Apple laptops compare much better 
with PC laptops. Until of course you get into the desktop replacement laptops, 
which you can get with 3ghz+ CPUs in them now...Not to mention gigs of RAM and 
RAIDs...But I digress...


I do like Mac Mini's, I think they'd make a great little mac to have around.
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] setInterval() and the trouble

2005-10-30 Thread Kent Humphrey

Eric E. Dolecki wrote:

use setTimeout now and you dont need to worry about interval ids.

e.dolecki




Have you found any documentation about setTimeout - because I haven't :
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] scrolling problem

2005-10-29 Thread Kent Humphrey

Can someone help me with this code?

I'm trying to figure out how to scroll an MC up and down based on the position 
of a scrollbar.


What am I doing wrong with this code?
I'm finding the ratio between how tall the content is (currentChild) and how 
tall the scrollbar is:


scrollRatio = currentChild._height/scrollBar._height;

Then changing the position of the content depending on where the 
scrollBar.slider is:


currentChild._y = (scrollBar._height - scrollBar.slider._y)*scrollRatio;

The result of this is the content is not visible until the scrollbar slider is 
most of the way down it's length, and then the content doesn't scroll far enough.


As you can see I've currently got the slider clip as a child of the scrollBar 
clip - should I bring it out to the same level?


Anyone got any ideas?

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] scrolling problem

2005-10-29 Thread Kent Humphrey

Frédéric v. Bochmann wrote:

As you can see I've currently got the slider clip as a child of the
scrollBar clip - should I bring it out to the same level?

On that matter, I would say, look carefully at your line of code that
follows: (scrollBar._height - scrollBar.slider._y)

If the slider is scrolled higher than _y = 0 or that the slider goes lower
than scrollBar._height your slider will influence the scrollBar._height
value. This can be quite dangerous for weird acting script, but if your sure
your slider won't ever influence it's containers height, your Ok.


I have the slider being constrained by the startDrag function to be within the 
scrollBar clip at all times, so it should be ok.



What I might suggest you would be to use the scrollBar.scrollTrack._height
that might be existent or not in your scrollBar movieclip. 


Yes, it is, I'll try that.


Now for your script, I don't usually go that way of doing it so here is how
I'd probably do it myself:

var scrollRatio = scrollBar.slider._y / scrollBar.scrollTrack._height;
currentChild._y = - scrollRatio * currentChild._height;

I'm not 100% sure but I think this should work. Notice the negative value
for the currentChild._y. 


Thanks, I'll see how that behaves.

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] scrolling problem

2005-10-29 Thread Kent Humphrey


Now for your script, I don't usually go that way of doing it so here 
is how

I'd probably do it myself:

var scrollRatio = scrollBar.slider._y / scrollBar.scrollTrack._height;
currentChild._y = - scrollRatio * currentChild._height;

I'm not 100% sure but I think this should work. Notice the negative value
for the currentChild._y. 



Thanks, I'll see how that behaves.


Well, it's giving me more consistant results across my different clips, but it's 
scrolling too far, leaving whitespace at the bottom. Any ideas?


Logically, I think the scrollRatio must be too high, because it's scrolling 
further than it should.


I've added an offset because the top of the scrolling area is not the top of the 
screen.


var offset = 108;
var scrollRatio = scrollBar.slider._y / scrollBar.track._height;
currentChild._y = (- scrollRatio * currentChild._height) + offset;

I'll write some code to make the offset dynamic later.

To see the script in action, go here - http://fari.kentandangela.com and browse 
to Gallery - Woodcarvings.

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] scrolling problem

2005-10-29 Thread Kent Humphrey

Frédéric v. Bochmann wrote:

I forgot something...true.
Change it to something like:

var scrollRatio = scrollBar.slider._y / scrollBar.scrollTrack._height;
var heightToScroll = currentChild._height -
currentChildContainerMask._height;
if(heightToScroll  0) {
  heightToScroll = 0;
}
currentChild._y = - scrollRatio * heightToScroll;


Where currentChildContainerMask._ height is the height of the Mask that is
masking your currentChild, or simply the height of the outline that is
representing the visible area of your currentChild as its being scrolled.
So basically heightToScroll is equal to the height of your currentChild that
is invisible to the user, it's the part you want to be able to scroll for.

Hope that helps :)
Fredz./


Cool, that's working properly now.

var offset = 108;
var scrollRatio = scrollBar.slider._y / (scrollBar.track._height-30);

var heightToScroll = currentChild._height - whichMask._height;
if(heightToScroll  0) {
heightToScroll = 0;
}
currentChild._y = (- scrollRatio * heightToScroll) +offset;

the (scrollBar.track._height-30) is because the slider is 30 tall, and so it 
never goes beyond scrollBar.track._height-30. The slider is non-proportional at 
the moment.


I was thinking it wasn't working, until I realised that I was cheating with the 
height of the mask, and hiding it behind a solid white block at the bottom of 
the screen! guilty look


Once I've got that sorted, I just need to make the slider move when I click on 
the arrows. What is the best way to do that? Make the arrows move the slider, 
and then update the content as before?


Thanks for all your help :
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] how to access mcs dinamically

2005-10-28 Thread Kent Humphrey


On 28 Oct 2005, at 11:08, Jorge Rego wrote:


Hi list,

I have some MCs named mc1, mc2, mc3 ...
I'm trying to access them like this:
mc[number].someProperty ... but no luck!

How can this be done!?


I use eval()

eval(mc+i).someProperty

where i is some number

perhaps a more correct way would be to generate the mc name into a  
variable, and then use the variable?


tempVariable = eval(mc+i);
tempVariable.someProperty
tempVariable.someOtherProperty
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] how to access mcs dinamically

2005-10-28 Thread Kent Humphrey


On 28 Oct 2005, at 11:08, Roman Blöth wrote:

[mc_+number].someProperty - when referencing mc's by name you  
have to

put it in square brackets...



Cool, you learn something everyday on here :

Goodbye eval()...

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] scroll dynamic MC help

2005-10-28 Thread Kent Humphrey
I was wondering if any of you knowledgeable and generous souls had  
any pointers on how to approach building my own scroll bars for  
dynamically created movieclips.


I've made a very simple one that just has buttons for scroll-up and  
scroll-down, but I'd like to add a slider too, and I;m having trouble  
figuring out how far to let the MCs scroll.


I also experimented with F8's scrollRect thing, but couldn't get it  
working and couldn't find any tutorials on it.


So any thoughts you can give me on best practices for scrolling an  
MC, with slider, either scrollRect-ed or masked, would be greatly  
appreciated :


(I'm wanting to avoid the built in components, unless they really are  
the easiest solution, including skinning to fit my site)


BTW, to see my work in progress - fari.kentandangela.com - you will  
see the long content I need to scroll.

___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


Re: [Flashcoders] What's This Mean?

2005-10-25 Thread Kent Humphrey

James O'Reilly wrote:
It all depends on how you use the .as files.  You can either INCLUDE 
them or IMPORT them.  You import classes and include external code.  The 
error you're getting like is a result of importing your script instead 
of including it.


Try using include:
#include yourscript.as

Notice no semicolon at the end of the line.

JOR


These scripts are already included like that :

I'm not too worried, because like I said, it's working for me when I compile 
with PrimalScript.


Maybe in my next project I'll figure it out properly.
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders


[Flashcoders] Please Help - missing item from loaded XML file, but not when I simulate download?!

2005-10-18 Thread Kent Humphrey

http://fari.kentandangela.com

This is a website I am days away from delivering, and today I'm getting a crazy 
problem.


The menu structure is loaded from an xml file. When I view this on the web, or 
preview from Flash, the 5th item of the main menu doesn't display.


When I do simulate download after previewing it, the 5th item IS there!

What do you see? I've got fast broadband here, but surely it's not skipping over 
a part of the file, the exact same part each time I load it??


This menu system has been working fine for over a week now...

Changing the order of the items in the xml file has no difference, it's always 
the 5th item that wont display, not matter which of my items is in 5th place.


Here is the code to generate the menu items, of course it's looping through them 
so all items are getting exactly the same instructions...


[code]
// build as many root menu items as listed in the xml
for (var i:Number = 0; ias2obj.main.length; i++) {

tempLabel = as2obj.main[i].attributes.label.toLowerCase();
tempMC = mainMenu.attachMovie(menu_item, tempLabel, 
mainMenu.getNextHighestDepth(), {_x:550, _y:i*20+48});

tempMC.level = main;
tempText = tempMC.createTextField(label_text, 1, 0, 0, 200, 20);
tempText._visible = false;
tempText.autoSize = left;
tempText.text = tempLabel.toUpperCase();
tempText.antiAliasType = advanced;
tempText.embedFonts = true;
tempText.selectable = false;
tempText.setTextFormat(menu_fmt);
tempText._visible = true;
trace(text: +tempMC);

}[/code]

(Note, I am using Sephiroth's XML2Obj class to handle the parsing of the xml 
file - as you can see it's reading everything else correctly)


The return from that trace statement is as you expect, it returns the correct 
MC, so it's definitely being created.


Anyone got any ideas? I've been hammering away at this problem for about 4 hours 
now :angry:


Flash 8 Pro, WinXP, published to AS2, Flash Player 8, same issue on Firefox and 
IE.

XML file here http://fari.kentandangela.com/site_tree.xml
.swf here http://fari.kentandangela.com/fari.swf

ignoreWhitespace = true/false isn't making any difference.

Excuse the XML, it's my first, so it might not be structured correctly...
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders