RE: [Flashcoders] error mesg

2010-12-16 Thread Benny
Then make the parameter optional:

function doSubmit(e:MouseEvent=null):void

OR

in your function doSubmitViaEnter method call doSubmit(null)



- Benny


-Oorspronkelijk bericht-
Van: flashcoders-boun...@chattyfig.figleaf.com
[mailto:flashcoders-boun...@chattyfig.figleaf.com] Namens DONALD TALCOTT
Verzonden: vrijdag 17 december 2010 1:24
Aan: Flash Coders List
Onderwerp: Re: [Flashcoders] error mesg

I failed to mention, also have the following for a button;
mc_aim_higher.mc_form.submitBtn.addEventListener(MouseEvent.CLICK,
doSubmit);

If I remove e.MouseEvent the button won't work.



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


RE: [Flashcoders] How to detect for modifier (alt/ctrl) keys

2010-11-20 Thread Benny
just Alt


-Oorspronkelijk bericht-
Van: flashcoders-boun...@chattyfig.figleaf.com
[mailto:flashcoders-boun...@chattyfig.figleaf.com] Namens Henrik Andersson
Verzonden: dinsdag 16 november 2010 14:54
Aan: Flash Coders List
Onderwerp: Re: [Flashcoders] How to detect for modifier (alt/ctrl) keys

I am curious, does the key say Alt or AltGr? They are not quite the 
same.

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


RE: [Flashcoders] How to detect for modifier (alt/ctrl) keys

2010-11-20 Thread Benny
Hi Glen,

I tried your code (somewhat modified, see below, to get the desired traces)
but it gives me the same result. 
E.g. if I hit (right) Alt-5 it traces:

onKeyDown: _ctrlKeyDown=true, _altKeyDown=false, keyCode=17
onKeyDown: _ctrlKeyDown=true, _altKeyDown=true, keyCode=18
onKeyDown: _ctrlKeyDown=true, _altKeyDown=true, keyCode=53
onKeyUp: _ctrlKeyDown=true, _altKeyDown=true, keyCode=53
onKeyUp: _ctrlKeyDown=true, _altKeyDown=false, keyCode=18

Notice that the KEY_DOWN event fires twice for the right alt key!
 
If I just press and release the right alt key it traces:

onKeyDown: _ctrlKeyDown=true, _altKeyDown=false, keyCode=17
onKeyDown: _ctrlKeyDown=true, _altKeyDown=true, keyCode=18
onKeyUp: _ctrlKeyDown=true, _altKeyDown=false, keyCode=18 

So the first trace shows a phantom control key press ...

This lead me to the following work-around (Flash Pro script):

import flash.events.KeyboardEvent;
import flash.ui.Keyboard;

stage.addEventListener(KeyboardEvent.KEY_DOWN, onKeyDownOrUpHandler);
stage.addEventListener(KeyboardEvent.KEY_UP, onKeyDownOrUpHandler);

var _ctrlKeyDown:Boolean;
var _altKeyDown:Boolean;

function onKeyDownOrUpHandler(e:KeyboardEvent):void
{   
if (e.keyCode==17 || e.keyCode==18) // then always test both Ctrl
and Alt to work around possible bug:
{
_ctrlKeyDown = e.keyCode == Keyboard.CONTROL;
_altKeyDown = e.keyCode == Keyboard.ALTERNATE;
}
trace(e.type + : _ctrlKeyDown= + _ctrlKeyDown + , _altKeyDown= +
_altKeyDown + , character:  + String.fromCharCode(e.charCode));   
}

So the trick is to flag both ctrlKeyIsDown and _altKeyIsDown every time.
This will override the phantom event.

It would be great if you and/or anybody else could confirm the initial bogus
key down event for the right alt key on press. 
I tested this so far on two systems with MS Vista and tested with various
debug 10 and 10.1 players, stand alone and in browser. In all cases I got
the bogus control event when pressing alt.

If this is a bug I will log it to Adobe's bug base with the discovered
work-around.

Thanks!

- Benny


By the way this is how I modified your code to get the traces I want (in
Flash Pro):

import flash.events.KeyboardEvent;

const CTRL_KEYCODE:int = 17;
const ALT_KEYCODE:int = 18;

var _ctrlKeyDown:Boolean = false;
var _altKeyDown:Boolean = false;

stage.addEventListener(KeyboardEvent.KEY_DOWN, onKeyDownHandler);
stage.addEventListener(KeyboardEvent.KEY_UP, onKeyUpHandler);

function onKeyDownHandler(e:KeyboardEvent):void
{
switch(e.keyCode) {

case CTRL_KEYCODE:
_ctrlKeyDown = true;
break;
case ALT_KEYCODE:
_altKeyDown = true; 
break;
}

trace(onKeyDown: _ctrlKeyDown= + _ctrlKeyDown + , _altKeyDown= +
_altKeyDown + , keyCode=+e.keyCode);

}

