Mercurial > urweb
comparison src/monoize.sml @ 571:86d324061ddc
Switch to using dyn() function in JavaScript
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Sun, 21 Dec 2008 12:01:00 -0500 |
parents | 162d5308e34f |
children | 57018f21cd5c |
comparison
equal
deleted
inserted
replaced
570:af0df56ecc2c | 571:86d324061ddc |
---|---|
1848 (L'.EFfiApp ("Basis", "get_script", [(L'.ERecord [], loc)]), | 1848 (L'.EFfiApp ("Basis", "get_script", [(L'.ERecord [], loc)]), |
1849 loc)), loc)) | 1849 loc)), loc)) |
1850 | 1850 |
1851 | "dyn" => | 1851 | "dyn" => |
1852 (case #1 attrs of | 1852 (case #1 attrs of |
1853 (*L'.ERecord [("Signal", (L'.ESignalReturn e, _), _)] => (e, fm) | 1853 (*L'.ERecord [("Signal", (L'.EApp ((L'.EAbs (_, _, _, (L'.ESignalReturn (L'.ERel 0, _), _)), _), |
1854 | L'.ERecord [("Signal", (L'.EApp ((L'.EAbs (_, _, _, (L'.ESignalReturn (L'.ERel 0, _), _)), _), | |
1855 e), _), _)] => (e, fm) *) | 1854 e), _), _)] => (e, fm) *) |
1856 | 1855 |
1857 L'.ERecord [("Signal", e, _)] => | 1856 L'.ERecord [("Signal", e, _)] => |
1858 ((L'.EStrcat | 1857 ((L'.EStrcat |
1859 ((L'.EPrim (Prim.String "<script type=\"text/javascript\">"), loc), | 1858 ((L'.EPrim (Prim.String "<script type=\"text/javascript\">dyn("), loc), |
1860 (L'.EStrcat ((L'.EJavaScript (L'.Script, | 1859 (L'.EStrcat ((L'.EJavaScript (L'.Script, e), loc), |
1861 (L'.ELet ("signal", (L'.TSignal | 1860 (L'.EPrim (Prim.String ")</script>"), loc)), loc)), loc), |
1862 (L'.TFfi ("Basis", "string"), loc), | |
1863 loc), | |
1864 e, | |
1865 (L'.EWrite (L'.ERel 0, loc), loc)), loc)), loc), | |
1866 (L'.EPrim (Prim.String "</script>"), loc)), loc)), loc), | |
1867 fm) | 1861 fm) |
1868 | _ => raise Fail "Monoize: Bad dyn attributes") | 1862 | _ => raise Fail "Monoize: Bad dyn attributes") |
1869 | 1863 |
1870 | "submit" => normal ("input type=\"submit\"", NONE, NONE) | 1864 | "submit" => normal ("input type=\"submit\"", NONE, NONE) |
1871 | 1865 |