Skip to content

Fix URL sharing#668

Merged
ArnyminerZ merged 4 commits into
devfrom
nav3-migration/fix-url-sharing
Aug 28, 2025
Merged

Fix URL sharing#668
ArnyminerZ merged 4 commits into
devfrom
nav3-migration/fix-url-sharing

Conversation

@ArnyminerZ
Copy link
Copy Markdown
Member

Purpose

Right now, sharing URLs is broken on ICSx⁵ (lazy implementation). Also it looks like it's not the best thing in the world in the current ICSx⁵ release (#675).

Short description

Cleanup of the intent parsing logic.

Checklist

  • The PR has a proper title, description and label.
  • I have self-reviewed the PR.
  • I have added documentation to complex functions and functions that can be used by other modules.
  • I have added reasonable tests or consciously decided to not add tests.

Signed-off-by: Arnau Mora <arnyminerz@proton.me>
@ArnyminerZ ArnyminerZ self-assigned this Aug 27, 2025
@ArnyminerZ ArnyminerZ added the refactoring Quality improvement of existing functions label Aug 27, 2025
@ArnyminerZ ArnyminerZ requested a review from Copilot August 27, 2025 12:49
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR fixes URL sharing functionality by refactoring the intent parsing logic in the MainApp component. The implementation moves from lazy loading of URL data to eager parsing during navigation setup.

  • Replaces LaunchedEffect-based URL extraction with direct intent parsing in the navigation destination calculation
  • Adds URL parameter to the AddSubscription destination to pass parsed URL data
  • Consolidates intent handling by passing the entire Intent object instead of just extras

Reviewed Changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
MainActivity.kt Updates MainApp call to pass entire intent and adds debug println
MainApp.kt Refactors calculateInitialDestination to parse URLs from intent and removes LaunchedEffect
Destination.kt Adds url parameter to AddSubscription destination

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

Comment thread app/src/main/java/at/bitfire/icsdroid/MainActivity.kt Outdated
Comment thread app/src/main/java/at/bitfire/icsdroid/ui/nav/MainApp.kt Outdated
ArnyminerZ and others added 2 commits August 27, 2025 15:12
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@ArnyminerZ ArnyminerZ marked this pull request as ready for review August 27, 2025 13:13
@ArnyminerZ ArnyminerZ requested a review from sunkup August 27, 2025 13:13
Signed-off-by: Arnau Mora <arnyminerz@proton.me>
Copy link
Copy Markdown
Member

@sunkup sunkup left a comment

Choose a reason for hiding this comment

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

Nice ~ Feel free to merge

@ArnyminerZ ArnyminerZ merged commit 15b4808 into dev Aug 28, 2025
7 checks passed
@ArnyminerZ ArnyminerZ deleted the nav3-migration/fix-url-sharing branch August 28, 2025 17:33
@sunkup sunkup linked an issue Sep 1, 2025 that may be closed by this pull request
2 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

refactoring Quality improvement of existing functions

Projects

None yet

Development

Successfully merging this pull request may close these issues.

webcal subscription passes URL of first webcal collection to ICSx5

3 participants