function onKeyUpHandler(e:KeyboardEvent):void
{
switch(e.keyCode) {

case CTRL_KEYCODE:
_ctrlKeyDown = false;
break; //your choice if you put break after return
case ALT_KEYCODE:
_altKeyDown = false;
break;
}

trace(onKeyUp: _ctrlKeyDown= + _ctrlKeyDown + , _altKeyDown= +
_altKeyDown + , keyCode=+e.keyCode);

}


-Oorspronkelijk bericht-
Van: flashcoders-boun...@chattyfig.figleaf.com
[mailto:flashcoders-boun...@chattyfig.figleaf.com] Namens Glen Pike
Verzonden: dinsdag 16 november 2010 1:08
Aan: Flash Coders List
Onderwerp: Re: [Flashcoders] How to detect for modifier (alt/ctrl) keys

Yes, but if you don't use keyEvent.ctrlKey in your event handler, but 
check for CTRL and set a flag:

e.g.

public static const CTRL_KEYCODE:int = 17;
private var _ctrlKeyDown:Boolean = false;
//etc

function onKeyDownHandler(e:KeyboardEvent):void
{
switch(e.keyCode) {

case CTRL_KEYCODE:
_ctrlKeyDown = true;
return;
break; //your choice if you put break after return
//case ALT_KEYCODE:
//  _altKeyDown = true; 
//  return;
//  break;
default:
break;
}

trace(onKeyDown: ctrlKeyDown= + _ctrlKeyDown);

}

