Skip to content

Commit

Permalink
Added 'willclose' event to window
Browse files Browse the repository at this point in the history
  • Loading branch information
Ani Sinanaj authored and kopiro committed Sep 5, 2018
1 parent 6164fa4 commit 849717c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions iphone/Classes/TiWindowProxy.m
Expand Up @@ -132,6 +132,9 @@ - (void)windowWillClose
if (tab == nil && (self.isManaged == NO)) {
[[[[TiApp app] controller] topContainerController] willCloseWindow:self];
}
if ([self _hasListeners:@"willclose"]) {
[self fireEvent:@"willclose" withObject:nil withSource:self propagate:NO reportSuccess:NO errorCode:0 message:nil];
}
[[NSNotificationCenter defaultCenter] removeObserver:self];
[super windowWillClose];
}
Expand Down

0 comments on commit 849717c

Please sign in to comment.