# HG changeset patch # User Adam Chlipala # Date 1253372169 14400 # Node ID 6f34950825b6b1e3c66561f516f46e061779b125 # Parent 53b9aeac676c2658221d30cd77961640418c4d42 Hopefully fixed Jscomp bug that was breaking Grid diff -r 53b9aeac676c -r 6f34950825b6 demo/more/grid.ur --- a/demo/more/grid.ur Fri Sep 18 19:30:09 2009 -0400 +++ b/demo/more/grid.ur Sat Sep 19 10:56:09 2009 -0400 @@ -57,7 +57,8 @@ Updating : source bool, Selected : source bool}, Selection : source bool, - Filters : $(map thd3 M.cols)} + Filters : $(map thd3 M.cols), + Sort : source (option (M.row -> M.row -> bool))} fun newRow cols row = rowS <- source row; @@ -86,11 +87,13 @@ rows <- Dlist.create; sel <- source False; + sort <- source None; return {Cols = cols, Rows = rows, Selection = sel, - Filters = filters} + Filters = filters, + Sort = sort} fun sync {Cols = cols, Rows = rows, ...} = Dlist.clear rows; @@ -218,7 +221,10 @@ return (previous && this)) (fn _ => return True) [_] M.folder M.cols grid.Cols grid.Filters row, - Sort = return (Some (fn _ _ => return True))} + Sort = f <- signal grid.Sort; + return (Option.mp (fn f r1 r2 => r1 <- signal r1.Row; + r2 <- signal r2.Row; + return (f r1 r2)) f)} grid.Rows} Monad.mapR2 [aggregateMeta M.row] [id] [id] diff -r 53b9aeac676c -r 6f34950825b6 src/jscomp.sml --- a/src/jscomp.sml Fri Sep 18 19:30:09 2009 -0400 +++ b/src/jscomp.sml Sat Sep 19 10:56:09 2009 -0400 @@ -1055,7 +1055,7 @@ (strcat (str "cs(function(){" :: locals @ [str "return ", - compact inner e, + (*compact inner*) e, str "})"]), st) end