function onKeyUpHandler(e:KeyboardEvent):void
{
switch(e.keyCode) {

case CTRL_KEYCODE:
_ctrlKeyDown = false;
return;
break; //your choice if you put break after return
//case ALT_KEYCODE:
//  _altKeyDown = false;
/   return;
//  break;
default:
break

RE: [Flashcoders] How to detect for modifier (alt/ctrl) keys

2010-11-19 Thread Benny
The work-around I listed would of course only work if you are just
interested in key combo's with either Alt or Ctrl. 
Something like (right) Alt-Ctrl-5 won't work.

I had a second thought on Henriks comment about Alt vs AltGr and Googled a
bit.


Part of Wiki article:

Control + Alt as a substitute
Originally, US PC keyboards (specifically, the US 101-key PC/AT keyboards)
did not have an AltGr key, it being relevant to only non-US markets; they
simply had left and right Alt keys.

As those using such US keyboards increasingly needed the specific
functionality of AltGr when typing non-English text, Windows began to allow
it to be emulated by pressing the Alt key together with the Control key:

Ctrl+Alt ? AltGr
Therefore, it is recommended that this combination not be used as a modifier
in Windows keyboard shortcuts as, depending on the keyboard layout and
configuration, someone trying to type a special character with it may
accidentally trigger the shortcut,[4] or the keypresses for the shortcut may
be inadvertently interpreted as the user trying to input a special
character.
--

So I think this explains why I get 2 events when pressing the right alt key.

Although the key says Alt it actual behaves like the mentioned AltGr key.

In other words. Flash doesn't actual support pure Alt key behavior but only
AltGr.

- Benny




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


[Flashcoders] How to detect for modifier (alt/ctrl) keys

2010-11-15 Thread Benny
In an application I am building I need to detect whether the (right) alt-key
was pressed in combination with another (letter) and make sure that the
control key isn't being pressed at the same time.

But it looks like the Keyboard events for both MOUSE_DOWN and MOUSE_UP
always return true for ctrlKey (when it is not actual pressed!) while the
Alt key is pressed.

Simplified test code:

import flash.events.KeyboardEvent;

stage.addEventListener(KeyboardEvent.KEY_DOWN, onKeyDownHandler);
stage.addEventListener(KeyboardEvent.KEY_UP, onKeyUpHandler);

function onKeyDownHandler(e:KeyboardEvent):void
{
trace(onKeyDown: e.ctrlKey= + e.ctrlKey + , e.altKey= +
e.altKey);  
}

function onKeyUpHandler(e:KeyboardEvent):void
{
trace(onKeyUp: e.ctrlKey= + e.ctrlKey + , e.altKey= + e.altKey);

}

When I test the code (tested on 2 PC's with Flash 10 or 10.1 Debug player in
Flash pro CS5 or via same version debug players in MSIE/FF browsers) and
press only the right alt key or a key combi e.g. right-alt-5 the traces
report always true for the ctrlKey, so even when it isn't pressed!?

I checked the Adobe bug base, tried Google, but didn't find anything related
so far.

What am I missing?

Thanks.

- Benny

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


RE: [Flashcoders] How to detect for modifier (alt/ctrl) keys

2010-11-15 Thread Benny
Thanks for the tip Glen.

Unfortunately that class also shows the problem of Keyboard.CONTROL (keycode
17) being reported as being down (while it actual isn't) when the right alt
key is being pressed. 

- Benny


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


RE: [Flashcoders] Highligting words in a textField

2010-08-16 Thread Benny
Maybe if you could give a sample text and the words that should be
highlighted we can advise you better. But in a nutshell I would use one or
more RegExp if the words you are looking for are only a few different ones.
If there are many or there is a complex syntax that needs to be analyzed
then probably you should look into a string tokenizer. 

- Benny

-Oorspronkelijk bericht-
Van: flashcoders-boun...@chattyfig.figleaf.com
[mailto:flashcoders-boun...@chattyfig.figleaf.com] Namens ktt
Verzonden: maandag 16 augustus 2010 0:26
Aan: Flashcoders@chattyfig.figleaf.com
Onderwerp: [Flashcoders] Highligting words in a textField

Hello,

I have a multiline text in a dynamic textfield with a scroll.
How is it possible to higlight some words in a textFiled which is splited to
lines (\n) ?

Thank you in advance,
Ktt


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

__ Informatie van ESET NOD32 Antivirus, versie van database
viruskenmerken 5368 (20100815) __

Het bericht is gecontroleerd door  ESET NOD32 Antivirus.

http://www.eset.com



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


[Flashcoders] Flash CS5 input controls with dragable values, what are they called?

2010-07-29 Thread Benny
(the former message probably come not through because of the included image,
so let's retry without ;-)

The Flash CS authoring tool nowadays has input controls (the ones with the
dotted underline) that allow you to click and drag the value out to change
it. For an extension I am building I want to use the same type of control
and am trying to Google if somebody already created such component but I
found nothing so far. That's probably because I am searching with the wrong
key phrases. Does anybody know how these input controls are actually
(officially) called?

Do you know whether somebody already recreated (free or commercial) a AS3 UI
component that mimics such an input control?

Thanks.

- Benny



-Oorspronkelijk bericht-
Van: flashcoders-boun...@chattyfig.figleaf.com
[mailto:flashcoders-boun...@chattyfig.figleaf.com] Namens
flashcoders-ow...@chattyfig.figleaf.com
Verzonden: donderdag 29 juli 2010 2:28
Onderwerp: Flash CS5 input controls with dragable values, what are they
called?

The message's content type was not explicitly allowed


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


RE: [Flashcoders] Error in displaying Hindi Text

2010-06-17 Thread Benny
Make sure the font(s) you use are embedded.

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


RE: [Flashcoders] reading a css from www?

2010-04-18 Thread Benny
You are right about the base path being the html, so you should get to your
css by passing in the complete relative path, so:
'../path_to_css/cssfile.css' when the html is in 'somefolder' en the css is
in 'path_to_css' folder

-Oorspronkelijk bericht-
Van: flashcoders-boun...@chattyfig.figleaf.com
[mailto:flashcoders-boun...@chattyfig.figleaf.com] Namens sebastian
Verzonden: zaterdag 17 april 2010 23:53
Aan: Flash Coders List
Onderwerp: Re: [Flashcoders] reading a css from www?

sweet thanks Benny, this replacement method worked! yaay!

btw, as far as i can tell, the flash file tries to load the files 
relative to the path of the current URL, and not the path relative to 
the SWF itself...

so if if the HTML file is in:

http://mysite.com/somefoloder/index.html

and you load: ('file.css');

then it will look in:

http://mysite.com/somefoloder/file.css

even if the swf is being loaded from:

http://mysite.com/flash/flashfile.swf

If I am wrong, and the path is relative to the swf, then I am completely 
confused as to why i have to use full URL paths and I cant just type 
file.css and get it to load when the swf and the css file are actually 
stored on the server from the same location...

Best,

Seb.


Benny wrote:
 You could use the url from which your swf is loaded, replace the filename
of
 the swf by that of the css.
 
 In your main movie (from top of my haead, i.e. not tested ;-) use
something
 like:
 
 var cssFullURL:String = this.loaderInfo.url.replace(/thecallingfile\.swf
 /,cssFile.css);
 trace(cssFullURL);
 
 ___
 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] reading a css from www?

2010-04-17 Thread Benny
You could use the url from which your swf is loaded, replace the filename of
the swf by that of the css.

In your main movie (from top of my haead, i.e. not tested ;-) use something
like:

var cssFullURL:String = this.loaderInfo.url.replace(/thecallingfile\.swf
/,cssFile.css);
trace(cssFullURL);

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


RE: [Flashcoders] reading a css from www?

2010-04-17 Thread Benny
... or just load the css file relative. As far as I know you are not
required to pass in absolute URLs   

-Oorspronkelijk bericht-
Van: flashcoders-boun...@chattyfig.figleaf.com
[mailto:flashcoders-boun...@chattyfig.figleaf.com] Namens Benny
Verzonden: zaterdag 17 april 2010 14:01
Aan: 'Flash Coders List'
Onderwerp: RE: [Flashcoders] reading a css from www?

You could use the url from which your swf is loaded, replace the filename of
the swf by that of the css.

In your main movie (from top of my haead, i.e. not tested ;-) use something
like:

var cssFullURL:String = this.loaderInfo.url.replace(/thecallingfile\.swf
/,cssFile.css);
trace(cssFullURL);

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

__ Informatie van ESET NOD32 Antivirus, versie van database
viruskenmerken 5035 (20100416) __

Het bericht is gecontroleerd door  ESET NOD32 Antivirus.

http://www.eset.com



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


RE: [Flashcoders] Getting the line index at the caretIndex

2010-04-10 Thread Benny
After *appending* a character the caret is positioned after the last
character input pointing to the next position it will accept input.
Hence when you call getLineIndexOfChar(caret) you ask for info about a none
existing character.

This should work:

var tf:TextField = new TextField();
tf.type = TextFieldType.INPUT;
tf.border=true;
tf.multiline = true;
tf.addEventListener(Event.CHANGE, onChange);
addChild(tf);

function onChange(event:Event):void
{
 var newCharIndex:int = tf.caretIndex-1;
 var line:int = tf.getLineIndexOfChar(newCharIndex);
 
 trace(caretIndex= + tf.caretIndex + , newCharIndex= + newCharIndex
+ 
   , char= +
tf.text.charAt(newCharIndex).replace(/\r/,\\r) + , line= + line);
}


Cheers, Benny

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


RE: [Flashcoders] OOP Books (OT)

2010-03-10 Thread Benny
Hi Susan I cannot recommend any OOP book but I can recommend Lynda.com. 
Lynda.com has some great video courses, like
http://www.lynda.com/home/DisplayCourse.aspx?lpk2=759
Which amongst other covers OOP fundamentals and common design patterns.


- Benny

-Oorspronkelijk bericht-
Van: flashcoders-boun...@chattyfig.figleaf.com
[mailto:flashcoders-boun...@chattyfig.figleaf.com] Namens Susan Day
Verzonden: woensdag 10 maart 2010 19:29
Aan: Flash Coders List
Onderwerp: Re: [Flashcoders] OOP Books (OT)

On Wed, Mar 10, 2010 at 12:23 PM, Mattheis, Erik (MIN - WSW) 
ematth...@webershandwick.com wrote:

 I got AS 3 w/Design Patterns right when I delved into AS3 and I found the
 examples too long and complicated to follow. I would not recommend it as
an
 introduction to OOP.


Noted. And your thoughts, if any, on The Object-Oriented Thought Process?
Susan
___
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

__ Informatie van ESET NOD32 Antivirus, versie van database
viruskenmerken 4932 (20100310) __

Het bericht is gecontroleerd door  ESET NOD32 Antivirus.

http://www.eset.com



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


RE: [Flashcoders] OOP Books (OT)

2010-03-10 Thread Benny
http://www.adobe.com/devnet/actionscript/articles/oop_as3.html



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


RE: [Flashcoders] Problem Importing Class

2010-03-05 Thread Benny
Hi susan,

In the 'other package' try:

import Star;

var myStar:Star = new Star();
addChild(myStar);

---
Why are you getting the error? .. because you are trying to cast 'nothing'
as a Star. Because Flash can't cast 'nothing' it tells you it's missing an
argument. 
---

Regards, Benny

-Oorspronkelijk bericht-

..

This code works by itself. However, when I call it in the other package with
the following lines:

import Star;
// var star:Sprite = new Sprite();
(whether commented out or not)
Star();

I get the error:

1136 Incorrect number of arguments. Expected 1. Star.as

for the last of the lines in the importing pkg. What argument is it
expecting?
TIA,
Susan

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


RE: [Flashcoders] OOP Tutorial

2010-03-05 Thread Benny
No need for inheritance then, just give your Star class the desired
parameters in the constructor, e.g

package
{
import flash.display.MovieClip;

public class Star extends MovieClip
{
public function Star(lineColor:uint, fillColor:uint)
{
graphics.lineStyle(1, lineColor);
graphics.beginFill(fillColor);
graphics.moveTo(144, 277);
graphics.lineTo(188, 184);
graphics.lineTo(288, 170);
graphics.lineTo(216, 98);
graphics.lineTo(232, 0);
graphics.lineTo(144, 47);
graphics.lineTo(55, 1);
graphics.lineTo(72, 100);
graphics.lineTo(0, 170);
graphics.lineTo(99, 184);
graphics.endFill();
}
}
}

When you then instantiate your class you just pass on the desired
parameters, like:

import Star;

var myStar:Star = new Star(0xFF, 0xFF);
addChild(myStar);

- Benny


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


RE: [Flashcoders] MultiLevel ContextMenu

2010-02-19 Thread Benny
Flash doesn't support that or actually even prevents us to come up with a
custom context menu.. 
In the past some flashers worked around that limitation by capturing the
right click mouse event in javascript and then communicate the event via a
local connection to the flash movie which than could built a custom context
menu. This worked not in all browsers though as far as I can remember.
Google will probably remember it better ;-)


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


RE: [Flashcoders] Re: import documents into flash

2010-02-18 Thread Benny
@valentin: Air 2 is able to call commandline tools just fine.


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


RE: [Flashcoders] Flash 10 - using basic RTL features without CS4

2010-02-11 Thread Benny
The standard TextField has no support for RTL text out of the box. But in
the past some clever devs had gone through a lot of trouble to make it
somehow possible, e.g: http://www.red-id.com/blog/category/RTL-Flash.aspx

If you the linked solution (or another one you may come across) works
(100%?) for RTL (+BIDI) please let us know.

- Benny




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


RE: [Flashcoders] Runtime Font embedding

2010-02-11 Thread Benny
Maybe this will help you a step in the right direction:

The IDE uses C:\Program Files\Adobe\Adobe Flash CS4\en\First
Run\FontEmbedding\UnicodeTable.xml

http://livedocs.adobe.com/flash/9.0/main/0894.html
http://blog.madebypi.co.uk/2009/06/01/flash-character-embedding-adding-addit
ional-ranges/
http://www.epic.dk/flash-unicodetable/flash-unicodetable-generator.php


- Benny

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


RE: [Flashcoders] OT: finding where a web site lives

2010-01-11 Thread Benny
Try: http://www.whoishostingthis.com/






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


RE: [Flashcoders] Som HTML tags do not work in Flash?

2010-01-02 Thread Benny
Did you set tf.multiline = true; 

Groet, Benny

-Oorspronkelijk bericht-
Van: flashcoders-boun...@chattyfig.figleaf.com
[mailto:flashcoders-boun...@chattyfig.figleaf.com] Namens Cor
Verzonden: zaterdag 2 januari 2010 16:05
Aan: 'Flash Coders List'
Onderwerp: [Flashcoders] Som HTML tags do not work in Flash?

Hi List,

I load my text from a mySQL database using AMFPHP.
In Flash I have a:
 var tf:TextField = new TextField();
 tf.htmlText = data[0][0]; 
 trace(typeof = +typeof(aData[0][0])); //returns string
 addChild(tf);

Everything shows.
But when I use HTML in my text in the database, these show correctly:

IItalic/I
BBold/B
UUnderline/U

But the below do not work:

BR
BR /
PParagraaf/P

Any ideas??

Kind regards
Cor van Dooren

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

__ Informatie van ESET NOD32 Antivirus, versie van database
viruskenmerken 4737 (20100102) __

Het bericht is gecontroleerd door  ESET NOD32 Antivirus.

http://www.eset.com



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


RE: [Flashcoders] OTish - CMS

2009-11-04 Thread Benny
www.dotnetnuke.com is a longstanding and leading ASP.net open source CMS

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


[Flashcoders] project planning tools

2009-07-18 Thread Benny
I am looking for tips/experiences for a simple/intuitive and affordable gantt 
based (offline) planning tool which should run on Windows vista.

Which tools are you using to plan your Flash projects and why would you 
recommend it?



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


RE: [Flashcoders] how to uncompress a compressed bytearray with PHP

2008-10-03 Thread Benny
Thanks Juan Pablo Califano.

I'm already sending the data in binary form so that's is probably not the
problem.
You are right about that the php decompression should be done with gzinflate
(I did test with it before but that didn't work either so I thought I should
try gzuncompress ;)

When I compare the deflating results of the same string in PHP and Flash I
noticed that flash started with two extra bytes while the rest of the output
was the same.

Next I added this code to the PHP test script to remove the two extra
leading bytes:

  mb_internal_encoding(UTF-8);
  $encoded = mb_substr($_POST[XMLString], 2);

Now when I compare the string in $encoded with the encoded string produced
by PHP deflate() then both seem to be exactly the same. So I expected that 

  $decoded = gzuncompress($encoded);
 
would now return the original string but no, an empty string is returned!?

If however I copy (i.e. hardcode) the compressed string into $encoded and
then execute 
  
  $decoded = gzuncompress($encoded);

Then it Works; I get the original text!?

Big question now why does it work with the hardcoded compressed string and
not with runtime compressed string, they seem to be exactly the same??

Any ideas?

BTW: thanks for your time :)


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


RE: [Flashcoders] how to uncompress a compressed bytearray with PHP

2008-10-03 Thread Benny
(please ignore previous reply - contained mistakes regarding gzuncompress
while I meant gzinflate)

Thanks Juan Pablo Califano.

I'm already sending the data in binary form so that's is probably not the
problem.
You are right about that the php decompression should be done with gzinflate
(I did test with it before but that didn't work either so I thought I should
try gzuncompress ;)

When I compare the deflating results of the same string in PHP and Flash I
noticed that flash started with two extra bytes while the rest of the output
was the same.

Next I added this code to the PHP test script to remove the two extra
leading bytes:

  mb_internal_encoding(UTF-8);
  $encoded = mb_substr($_POST[XMLString], 2);

Now when I compare the string in $encoded with the encoded string produced
by PHP deflate() then both seem to be exactly the same. So I expected that 

  $decoded = gzinflate($encoded);
 
would now return the original string but no, an empty string is returned!?

If however I copy (i.e. hardcode) the compressed string into $encoded and
then execute 
  
  $decoded = gzinflate($encoded);

Then it Works; I get the original text!?

Big question now why does it work with the hardcoded compressed string and
not with runtime compressed string, they seem to be exactly the same??

Any ideas?

BTW: thanks for your time :)


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


