Skip to content

fix #406: Added the service for canceling the ringing sound#416

Open
wellorbetter wants to merge 1 commit intoFossifyOrg:mainfrom
wellorbetter:main
Open

fix #406: Added the service for canceling the ringing sound#416
wellorbetter wants to merge 1 commit intoFossifyOrg:mainfrom
wellorbetter:main

Conversation

@wellorbetter
Copy link

@wellorbetter wellorbetter commented Mar 23, 2026

Added the service for canceling the ringing sound & adapted onStartCommand for the service that cancels the ringing sound.

Type of change(s)

  • Bug fix
  • Feature / enhancement
  • Infrastructure / tooling (CI, build, deps, tests)
  • Documentation

What changed and why

  • Added part to stop ongoing service when clock is deleted.
  • Adapted onStartCommand to handle cases where the alarm has been deleted, causing getAlarmWithId to return null.

Tests performed

  • Tested stopping alarms after they were deleted.

Closes the following issue(s)

Checklist

  • I read the contribution guidelines.
  • I manually tested my changes on device/emulator (if applicable).
  • I updated the "Unreleased" section in CHANGELOG.md (if applicable).
  • I have self-reviewed my pull request (no typos, formatting errors, etc.).
  • I understand every change in this pull request.

… & Adapted onStartCommand for the service that cancels the ringing sound.
Copy link
Author

@wellorbetter wellorbetter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a service to stop the alarm when it is ringing, and also adapted the corresponding onStartCommand logic so that it can enter the stopActiveAlarm state. This is because after deleting this alarm, the applicationContext.dbHelper.getAlarmWithId would result in newAlarm being null.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Not possible to stop an alarm that was deleted

1 participant