Evan Czaplicki
502cfc0465
Handle values sent to incoming ports, still need to properly define Elm.input though
2014-01-05 13:47:01 +01:00
Evan Czaplicki
1eaa3043c8
define ports_out on the elm object
2014-01-04 16:16:50 +01:00
Evan Czaplicki
7e64531d2e
Switch from old FFI to new port interface for default output ports
...
Also add default handlers for stdout and stderr
2014-01-04 11:41:06 +01:00
Evan Czaplicki
71bb1c8bf9
Add basics of properly handling ports
2013-12-24 10:13:19 -08:00
Evan Czaplicki
bccfece2c1
Merge branch 'master' into dev
2013-11-19 22:34:08 -08:00
Evan Czaplicki
704da021b0
Fix "dropped" frames for text updates ( #224 , #339 ) using @timthelion's insights in #350
...
* Change the implementation of `notify` so that it does not have a
return value any more.
* Get rid of the only remaning use of the return value of `notify` in
the `every` function.
* Have a "lock" on each round to ensure that no library or runtime
calls `notify` synchronously, causing an update to happen half way
through another update, ultimately leading to a dropped frame.
2013-11-18 17:23:40 +01:00
Michael Sondergaard
db7e3f618f
Fix whitespace in Init.js
2013-10-31 14:47:31 +01:00
Evan Czaplicki
a29a1fd558
Fix mouse and touch tracking for embedded Elm programs, #291
2013-10-13 19:10:02 -04:00
Evan Czaplicki
b40f2958d4
New convention for storing module values, fixes bug
...
Before it was not possible to add values to anything except leafs of
the namespace structure.
2013-09-30 01:32:27 -07:00
Evan Czaplicki
dcbe2fc245
Change the format of module instantiation
...
Currently, it's only possible to create modules at the leafs of the
namespace structure. This CL lifts that restriction.
Get rid of "use strict" in many cases.
2013-09-30 00:44:31 -07:00
Evan Czaplicki
1a45cb5eca
Nicer API for embedding Elm programs
2013-08-29 17:38:37 -07:00
Evan Czaplicki
308c1af433
Fix hotswapping on static scenes
2013-08-09 17:44:18 -07:00
Evan Czaplicki
c37f30fb41
Make sure that screen resize is registered on initialization
2013-08-04 15:27:02 -07:00
Evan Czaplicki
330aa78bde
Give a hint about the developer console for runtime errors
2013-08-04 14:45:04 -07:00
Evan Czaplicki
c8d2734a0d
Report some runtime errors on screen
...
only if error occurs on initialization, not after first frame
2013-08-04 13:27:08 -07:00
evancz
b30482a38f
Get timers to detach themselves when a swap occurs.
2013-06-03 00:19:48 -07:00
evancz
90cf4218a8
Switch to a custom way of attaching event listeners that makes it easier to detach them if necessary.
2013-06-02 23:46:02 -07:00
evancz
3d5d60a47d
Get basic hot-swapping working.
2013-05-31 10:40:49 -07:00
evancz
cb154acc53
Bug fixes from the Init.js refactor that just happened.
2013-05-30 18:52:02 -07:00
evancz
6ddb826332
First draft addition of hot-swapping. Clean up Init.js a bit as well.
2013-05-30 18:41:43 -07:00
evancz
26420d2937
Actually build the module when using Elm.worker
2013-05-21 18:25:38 +02:00
evancz
d31acc5c9d
Minor bug fixes in RTS and libraries.
2013-05-21 10:03:51 +02:00
evancz
1be7f0413a
Switch to creating Elm nodes by ID.
2013-05-15 07:38:11 +02:00
evancz
6134ed581d
Merge branch 'dev' of https://github.com/evancz/Elm into dev
2013-05-14 19:28:58 +02:00
evancz
b96b240c47
Make rotations counter-clockwise, just like the unit circle. Now trig functions and rendering functions match each other.
2013-05-14 19:28:36 +02:00
Colin Curtin
acd2b61e00
Merge remote-tracking branch 'evan/dev' into lint
...
Conflicts:
runtime/Init.js
runtime/Render/Collage.js
2013-05-14 09:18:38 -07:00
evancz
7ce550901c
Move to initializing with three different functions: fullscreen, node, and worker.
...
Add code to ensure that mouse and touch positions are reported relative to the embedded Elm node.
Remove the elm_ prefix from the events for logging, redirects, and title changes. Should be silo'd by the `elm` and not escape into the global event namespace.
2013-05-14 16:29:06 +02:00
Colin Curtin
2b90d0eb9e
Whitespace, semicolons, lint etc. No functional changes.
2013-05-11 13:42:45 -07:00
evancz
95726b7baf
Start using requestAnimationFrame
2013-04-18 22:25:18 -07:00
evancz
1d2b3fcbe4
Add built in event listeners.
2013-04-10 02:00:58 -07:00
evancz
22890292b8
Correct resizing problems with static elements. Previously, no property updates occurred.
2013-04-07 17:57:57 -07:00
evancz
60e403ba82
Fix show
for ADTs and get parens in the right places.
...
Make `Elm.init(Elm.MyModule)` work nicer when it takes over the whole `document` and needs to resize with the window.
2013-04-06 16:48:20 -07:00
evancz
7d1b40a85f
Change send function to be curry-able.
2013-04-01 00:35:45 -07:00
evancz
131a2b6818
Get sprites working in collage. temporary fix for docs.json issue. Looks like git thinks we're in the past, so a bunch of changes that have already happened as well.
2013-03-21 02:29:23 -07:00
evancz
152ef51a98
Fix croppedImage
, show
for tuples, and init for resizing initial dom node.
2013-03-13 00:52:14 -07:00
evancz
55137ac66d
Move files around in runtime/
2013-03-12 11:06:47 -07:00
evancz
a1b890adc3
Lots of tiny fixes to get the RTS working!
2013-03-12 00:48:11 -07:00
evancz
29a2ec36bb
Move css into RTS. Simplifies Haskell API and compiler code.
2013-03-10 18:52:16 -07:00
evancz
a38d346427
Remove a stray 'p' from navigating around in emacs with a weak pinky :P
2013-03-10 15:59:33 -07:00
evancz
f49a509e7f
Add send and recv functions for each RTS instance.
2013-03-09 18:58:44 -08:00
evancz
505b1e32d6
Add the Init module which exports Elm.init, creating a self-contained RTS. It can be used as follows:
...
Elm.init( Elm.MyModule ) // which takes over the document
Elm.init( Elm.MyModule, arbitraryDiv ) // which embeds the program in 'arbitraryDiv'
These functions can be called multiple times on the same modules!
Also slightly modify the format of the Render module.
2013-03-09 18:39:09 -08:00