diff --git a/Classes/CallConferenceTableView.h b/Classes/CallConferenceTableView.h index d7d8b201f..9034a155e 100644 --- a/Classes/CallConferenceTableView.h +++ b/Classes/CallConferenceTableView.h @@ -8,9 +8,8 @@ #import -@interface CallConferenceTableView : UITableViewController { - @private - NSTimer *updateTime; -} +@interface CallConferenceTableView : UITableViewController + +- (void)update; @end diff --git a/Classes/CallConferenceTableView.m b/Classes/CallConferenceTableView.m index 71bd14208..cfbffb279 100644 --- a/Classes/CallConferenceTableView.m +++ b/Classes/CallConferenceTableView.m @@ -24,22 +24,6 @@ @implementation CallConferenceTableView -#pragma mark - ViewController Functions - -- (void)viewWillAppear:(BOOL)animated { - [super viewWillAppear:animated]; - updateTime = - [NSTimer scheduledTimerWithTimeInterval:1 target:self selector:@selector(update) userInfo:nil repeats:YES]; -} - -- (void)viewWillDisappear:(BOOL)animated { - [super viewWillDisappear:animated]; - if (updateTime != nil) { - [updateTime invalidate]; - updateTime = nil; - } -} - #pragma mark - UI change - (void)update { diff --git a/Classes/CallPausedTableView.h b/Classes/CallPausedTableView.h index 7b64bc45e..0fe820402 100644 --- a/Classes/CallPausedTableView.h +++ b/Classes/CallPausedTableView.h @@ -19,9 +19,8 @@ #import -@interface CallPausedTableView : UITableViewController { - @private - NSTimer *updateTime; -} +@interface CallPausedTableView : UITableViewController + +- (void)update; @end diff --git a/Classes/CallPausedTableView.m b/Classes/CallPausedTableView.m index 5878d3588..8a3dc4256 100644 --- a/Classes/CallPausedTableView.m +++ b/Classes/CallPausedTableView.m @@ -24,22 +24,6 @@ @implementation CallPausedTableView -#pragma mark - ViewController Functions - -- (void)viewWillAppear:(BOOL)animated { - [super viewWillAppear:animated]; - updateTime = - [NSTimer scheduledTimerWithTimeInterval:1 target:self selector:@selector(update) userInfo:nil repeats:YES]; -} - -- (void)viewWillDisappear:(BOOL)animated { - [super viewWillDisappear:animated]; - if (updateTime != nil) { - [updateTime invalidate]; - updateTime = nil; - } -} - #pragma mark - UI change - (void)update { diff --git a/Classes/CallView.m b/Classes/CallView.m index b35307aae..e8aa0294a 100644 --- a/Classes/CallView.m +++ b/Classes/CallView.m @@ -415,6 +415,9 @@ static void hideSpinner(LinphoneCall *call, void *user_data) { int duration = linphone_core_get_current_call(LC) ? linphone_call_get_duration(linphone_core_get_current_call(LC)) : 0; _durationLabel.text = [LinphoneUtils durationToString:duration]; + + [_pausedCallsTable update]; + [_conferenceCallsTable update]; } - (void)onCurrentCallChange { @@ -513,8 +516,8 @@ static void hideSpinner(LinphoneCall *call, void *user_data) { } // Update tables - [_pausedCallsTable.tableView reloadData]; - [_conferenceCallsTable.tableView reloadData]; + [_pausedCallsTable update]; + [_conferenceCallsTable update]; static LinphoneCall *currentCall = NULL; if (!currentCall || linphone_core_get_current_call(LC) != currentCall) { diff --git a/linphone-Info.plist b/linphone-Info.plist index bd82a20e2..35d7d86c3 100644 --- a/linphone-Info.plist +++ b/linphone-Info.plist @@ -53,7 +53,7 @@ CFBundleVersion - 4 + 5 LSRequiresIPhoneOS UIApplicationExitsOnSuspend