Skip to content

[stable-34.0.x] fix: show "Loading note…" in single-note widget on boot instead of "Note not found"#3261

Open
backportbot[bot] wants to merge 1 commit into
stable-34.0.xfrom
backport/3198/stable-34.0.x
Open

[stable-34.0.x] fix: show "Loading note…" in single-note widget on boot instead of "Note not found"#3261
backportbot[bot] wants to merge 1 commit into
stable-34.0.xfrom
backport/3198/stable-34.0.x

Conversation

@backportbot

@backportbot backportbot Bot commented Jul 8, 2026

Copy link
Copy Markdown

Backport of PR #3198

Three distinct states are now handled correctly:

- Startup / system update: the widget shows "Loading note…" while the
  RemoteViewsAdapter connects. updateAppWidget() sets the placeholder
  visible with that text on every full reset (ACTION_APPWIDGET_UPDATE).

- Note refresh (edit or sync): updateSingleNoteWidgets() now sends a
  custom ACTION_DATA_CHANGED instead of ACTION_APPWIDGET_UPDATE. onReceive()
  handles this with notifyAppWidgetViewDataChanged() only, leaving the
  existing RemoteViews intact so the note content updates in place with
  no blank gap or flash.

- Note missing: once onDataSetChanged() confirms getNoteById() returns null,
  partiallyUpdateAppWidget() sets the placeholder visible with "Note not found".
  When the note is found the placeholder is hidden via the same mechanism.

Fixes #1611

AI-assisted: Claude Code (Sonnet 4.6)
Signed-off-by: Jan C. Borchardt <925062+jancborchardt@users.noreply.github.com>
@backportbot backportbot Bot added bug design Design and UX/UI issues 3. to review papercut Annoying recurring UX issue with possibly simple fix. labels Jul 8, 2026
@backportbot backportbot Bot added this to the 34.0.1 milestone Jul 8, 2026
@codacy-production

Copy link
Copy Markdown

Not up to standards ⛔

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@github-actions

github-actions Bot commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

APK file: https://github.com/nextcloud/notes-android/actions/runs/28926710652/artifacts/8161804925
To test this change/fix you can simply download above APK file and install and test it in parallel to your existing Nextcloud app.
qrcode (please click on link to get QR code displayed)

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

Labels

3. to review bug design Design and UX/UI issues papercut Annoying recurring UX issue with possibly simple fix.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants