Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

* Added the binding to go from a jQuery object to Array

  • Loading branch information...
commit 609f869d7a571fe5bb8b27beda44bc1ca514c45b 1 parent 25c2d13
Alessandro Vermeulen authored January 18, 2012
6  uhc-jscript/src/Language/UHC/JScript/JQuery/JQuery.hs
... ...
@@ -1,5 +1,6 @@
1 1
 module Language.UHC.JScript.JQuery.JQuery where
2 2
 
  3
+import Language.UHC.JScript.ECMA.Array (JSArray)
3 4
 import Language.UHC.JScript.ECMA.String
4 5
 import Language.UHC.JScript.Primitives
5 6
 import Language.UHC.JScript.Types
@@ -53,7 +54,10 @@ foreign import jscript "jQuery.when(%*)"
53 54
   when'' :: JSPtr a -> JSPtr a -> JSPtr a -> IO ()
54 55
 
55 56
 -------------------------------------------------------------------------------
56  
--- DOM
  57
+-- Iteration
  58
+
  59
+foreign import jscript "jQuery.makeArray(%1)"
  60
+  jQueryToArray :: JQuery -> IO (JSArray a)
57 61
 
58 62
 foreign import jscript "%1.each(%2)"
59 63
   each :: JQuery -> JSFunPtr (Int -> JSPtr a -> IO ()) -> IO ()

0 notes on commit 609f869

Please sign in to comment.
Something went wrong with that request. Please try again.