Skip to content

Commit

Permalink
rename ViewerAction.EDIT_NOTE
Browse files Browse the repository at this point in the history
to EDIT

this allows to share the same preference key of `ViewerCommand`, since the name is the same now

This change will reset its position in the toolbar, but it doesn't need a preference upgrade because the new reviewer is a developer option
  • Loading branch information
BrayanDSO committed Dec 25, 2024
1 parent 2a909fe commit 9028535
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ enum class ViewerAction(
REDO(R.id.action_redo, R.drawable.ic_redo, R.string.redo, MENU_ONLY),
FLAG_MENU(R.id.action_flag, R.drawable.ic_flag_transparent, R.string.menu_flag, MENU_ONLY),
MARK(R.id.action_mark, R.drawable.ic_star, R.string.menu_mark_note, MENU_ONLY),
EDIT_NOTE(R.id.action_edit_note, R.drawable.ic_mode_edit_white, R.string.cardeditor_title_edit_card, MENU_ONLY),
EDIT(R.id.action_edit_note, R.drawable.ic_mode_edit_white, R.string.cardeditor_title_edit_card, MENU_ONLY),
BURY_MENU(R.id.action_bury, R.drawable.ic_flip_to_back_white, R.string.menu_bury, MENU_ONLY),
SUSPEND_MENU(R.id.action_suspend, R.drawable.ic_suspend, R.string.menu_suspend, MENU_ONLY),
DELETE(R.id.action_delete, R.drawable.ic_delete_white, R.string.menu_delete_note, MENU_ONLY),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ import com.ichi2.anki.preferences.reviewer.ViewerAction.BURY_NOTE
import com.ichi2.anki.preferences.reviewer.ViewerAction.CARD_INFO
import com.ichi2.anki.preferences.reviewer.ViewerAction.DECK_OPTIONS
import com.ichi2.anki.preferences.reviewer.ViewerAction.DELETE
import com.ichi2.anki.preferences.reviewer.ViewerAction.EDIT_NOTE
import com.ichi2.anki.preferences.reviewer.ViewerAction.EDIT
import com.ichi2.anki.preferences.reviewer.ViewerAction.FLAG_BLUE
import com.ichi2.anki.preferences.reviewer.ViewerAction.FLAG_GREEN
import com.ichi2.anki.preferences.reviewer.ViewerAction.FLAG_MENU
Expand Down Expand Up @@ -175,7 +175,7 @@ class ReviewerFragment :
ADD_NOTE -> launchAddNote()
CARD_INFO -> launchCardInfo()
DECK_OPTIONS -> launchDeckOptions()
EDIT_NOTE -> launchEditNote()
EDIT -> launchEditNote()
DELETE -> viewModel.deleteNote()
MARK -> viewModel.toggleMark()
REDO -> viewModel.redo()
Expand Down

0 comments on commit 9028535

Please sign in to comment.