Updated AppState module to use new emitter system

Summary: AppState now subclasses NativeEventEmitter instead of using global RCTDeviceEventEmitter.

Reviewed By: javache

Differential Revision: D3310488

fbshipit-source-id: f0116599223f4411307385c0dab683659d8d63b6
This commit is contained in:
Nick Lockwood
2016-05-23 09:08:51 -07:00
committed by Facebook Github Bot 3
parent c87b737ca1
commit d9737571c4
20 changed files with 187 additions and 264 deletions

View File

@@ -66,9 +66,13 @@ typedef void (^ControlBlock)(RCTRootView*);
- (void)rootViewDidChangeIntrinsicSize:(RCTRootView *)rootView
{
#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wdeprecated-declarations"
[rootView.bridge.eventDispatcher sendAppEventWithName:@"rootViewDidChangeIntrinsicSize"
body:@{@"width": @(rootView.intrinsicSize.width),
@"height": @(rootView.intrinsicSize.height)}];
#pragma clang diagnostic pop
}
@end