MooFlow Firefox Uncaught Exception Fix 8

Posted by Jason on March 23, 2009

I am using MooFlow for a project at work and it is absolutely fantastic. Nothing else gives the ease of use and nice look like MooFlow. However, it kept throwing an uncaught exception in Firefox:

Error: uncaught exception: [Exception... "Component returned failure code: 0x80040111 (NS_ERROR_NOT_AVAILABLE) [nsIDOMCanvasRenderingContext2D.drawImage]” nsresult: “0×80040111 (NS_ERROR_NOT_AVAILABLE)” location: “JS frame :: http://your-server/MooFlow.js :: anonymous :: line 423″ data: no]

I have figured out a simple fix for this.

In the file MooFlow.js look for the following line of code:

ctx.drawImage(i, 0, 0, arg.width, arg.height);

And change it to this:

try {
ctx.drawImage(i, 0, 0, arg.width, arg.height);
} catch(err) {}

And that will do it!

Note: this “fix” will disable refllections in the firefox browser.

Trackbacks

Use this link to trackback from your own site.

Comments

Leave a response

  1. Primalmotion Wed, 01 Apr 2009 01:11:14 UTC

    Thanks dude!

  2. benson bear Sat, 04 Apr 2009 00:15:46 UTC

    Hey, how about that other stupid exception trying to open a frame’s document and write into it in the newest Firefox? I am getting that too all of a sudden in similar cirucmstances but noone else seems to be. Have you found out what it is?

    I can open lots of iframe documents and write into them, just not some. Cant see the difference

  3. Jason Sat, 04 Apr 2009 07:37:33 UTC

    Hi Benson,

    I have experienced similar issues with the latest firefox. In my experience, my code would retrieve values set in another frame several times, then at the end of the function it would fail to do more of those operations. At some point in time, it was as though the window object had become corrupt.

    The way I solved it was to define a variable at the very top of my function that would contain the reference to the window object. This solved it for me.

    Hope this helps.

  4. mgsmus Thu, 09 Apr 2009 02:11:42 UTC

    Thanks. That solved error but i can’t see any reflection in FF, but demos at mooflow are working good. Any idea?

  5. lizux Tue, 28 Apr 2009 22:36:27 UTC

    // just change this to the one below
    // var i = arg.img.clone();
    var i = arg.img.clone().set(‘src’, arg.img.src);
    and this works fine in mootools 1.2.1

  6. Fonsan Thu, 02 Jul 2009 07:58:13 UTC

    Thanx a bunch, saved me some time

  7. BriAnn Mon, 27 Jul 2009 16:25:23 UTC

    Wow, lizux that worked great for me too in mootools 1.2.3, reflections are there. Only problem I’m having now is the bridge with ReMooz.

  8. Thomas Tue, 30 Mar 2010 03:14:36 UTC

    @lizux thanks a lot, that’s it.

Comments


Clicky Web Analytics