about summary refs log tree commit diff stats
path: root/src/html/event.nim
Commit message (Collapse)AuthorAgeFilesLines
* dom: add onclick attribute supportbptato2024-04-141-16/+49
| | | | | + better align attribute-based event handler behavior with other browsers
* js: proper distinction between Opt/Optionbptato2024-03-241-5/+6
| | | | | | | | | | | | | | | | until now, this had very strange (and inconsistent) semantics: * err() was used for exception propagation, but also as a null value * Option accepted undefined as a none value, but not null * Opt and Option were used interchangeably (and mostly randomly) Now, Result is always used for error reporting, and err(nil) means JS_EXCEPTION. (Opt is a special case of Result where we don't care about the error type, and is not used in JS.) Option on the other hand means "nullable variation of normally non-nullable type", and translates to JS_NULL. In JS we mainly use it for turning strings nullable.
* js: merge some type modules into jstypesbptato2024-01-111-1/+1
| | | | They only had type definitions, no need to put them in separate modules.
* Use std/* imports everywherebptato2024-01-071-2/+2
|
* event: remove ctx from CustomEventbptato2023-12-031-13/+9
| | | | | Instead, make finalizers optionally pass their runtime for resource deallocation.
* buffer: add DOMContentLoaded, misc event improvementsbptato2023-11-271-3/+3
| | | | | | | * Add DOMContentLoaded * Re-use the same event object for all elements * Reshape if an event was fired * Reshape on setTimeout/setInterval fired
* move around more modulesbptato2023-09-141-1/+1
| | | | | | | | | | * ips -> io/ * loader related stuff -> loader/ * tempfile -> extern/ * buffer, forkserver -> server/ * lineedit, window -> display/ * cell -> types/ * opt -> types/
* event: use JSDictbptato2023-09-091-20/+18
|
* buffer: basic click event supportbptato2023-08-311-7/+15
| | | | | | | Mostly a proof of concept. Just bubble it unconditionally for now and never prevent default. Also, fix fromJSFunction by Dup'ing its closure JSValue.
* javascript: factor out fromJSbptato2023-08-291-0/+1
|
* refactor: Result[T, JSError] -> JSResult[T]bptato2023-08-281-2/+2
|
* javascript: refactorbptato2023-08-281-0/+2
| | | | | | | Split out parts of the JS module, because it was starting to confuse the compiler a little. (Peakmem is back at 750M. Interesting.)
* javascript: update Events, misc fixes & additionsbptato2023-08-201-1/+224
| | | | | | | | | | | | | | Events: just implement the interfaces, no events are triggered yet. JS changes: * add LegacyUnforgeable * make consts enumerable * fix crash in isInstanceOf * fix destructor warnings * refactor registerType As a result, peakmem is now 1G+ on 1.6.14. It stays ~750M on 2.0.0. Hmm. Well, better upgrade to 2.0.0 I guess.
* Event: add some properties, js: add defineConstsbptato2023-07-041-2/+17
|
* Fix compilation failurebptato2023-07-031-1/+2
|
* Add XHR/Event stubsbptato2023-07-021-0/+15
18:31:12 -0800 committer Kartik Agaram <vc@akkartik.com> 2020-01-16 18:31:12 -0800 5897 - rename comparison instructions' href='/akkartik/mu/commit/050_write.subx?h=main&id=6070c23e5e1c60d3bb169e43bddfa59b1d322427'>6070c23e ^
cf02c20b ^
ee9a9237 ^
33352536 ^



7a583220 ^
33352536 ^

6030d7e2 ^
4224ec81 ^
e59a74ab ^


33352536 ^

e59a74ab ^


ee9a9237 ^
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57