Tencent-RTC / Tencent-RTC/TUICallKit
[iOS] Call duration timer pauses after app enters background
Nobody has claimed this yet.
- Dominant language
- Swift
- Stars
- 249
- Forks
- 170
- PR merge metrics
- No merged PRs in 30d
Description
Environment
- Plugin:
tencent_calls_uikit - Current version:
4.1.1 - Also reproduced in:
atomic_x_core 4.1.0 - iOS device: [please fill in, e.g. iPhone 15 Pro]
- iOS version: [please fill in]
- Flutter version: [please fill in]
- Dart version: [please fill in]
Description
The call duration displayed in the built-in TUICallKit UI stops updating after the app enters the background on iOS.
The call itself remains active and the audio/video connection continues normally. However, after returning to the foreground, the duration remains at the value shown before entering the background and does not include the time spent in the background.
Steps to Reproduce
- Start or accept a one-to-one audio/video call.
- Wait until the call duration timer is visible.
- Put the app into the background by pressing the Home button or locking the device.
- Keep the call active for a while.
- Return to the app.
Actual Behavior
The call duration timer pauses when the app enters the background and does not reflect the elapsed background time after returning to the foreground.
Expected Behavior
The call duration should continue based on the actual call start time, including the time while the app is in the background.
Technical Details
The issue appears to be related to the duration implementation in atomic_x_core, which currently increments the duration using a Dart periodic timer:
Timer.periodic(const Duration(seconds: 1), (timer) {
_duration += 1;
});
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the duration implementation in atomic_x_core and inspect the Dart Timer.periodic logic described in the issue. Verify the timer's behavior when the app backgrounds, then confirm that the displayed duration includes time since the call started after returning to the foreground.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- dart, flutter, ios
- Domain
- mobile
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 58/100