Commit 735eee2e authored by Gaëtan Renaudeau's avatar Gaëtan Renaudeau

Fixes #21

parent 3cca570a
...@@ -418,14 +418,11 @@ RCT_NOT_IMPLEMENTED(-init) ...@@ -418,14 +418,11 @@ RCT_NOT_IMPLEMENTED(-init)
- (void)dispatchOnLoad - (void)dispatchOnLoad
{ {
if (_onLoad) {
[_bridge.eventDispatcher sendInputEventWithName:@"load" body:@{ @"target": self.reactTag }]; [_bridge.eventDispatcher sendInputEventWithName:@"load" body:@{ @"target": self.reactTag }];
}
} }
- (void)dispatchOnProgress: (double)progress withLoaded:(int)loaded withTotal:(int)total - (void)dispatchOnProgress: (double)progress withLoaded:(int)loaded withTotal:(int)total
{ {
if (_onProgress) {
NSDictionary *event = NSDictionary *event =
@{ @{
@"target": self.reactTag, @"target": self.reactTag,
...@@ -433,7 +430,6 @@ RCT_NOT_IMPLEMENTED(-init) ...@@ -433,7 +430,6 @@ RCT_NOT_IMPLEMENTED(-init)
@"loaded": @(loaded), @"loaded": @(loaded),
@"total": @(total) }; @"total": @(total) };
[_bridge.eventDispatcher sendInputEventWithName:@"progress" body:event]; [_bridge.eventDispatcher sendInputEventWithName:@"progress" body:event];
}
} }
@end @end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment