Handles the issue of adhan audio cutting off in the middle for Fajr prayer
This solve issue: #1100
Description
This PR addresses the issue where the adhan audio was cutting off in the middle during the Fajr prayer. It introduces the following changes:
In AdhanSubScreen.dart, a flag isFajrPray is added to check if the current salah index is 0 (Fajr prayer). The getAdhanDuration function is called with this flag to determine the appropriate duration.
In salah_workflow.dart, the isFajrPray flag is also used when calling getAdhanDuration to calculate the adhanEndTime.
In audio_mixin.dart, the getAdhanDuration function is modified to handle the Fajr prayer case. If the isFajrPray flag is true and the adhanName is not null, the '-fajr' suffix is appended to the adhanName.
Tests
π§ͺ Use case 1
π¬ Description: Test the Fajr prayer adhan playback to ensure the audio does not cut off in the middle.
π· Screenshots or GIFs (if applicable): [Provide any relevant screenshots or GIFs demonstrating the successful test case]
Checklist:
[x] Coding Standards: I have reviewed my code to ensure it follows the project's coding standards.
[x] Testing: I have tested the changes and they work as expected.
[x] Merge Conflicts: I have resolved any merge conflicts with the latest main/development branch.
[x] Branch Status: The branch is up-to-date with the target branch (main/development).
π Summary
Handles the issue of adhan audio cutting off in the middle for Fajr prayer
This solve issue: #1100
Description
This PR addresses the issue where the adhan audio was cutting off in the middle during the Fajr prayer. It introduces the following changes:
In
AdhanSubScreen.dart
, a flagisFajrPray
is added to check if the current salah index is 0 (Fajr prayer). ThegetAdhanDuration
function is called with this flag to determine the appropriate duration.In
salah_workflow.dart
, theisFajrPray
flag is also used when callinggetAdhanDuration
to calculate theadhanEndTime
.In
audio_mixin.dart
, thegetAdhanDuration
function is modified to handle the Fajr prayer case. If theisFajrPray
flag is true and theadhanName
is not null, the '-fajr' suffix is appended to theadhanName
.Tests
π§ͺ Use case 1
π¬ Description: Test the Fajr prayer adhan playback to ensure the audio does not cut off in the middle.
π· Screenshots or GIFs (if applicable): [Provide any relevant screenshots or GIFs demonstrating the successful test case]
Checklist: