Agile Ajax

GWTaculous Grows a Little More

GWTaculous keeps plodding along a little more. I've got the Parallel effects base class done and am working my way through the simple effects. Highlight and Move are done and Scale is up next.

I've got the original effects on the left hand side for comparison. I'm finding that I have to pull some of the style effects out of Prototype.js. I'm stuffing them in a DOMX class (with the whole browser specific DOMXImpl tree) for possible reusability. I'm not sure of all of the choices I've made there, but that's what refactoring is for.

I've also discovered that the GWT parseDouble() and parseFloat() are not like the Javascript parseFloat(). The Javascript one will slurp up any old crap and try to spit out a number. The Java/GWT variety will barf on invalid strings. One look will tell you why:

public static double parseDouble(String s) throws NumberFormatException {    return FloatingDecimal.readJavaFormatString(s).doubleValue();}

The GWT version isn't simply a wrapper around the Javascript version. Yes, this sort of precision in language and library can cost time, but it also avoids errors. Anyhow, lesson learned. Now my Move doesn't go back to the starting point with each click.

Technorati Tags: , , ,

Topics: ,

Leave a comment

Powered by WP Hashcash

About Pathfinder

  • We design and build extraordinary applications for companies looking to make the next great idea a reality.
  • learn more

Topics

WordPress

Comments about this site: info@pathf.com