RE: [Flashcoders] how to uncompress a compressed bytearray with PHP

2008-10-03 Thread Benny
We are getting closer ;-)

The code you provided worked for me too. 
When I compare my code to yours I notice that I am using the $_POST array
while you are using the PHP input stream. The other major difference is the
fact that I am POSTing using via an URLVariables instance.

When I change both in my code then everything indeed works fine.

The only problem now is that in the production code I have to send several
ByteArray objects to the server in one go. And I have to process them
separately in the PHP script. Hence I thought the obvious thing would be to
assign the various vars to an URLVariables object and send that as the
URLRequest data. On the PHP side I wanted then to access those vars again as
members of the $_POST array and gzinflate the compressed vars there for
further processing.

Can you think of any solution that would make this possible?

The only thing which comes to my mind at the moment is parsing the php input
string by hand but I still would expect that the $_POST array should just
work too, after all it seems it contains the correct compressed string. But
when I feed that string to the gzinflate function I get an empty string in
return and when I feed it the exact same string hardcoded then it returns
the correct uncompressed string... I must be missing something obvious ;-)

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


RE: [Flashcoders] how to uncompress a compressed bytearray with PHP

2008-10-03 Thread Benny
 There's one problem with using URLVariables: it works on NUL-terminated
Strings
You're right, so URLVariables is now out of the picture ;-)

