Pārlūkot izejas kodu

Event API in class doc

Herbert Vojčík 8 gadi atpakaļ
vecāks
revīzija
fc73cfdec5
2 mainītis faili ar 8 papildinājumiem un 1 dzēšanām
  1. 0 0
      src/DOMite.js
  2. 8 1
      src/DOMite.st

Failā izmaiņas netiks attēlotas, jo tās ir par lielu
+ 0 - 0
src/DOMite.js


+ 8 - 1
src/DOMite.st

@@ -54,7 +54,14 @@ It is not presumed one would use `setToXxx`
 to actually move around in a single instance.
 It is envisioned this API will be used mostly
 in combination with `copy`, like
-`afterMe := self copy setToAfter`.!
+`afterMe := self copy setToAfter`.
+
+Event API:
+
+ - `aDomite on: aString bind: [ :ev | ... ]` binds a block to process an event.
+ - `aDomite off: aString unbind: aBlock` unbinds the block from processing an event.
+ - `aDomite fire: aString [detail: anObject]` triggers a CustomEvent with specified type and, optionally, a detail object.
+ - `aDomite fireEvent: anEvent` triggers existing DOM Event object!
 
 !Domite methodsFor: 'accessing'!
 

Daži faili netika attēloti, jo izmaiņu fails ir pārāk liels