Merge pull request #2383 from jhavens1566/main

fix: unable to edit from preview mode
This commit is contained in:
Alper Öztürk 2024-10-08 14:23:09 +02:00 committed by GitHub
commit 0d79950ecf
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -89,8 +89,11 @@ public abstract class SearchableBaseNoteFragment extends BaseNoteFragment {
super.onViewCreated(view, savedInstanceState);
checkDirectEditingAvailable();
if (isDirectEditEnabled()) {
ExtendedFloatingActionButton edit = getNormalEditButton();
if (edit != null) edit.setVisibility(View.GONE);
final ExtendedFloatingActionButton directEditingButton = getDirectEditingButton();
directEditingButton.setExtended(false);
directEditingButton.setVisibility(View.VISIBLE);
ExtendedFabUtil.toggleExtendedOnLongClick(directEditingButton);
directEditingButton.setOnClickListener(v -> {
if (listener != null) {