I think your class would indeed do the job but because I want to keep the
client code as light as possible I think I'll just send one big compressed
ByteArray to the server inflate it and decode the AMF data using the AMF
capabilities the Zend Framework will bring in the near future. 

Thank you for your time and great input!!
Cheers, Benny

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


[Flashcoders] how to uncompress a compressed bytearray with PHP

2008-10-02 Thread Benny
I am sending a compressed bytearray to PHP:

 

var XMLOut:ByteArray = new ByteArray();

XMLOut.writeUTFBytes(rootitem1just an example/item1/root);

XMLOut.compress();

. cut .

 

The data is POSTed (with URLLoader in var XMLString) to
mydomain.com/save.php:

 

?php   

  $XMLString = gzuncompress($_POST[XMLString ]); 

  $handle = fopen(content/test.xml, w+b);

  fwrite($handle, $ XMLString);

  fclose($handle);

?

 

The result of this is that test.xml is being created but without any
content.

(BTW: If I leave out the compression/decompression part then the file is
created with the expected content)

 

Should this actually work with gzuncompress and if so why might it be
failing here?

Or should the uncompressioning be handled differently?

 

 

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


RE: [Flashcoders] search engine optimization for flash sites

2007-09-06 Thread Benny
Hi Robin,

Google DOES index flash content (out of the box) but there are some
limitations. The biggest one is that Google only indexes the text and links
that are embedded in the swf. So dynamically loaded content will NOT be
indexed.

