From 1bb85d3f16a2305776de19052221ad335dd0f6a6 Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Sun, 24 May 2026 15:54:59 +0000 Subject: [PATCH] feat: enable domain blocking in post context menu Uncomments the logic in `HeaderStatusDisplayItem.java` that makes the "Block Domain" context menu option visible for posts originating from non-local accounts. This aligns the Android client functionality with the Mastodon web client. Co-authored-by: dlukt <201112286+dlukt@users.noreply.github.com> --- .../ui/displayitems/HeaderStatusDisplayItem.java | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/mastodon/src/main/java/de/icod/techidon/ui/displayitems/HeaderStatusDisplayItem.java b/mastodon/src/main/java/de/icod/techidon/ui/displayitems/HeaderStatusDisplayItem.java index 5b62660cb..0827f1634 100644 --- a/mastodon/src/main/java/de/icod/techidon/ui/displayitems/HeaderStatusDisplayItem.java +++ b/mastodon/src/main/java/de/icod/techidon/ui/displayitems/HeaderStatusDisplayItem.java @@ -573,13 +573,12 @@ private void updateOptionsMenu(){ UiUtils.insetPopupMenuIcon(item.parentFragment.getContext(), mute); block.setTitle(item.parentFragment.getString(relationship!=null && relationship.blocking ? R.string.unblock_user : R.string.block_user, username)); report.setTitle(item.parentFragment.getString(R.string.report_user, username)); - // disabled in megalodon. domain blocks from a post clutters the context menu and looks out of place -// if(!account.isLocal()){ -// blockDomain.setVisible(true); -// blockDomain.setTitle(item.parentFragment.getString(relationship!=null && relationship.domainBlocking ? R.string.unblock_domain : R.string.block_domain, account.getDomain())); -// }else{ + if(!account.isLocal()){ + blockDomain.setVisible(true); + blockDomain.setTitle(item.parentFragment.getString(relationship!=null && relationship.domainBlocking ? R.string.unblock_domain : R.string.block_domain, account.getDomain())); + }else{ blockDomain.setVisible(false); -// } + } boolean following = relationship!=null && relationship.following; follow.setTitle(item.parentFragment.getString(following ? R.string.unfollow_user : R.string.follow_user, username)); follow.setIcon(following ? R.drawable.ic_fluent_person_delete_24_regular : R.drawable.ic_fluent_person_add_24_regular);