Revision: 4337 http://vexi.svn.sourceforge.net/vexi/?rev=4337&view=rev Author: mkpg2 Date: 2012-01-24 02:56:14 +0000 (Tue, 24 Jan 2012) Log Message: ----------- Fix. Do not format decimal point if scale<0.
Modified Paths: -------------- trunk/org.vexi-library.js/src/main/java/org/ibex/js/JSNumber.java Modified: trunk/org.vexi-library.js/src/main/java/org/ibex/js/JSNumber.java =================================================================== --- trunk/org.vexi-library.js/src/main/java/org/ibex/js/JSNumber.java 2012-01-20 03:18:27 UTC (rev 4336) +++ trunk/org.vexi-library.js/src/main/java/org/ibex/js/JSNumber.java 2012-01-24 02:56:14 UTC (rev 4337) @@ -117,7 +117,8 @@ }else if("toDecimalString".equals(keyStr)){ int dpMin = JSU.getArg_int(args, 0, 0); int dpMax = JSU.getArg_int(args, 1, 20); - String format = "0."; + String format = "0"; + if(dpMin>0) format+="."; for(int i=0; i<dpMin; i++) format+="0"; for(int i=0; i<dpMax-dpMin; i++) format+="#"; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------------ Keep Your Developer Skills Current with LearnDevNow! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-d2d _______________________________________________ Vexi-svn mailing list Vexi-svn@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/vexi-svn