Therefore most pro's will go another direction, the one of 'progressive
enhancement'. This means you first build the html version of your site
(inclusive internal linking) and build your swf in such way that it loads
that same content. Then you setup your index page with SWFObject. This will
first load the html version of your site in a div and immediately overwrites
that div with the flash version (i.e. if possible). 

Now if a indexing robot visits your site they will only get as far as the
html version, because they don't pass  SWFObject's flash detection check. 

Don’t forget to disallow indexing of your swf through an entry in your
robots.txt file. 

Regards,
Benny

P.S. SWFAddress (or alternatives) is not persé needed for good SEO but does
have a positive effect on the accessibility and user experience of your
site. Another benefit of SWFAddress is it's deep linking capability. So if
someone finds any page of your site in Google you can direct them to the
exact spot in your swf site, without deep linking the will always end up at
the start section of your swf site.


___
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] accessing super fields

2007-08-20 Thread Benny
Looks like you forgot to actually extend the superclass, try

class SubClass extends superclass {

- Benny

-Oorspronkelijk bericht-
Van: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Namens Hans Wichman
Verzonden: maandag 20 augustus 2007 13:51
Aan: Flashcoders mailing list
Onderwerp: [Flashcoders] accessing super fields

Hi,

lets say i have a superclass:

class SuperClass {
 private var _test:String = null;
}

and a subclass:

class SubClass {
private function _testFunction () {
  super._test = foo;
trace (super._test);
}
}


this traces undefined.

If I remove the super. it works, but I like to know when I'm referencing
super class fields.

It is fixed as well, when I nicely wrap the setting of _test in a function,
as I should, but I'm still wondering why it fails.

Any ideas?

greetz
JC

___
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] accessing super fields

