Hi Klaus,

I think there are "issues" with using the same object as both an event
handler and getURL callback. I probably caught that in the #svg
channel on irc.freenode.org. Try googling svg.jibbering.com to see if
the logs have any useful info.

On 8/24/05, arosyada <[EMAIL PROTECTED]> wrote:
> Hi
> in line :
> addEventListener("click",this,false)
> 'this' will be handled by 'Strange.prototype.handleEvent'
> 
> but in line :
> getURL("strange.svg",this);
> 'this' refers to 'Strange'
> 
> maybe you can use something like :
> getURL("strange.svg",this.callback);
> 
> Strange.prototype.callback = function(response){
> }
> 
> for addEventListener, in ASV 'this' will refer to the object, but in
> CSV and Batik, 'this' refers to js 'Function' native object.


Hi amri,

Did you test this? The 'this' keyword should be a reference to the
Strange object in both cases, and from my quick test in Batik 1.6 this
seems to be the case. (I haven't tested CSV.)


> amri
> 
> --- In [email protected], Klaus Förster
> <[EMAIL PROTECTED]> wrote:
> > are there any know issues with using getURL in combination with
> > prototypes, handleEvent and operationComplete in ASV3/6? the
> following
> > code yields a parameter type mismatch error for getURL
> passing "this" as
> > callback-function argument and i don't see a reason why it should ;-
> )
> >
> > strange.svg:
> > <svg>
> > <script type="text/javascript"><![CDATA[
> > function Strange() {
> >      document.getElementById("r").addEventListener
> ("click",this,false);
> > }
> > Strange.prototype.handleEvent = function(evt) {
> >      getURL("strange.svg",this);
> > }
> > Strange.prototype.operationComplete = function(req) {
> >      alert(req.success);
> > }
> > new Strange();
> >
> > ]]></script>
> > <rect id="r" x="20" y="20" width="40" height="30" />
> > </svg>
> >
> > any ideas how to solve this?
> > klaus
> 
> 
> 
> 
> 
> 
> -----
> To unsubscribe send a message to: [EMAIL PROTECTED]
> -or-
> visit http://groups.yahoo.com/group/svg-developers and click "edit my 
> membership"
> ----
> Yahoo! Groups Links
> 
> 
> 
> 
> 
> 
>


------------------------ Yahoo! Groups Sponsor --------------------~--> 
<font face=arial size=-1><a 
href="http://us.ard.yahoo.com/SIG=12ht0gfch/M=362131.6882499.7825260.1510227/D=groups/S=1706030389:TM/Y=YAHOO/EXP=1124888407/A=2889191/R=0/SIG=10r90krvo/*http://www.thebeehive.org
">Get Bzzzy! (real tools to help you find a job) Welcome to the Sweet Life 
- brought to you by One Economy</a>.</font>
--------------------------------------------------------------------~-> 

-----
To unsubscribe send a message to: [EMAIL PROTECTED]
-or-
visit http://groups.yahoo.com/group/svg-developers and click "edit my 
membership"
---- 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/svg-developers/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to