In the code below--

it looks like in the first function you have MouseEvent.MOUSE_DOWN associated 
with the onMouseOverHandler and in the second function you have 
Mouse.Event.MOUSE_OVER associated with the same handler.


Odie

On Mar 13, 2010, at 10:02 AM, Susan Day wrote:

> On Sat, Mar 13, 2010 at 10:36 AM, David Hunter 
> <davehunte...@hotmail.com>wrote:
> 
>> 
>> hi susan. you can paste this directly into a new FLA and it should work. it
>> works for me: http://pastebin.org/111702
>> i've passed it two parameters one for the actual url to navigate to and one
>> without the "http://..."; junk for display in the textfield. but you could
>> add or remove the "http..." stuff at different parts of the process if you
>> only wanted to pass it one parameter but you might into problems later down
>> the line with urls that use "www" and urls that don't let alone what is
>> appended to the back ".com",".co.uk",".biz",".info" etc. i don't know
>> where you are getting the urls from but if you are storing them in an array
>> then you could just pass a number and grab the value from the array. you can
>> always add extra parameters for x and y or any other attributes. there are
>> many ways to skin a cat.
>> hope i've helped,
>> david
>> 
> 
> Thank you, however, I don't think this addresses my problem. My problem is
> that I have an onMouseOver eventHandler that's running interference with the
> onClick eventHandler. For some reason I can't figure out, that mouse-over
> one mangles the on-click one. Here's the code for the mouse-over, and it's
> pretty benign:
> 
>        function onMouseOverHandler(e:MouseEvent)
>        {
>            if (e.currentTarget.name == ' Home ')
>            {
>                e.currentTarget.removeEventListener(MouseEvent.MOUSE_DOWN,
> onMouseOverHandler);
>                e.currentTarget.removeEventListener(MouseEvent.CLICK,
> onPressHandler);
>                Navigation(' Home ', 'index', 235, 0x97f9ec);
> ...
> 
> I added the removeEventListeners to try and resolve the problem, but that
> didn't help. Here's the code for the other one:
> 
>        function onPressHandler(e:MouseEvent)
>        {
>            if (e.currentTarget.name == ' Home ')
>            {
>                Navigation(' Home ', 'index', 235, 0xffffff);
>                e.currentTarget.removeEventListener(MouseEvent.MOUSE_OVER,
> onMouseOverHandler);
>                Navigate.to(e.currentTarget.getChildAt(1).text + '.html');
> ...
> 
> I shouldn't have to add that ".html"...that's what gets mangled. The rest of
> the url is fine, underscores and all (where applicable), so it's not just a
> duplication of the name property. I can't figure the silly thing out. Are
> there other examples of where one event handler can mangle another?
> TIA,
> Susan
> _______________________________________________
> 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

Reply via email to