2007-08-20 Thread Benny
On a second look: first you don't need the super statement because
SuperClass' _test is already inherited by the SubClass and second super is
only supported with method members, see LiveDocs:
http://livedocs.adobe.com/flash/9.0/main/wwhelp/wwhimpl/common/html/wwhelp.h
tm?context=LiveDocs_Partsfile=1337.html

Greetz 
Benny

-Oorspronkelijk bericht-
Van: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Namens Hans Wichman
Verzonden: maandag 20 augustus 2007 15:40
Aan: flashcoders@chattyfig.figleaf.com
Onderwerp: Re: [Flashcoders] accessing super fields

Hi Benny,

Sorry, copy paste error, of course the subclass looks like:  subclass
extends superclass etc

:)

Still no go :)

greetz
JC




On 8/20/07, Benny [EMAIL PROTECTED] wrote:

 Looks like you forgot to actually extend the superclass, try

 class SubClass extends superclass {

 - Benny

 -Oorspronkelijk bericht-
 Van: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED] Namens Hans Wichman
 Verzonden: maandag 20 augustus 2007 13:51
 Aan: Flashcoders mailing list
 Onderwerp: [Flashcoders] accessing super fields

 Hi,

 lets say i have a superclass:

 class SuperClass {
 private var _test:String = null;
 }

 and a subclass:

 class SubClass {
private function _testFunction () {
  super._test = foo;
 trace (super._test);
 }
 }


 this traces undefined.

 If I remove the super. it works, but I like to know when I'm referencing
 super class fields.

 It is fixed as well, when I nicely wrap the setting of _test in a
 function,
 as I should, but I'm still wondering why it fails.

 Any ideas?

 greetz
 JC

 ___
 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


__ NOD32 2470 (20070819) Informatie __

Dit bericht is gecontroleerd door het NOD32 Antivirus Systeem.
http://www.nod32.nl


___
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] accessing super fields

2007-08-20 Thread Benny
 As Benny said, you dont need to, no i know! But appearantly it works
different for fields than for methods.
It actually doesn't work *different* but it doesn't work *per design* for
fields. 
The docs (see the link I provided) clearly state that it is only supported
with methods. There is no mention of that it should only work with
overridden methods but that's of course the logical place where you would
use super (and of course in the constructor). 

- Benny 


___
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] AS3 instantiating a new class object from a string value

2007-07-26 Thread Benny
MaTT, 

See getDefinitionByName() function in flash.utils
It will give you a reference to the class name that is specified by a
string.
You can then use that reference to get an instance of that class.

Of course you must make sure the class is loaded.

Regards,
Benny


-Oorspronkelijk bericht-
Onderwerp: [Flashcoders] AS3 instantiating a new class object from a string
value

Hi, I'm trying to instantiate a new class object from a xml attribute which
is a string, but its not having any of it.
I've tried casting the string to an object and also using this['class_id']
etc but no luck.

Does someone have a solution?


___
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] Found an AS3 RegExp Bug.

2007-06-09 Thread Benny
The results you get are as expected.
To get the output you desire try:

var code:String = alert('foo');;
code = code.replace(/'/g,\\');
trace(code);

- Benny

-Oorspronkelijk bericht-
Van: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Namens Isaac Rivera
Verzonden: zaterdag 9 juni 2007 19:09
Aan: flashcoders@chattyfig.figleaf.com
Onderwerp: Re: [Flashcoders] Found an AS3 RegExp Bug.

Let me correct a paste mistake there:

THE FOLLOWING CODE:

