comparison src/monoize.sml @ 599:889dc9fceb3a

Use header to set default script type
author Adam Chlipala <adamc@hcoop.net>
date Sun, 11 Jan 2009 10:22:19 -0500
parents 4c2c740c6931
children 7c3c21eb5b4c
comparison
equal deleted inserted replaced
598:4c2c740c6931 599:889dc9fceb3a
1896 (case attrs of 1896 (case attrs of
1897 [("Signal", (L'.EApp ((L'.EAbs (_, _, _, (L'.ESignalReturn (L'.ERel 0, _), _)), _), 1897 [("Signal", (L'.EApp ((L'.EAbs (_, _, _, (L'.ESignalReturn (L'.ERel 0, _), _)), _),
1898 e), _), _)] => (e, fm) 1898 e), _), _)] => (e, fm)
1899 | [("Signal", e, _)] => 1899 | [("Signal", e, _)] =>
1900 ((L'.EStrcat 1900 ((L'.EStrcat
1901 ((L'.EPrim (Prim.String "<script type=\"text/javascript\">dyn("), loc), 1901 ((L'.EPrim (Prim.String "<script>dyn("), loc),
1902 (L'.EStrcat ((L'.EJavaScript (L'.Script, e, NONE), loc), 1902 (L'.EStrcat ((L'.EJavaScript (L'.Script, e, NONE), loc),
1903 (L'.EPrim (Prim.String ")</script>"), loc)), loc)), loc), 1903 (L'.EPrim (Prim.String ")</script>"), loc)), loc)), loc),
1904 fm) 1904 fm)
1905 | _ => raise Fail "Monoize: Bad dyn attributes") 1905 | _ => raise Fail "Monoize: Bad dyn attributes")
1906 1906
1917 ((L'.EStrcat (ts, 1917 ((L'.EStrcat (ts,
1918 (L'.EPrim (Prim.String (" name=\"" ^ name ^ "\"/>")), 1918 (L'.EPrim (Prim.String (" name=\"" ^ name ^ "\"/>")),
1919 loc)), loc), fm) 1919 loc)), loc), fm)
1920 end 1920 end
1921 | SOME (_, src, _) => 1921 | SOME (_, src, _) =>
1922 (strcat [str "<script type=\"text/javascript\">inp(\"input\",", 1922 (strcat [str "<script>inp(\"input\",",
1923 (L'.EJavaScript (L'.Script, src, NONE), loc), 1923 (L'.EJavaScript (L'.Script, src, NONE), loc),
1924 str ")</script>"], 1924 str ")</script>"],
1925 fm)) 1925 fm))
1926 | _ => (Print.prefaces "Targs" (map (fn t => ("T", CorePrint.p_con env t)) targs); 1926 | _ => (Print.prefaces "Targs" (map (fn t => ("T", CorePrint.p_con env t)) targs);
1927 raise Fail "No name passed to textbox tag")) 1927 raise Fail "No name passed to textbox tag"))