OLD | NEW |
(Empty) | |
| 1 |
| 2 class _IDBTransactionImpl extends _DOMTypeBase implements IDBTransaction { |
| 3 _IDBTransactionImpl._wrap(ptr) : super._wrap(ptr); |
| 4 |
| 5 IDBDatabase get db() => _wrap(_ptr.db); |
| 6 |
| 7 int get mode() => _wrap(_ptr.mode); |
| 8 |
| 9 EventListener get onabort() => _wrap(_ptr.onabort); |
| 10 |
| 11 void set onabort(EventListener value) { _ptr.onabort = _unwrap(value); } |
| 12 |
| 13 EventListener get oncomplete() => _wrap(_ptr.oncomplete); |
| 14 |
| 15 void set oncomplete(EventListener value) { _ptr.oncomplete = _unwrap(value); } |
| 16 |
| 17 EventListener get onerror() => _wrap(_ptr.onerror); |
| 18 |
| 19 void set onerror(EventListener value) { _ptr.onerror = _unwrap(value); } |
| 20 |
| 21 void abort() { |
| 22 _ptr.abort(); |
| 23 return; |
| 24 } |
| 25 |
| 26 void addEventListener(String type, EventListener listener, [bool useCapture =
null]) { |
| 27 if (useCapture === null) { |
| 28 _ptr.addEventListener(_unwrap(type), _unwrap(listener)); |
| 29 return; |
| 30 } else { |
| 31 _ptr.addEventListener(_unwrap(type), _unwrap(listener), _unwrap(useCapture
)); |
| 32 return; |
| 33 } |
| 34 } |
| 35 |
| 36 bool dispatchEvent(Event evt) { |
| 37 return _wrap(_ptr.dispatchEvent(_unwrap(evt))); |
| 38 } |
| 39 |
| 40 IDBObjectStore objectStore(String name) { |
| 41 return _wrap(_ptr.objectStore(_unwrap(name))); |
| 42 } |
| 43 |
| 44 void removeEventListener(String type, EventListener listener, [bool useCapture
= null]) { |
| 45 if (useCapture === null) { |
| 46 _ptr.removeEventListener(_unwrap(type), _unwrap(listener)); |
| 47 return; |
| 48 } else { |
| 49 _ptr.removeEventListener(_unwrap(type), _unwrap(listener), _unwrap(useCapt
ure)); |
| 50 return; |
| 51 } |
| 52 } |
| 53 } |
OLD | NEW |