Anki-Android icon indicating copy to clipboard operation
Anki-Android copied to clipboard

[Bug] The sync button badge doesn't light up when adjusting the number of today's study cards in custom study.

Open mikunimaru opened this issue 3 years ago • 10 comments

Reproduction Steps
  1. Press and hold the deck to select custom study
  2. Modify today's card limit.
Expected Result

A red badge appears on the sync button

Actual Result

A red badge does not appear on the sync button

Debug info

AnkiDroid Version = 2.16alpha34

Android Version = 10

Manufacturer = asus

Model = ASUS_I01WD

Hardware = qcom

Webview User Agent = Mozilla/5.0 (Linux; Android 10; ASUS_I01WD Build/QP1A.190711.005; wv) AppleWebKit/537.36 (KHTML, like Gecko) Version/4.0 Chrome/96.0.4664.92 Mobile Safari/537.36

ACRA UUID = f40502af-2f2d-46a1-89bc-6b86d7fa6380

Scheduler = std2

Crash Reports Enabled = false

DatabaseV2 Enabled = true

Research

Enter an [x] character to confirm the points below:

  • [x] I have read the support page and am reporting a bug or enhancement request specific to AnkiDroid
  • [x] I have checked the manual and the FAQ and could not find a solution to my issue
  • [x] I have searched for similar existing issues here and on the user forum
  • [x] (Optional) I have confirmed the issue is not resolved in the latest alpha release (instructions)

mikunimaru avatar Dec 13 '21 07:12 mikunimaru

Hello 👋, this issue has been opened for more than 2 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically

github-actions[bot] avatar Feb 11 '22 07:02 github-actions[bot]

Hi, I would like to work on this issue. Could I have this one? @david-allison

RaidenCHEN avatar Mar 10 '22 10:03 RaidenCHEN

Hi, I would like to work on this issue. Could I have this one? @david-allison

Sounds good to me!

david-allison avatar Mar 10 '22 11:03 david-allison

@david-allison @mikehardy Hi! Right now, i have added the trans of syncstatus when choosing to modify "today's new card limit" or "today's review card limit". But the problem is, other options in Custom Study would trigger a page transform, which will cause a redraw of main menu calling the onCreateOptionsMenu(menu: Menu) function. The redrawing process performs like refresh, and thus the change of badge would appears. However, since Modify today's new/review card limit just simply exit the dialog when pressing OK button, which not involving the onCreateOptionsMenu function and thus, i need to enter one deck and get out to let the badge lit. I would like to know if there is any function that i may use for the refresh/redrawing of the menu? (onCreateOptionsMenu needs an input of Menu kind which i do not really know where to get.)

RaidenCHEN avatar Apr 24 '22 18:04 RaidenCHEN

supportInvalidateOptionsMenu?

It's recently got a deprecation, feel free to @Suppress("deprecation") // supportInvalidateOptionsMenu as we do in a few places to get it to compile

david-allison avatar Apr 24 '22 18:04 david-allison

Hello 👋, this issue has been opened for more than 2 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically

github-actions[bot] avatar Jun 24 '22 18:06 github-actions[bot]

Hi @david-allison , I want to work on this issue.

yshubham8419 avatar Jul 30 '22 10:07 yshubham8419

I think this is going to be a tough issue because of this - #11902 - no effort should be spent on the current implementation because of the new schema making it obsolete. That said if you want to take this up - for the new schema in general (11902 as well as this) that would be awesome

mikehardy avatar Jul 30 '22 23:07 mikehardy

#11902 should already be sorted for the new schema once the PR goes in: https://github.com/ankitects/Anki-Android/commit/7c5da5a3297f66f29dbd018b0e496c5c8c1053cd

dae avatar Jul 31 '22 03:07 dae

Thanks for the information, I will find another issue.

yshubham8419 avatar Jul 31 '22 07:07 yshubham8419

Hello 👋, this issue has been opened for more than 2 months with no activity on it. If the issue is still here, please keep in mind that we need community support and help to fix it! Just comment something like still searching for solutions and if you found one, please open a pull request! You have 7 days until this gets closed automatically

github-actions[bot] avatar Sep 29 '22 07:09 github-actions[bot]