var pattern:RegExp = /[^\\]'/;
var code:String = alert('foo');;
code = code.replace(pattern, \\');
code = code.replace(pattern, \\');

traces: alert\'fo\');

Should it not trace: alert(\'foo\'); instead?

Isaac Rivera
Technology Director :: Experience Design Group
America Online :: New York City
p 212 652-6308 :: c 347 342-2195


On Jun 9, 2007, at 1:04 PM, Isaac Rivera wrote:

 The following code:

 var pattern:RegExp = /[^\\]'/;
 var code:String = alert(\'foo\');;
 code = code.replace(pattern, \\');
 code = code.replace(pattern, \\');

 traces alert\'fo\'); instead of alert(\'foo\');

 Isaac Rivera
 Technology Director :: Experience Design Group
 America Online :: New York City
 p 212 652-6308 :: c 347 342-2195


 ___
 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


__ NOD32 2320 (20070609) Informatie __

Dit bericht is gecontroleerd door het NOD32 Antivirus Systeem.
http://www.nod32.nl


___
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] AS3 RegExp (bug?)

2007-05-02 Thread Benny
I have some troubles with RegExp in Flash CS3 (AS3). It seems whenever a
pattern ends with .* AND has the Global flag set flash freezes.

Simplified sample code:

  var re:RegExp=/.*/g;
  var str:String=one two three;
  trace(str.match(re)); 

Why does Flash CS3 (AS3) freeze with this code, is it a bug or am I missing
something obvious?

- Benny


___
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] AS3 RegExp (bug?)

2007-05-02 Thread Benny
Thanks for confirming this. I submitted a bug report with Adobe.

I noticed that if the pattern is used with exec command the same thing
happens. Aafter the last actual match is found it will not return null for
the result so in a while loop (as demonstrated in the Adobe docs for the
exec method) you'll get trapped in an endless loop. But with the exec method
we at least can come up with a work-around by testing if the new lastindex
is  then the previous lastIndex. If not then stop the search.


-Oorspronkelijk bericht-
Van: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Namens Andrés González 
Aragón
Verzonden: woensdag 2 mei 2007 17:39
Aan: flashcoders@chattyfig.figleaf.com
Onderwerp: Re: [Flashcoders] AS3 RegExp (bug?)

Is not a cs3 bug, is a player bug. I cut n paste your code in cs3 and it
freezes, in eclipse with flex builder plugin the same, but eclipse didn't
freeze, only the player do.

___
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] The great CS3 Swindle

2007-03-30 Thread Benny
Hi John, 

Thanks for sharing your thoughts with us and for pushing for public
explanations.

I contacted Dutch Adobe support and this is the explanation they gave: 

---
 Thankyou for your email to Adobe Cs.
Why are European products more expensive than UE or American products? 
The price of software in EMEA reflects both the additional expense to
develop and test Adobes applications for local markets and operating
systems, as well as for the delivery of complimentary Warranty support.
Adobes complimentary Warranty support covers product installation and defect
issues for the life of the current version of Adobes desktop applications. 

Although Adobe Europe and Adobe US are different parts of the same global
company European Marketing strategies and pricing are not directly related
on those used for the US. The prices are not simply converted from the
dollar pricing used for US products, therefore,  the pricing used for each
country in the EMEA region may vary.

Should you require any further information, please do not hesitate to
contact us.
---

My question: what is so specific about our local market that requires those
(huge?) additional expenses for tests and development to such extend that
prices have to almost double or if I understand correct even are 2.5 times
as high for UK customers then US customers. 

By the way you would think that with the whole emphasis on local support
that the support person would answer in my local language (Dutch) but no,
the answer was in English and for further info I could phone to the Adobe
office in the UK or in Ireland. My point if I have to pay for local support
I want local support if not I would rather contact the American office and
pay the much lower price just like out American friends do. In fact I even
don't need support in my language but just to make the point... ;-)

I hope you, actual the people in charge of this ridicules pricing policy,
would offer us an option to order from a US store. Preferable downloadable
(upgrade/upsell) studio versions but others might be more interested in
boxed versions. I don't mind if that means that we must contact the US
support desk for assistance ;-)

John if you could make that happen I will pronounce you in advance: men of
the year and maybe I'll even consider to nominate you for the Nobel Peace
Prize ;-)

Thanks for listening.

cu,
Benny 

-Oorspronkelijk bericht-
Van: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] Namens John Dowdell
Verzonden: vrijdag 30 maart 2007 22:04
Aan: flashcoders@chattyfig.figleaf.com
Onderwerp: Re: [Flashcoders] The great CS3 Swindle

jd wrote:
 Thanks for the response John, please don't take this personally, - but I
 suspect the legitimate reason is because we can

... and if that's the case, then I'd like to see those decisionmakers 
defend it in open debate.

But it's difficult for me to see intentional discrimination as the root 
cause... doesn't match up with what I see of people here. The DNA is 
towards global participation, so I suspect there are real constraints in 
the way of flat pricing.

I've still got the action item to keep pressing for public explanations 
about why software companies show such similar disparities across 
regions. Such a mystery does no-one any good. The ZDNet/CNET articles 
today likely caught org-wide attention, so I've got some more ammo this 
week ;-)





-- 
John Dowdell . Adobe Developer Support . San Francisco CA USA
Weblog: http://weblogs.macromedia.com/jd
Aggregator: http://weblogs.macromedia.com/mxna
Technotes: http://www.macromedia.com/support/
Spam killed my private email -- public record is best, 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


__ NOD32 2158 (20070330) Informatie __

Dit bericht is gecontroleerd door het NOD32 Antivirus Systeem.
http://www.nod32.nl


___
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] Flair Pattern?

2007-01-29 Thread Benny
The pattern is similar to Decorator (as they acknowledge in the book)  
but different in that it allows you to add and remove functionality  
at runtime. ...

Hmmm ...sounds interesting.
Besides the book (which I don't have access to unfortunately) are there any
online resources where I can find more details (description/code samples)
about the flair pattern?

- Benny


___
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