Skip to content

Add toggle between logo and full title on click in details screen#2760

Open
VyomVyas4765 wants to merge 3 commits intorecloudstream:masterfrom
VyomVyas4765:feature/toggle-title-logo
Open

Add toggle between logo and full title on click in details screen#2760
VyomVyas4765 wants to merge 3 commits intorecloudstream:masterfrom
VyomVyas4765:feature/toggle-title-logo

Conversation

@VyomVyas4765
Copy link
Copy Markdown

@VyomVyas4765 VyomVyas4765 commented May 4, 2026

Implements the feature for #2650 by adding a toggle on the logo to show the full title. Tapping the logo switches to the text title of the media and then tapping the title again brings the logo back. Nothing changes when there is no logo and the title itself is there. Tested and working as expected.

Screenshot_20260504-225722 Screenshot_20260504-225725

Copy link
Copy Markdown
Collaborator

@fire-light42 fire-light42 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great first commit, however do not add additional logic that conflicts with existing code. We already have a result_title textview, and a bindLogo function. Modify those instead of adding new code. Moreover, while your result_full_title_text might have nextFocus to navigate from, it can not be navigated to.

@VyomVyas4765
Copy link
Copy Markdown
Author

Thanks for the feedback! That makes sense, I’ll refactor it to use result_title and bindLogo, and also fix the navigation issue.

@VyomVyas4765 VyomVyas4765 requested a review from fire-light42 May 4, 2026 19:22
Copy link
Copy Markdown
Collaborator

@fire-light42 fire-light42 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good improvements, however there are some visual errors that make this feature look weird.

  1. The UI is bugged on TV, the focus looks really weird. It should be a clear outline, not a white background.
  2. The UI is not clickable on TV with touch in the results view.
  3. As both views fight over the same layout location, the "animation" makes the UI move a lot. It is not seamless and has an affect on the entire layout tree.
  4. It is not serialized, saved or is in any shape persistent. Normally this would be fine, but bindLogo may get run several times on the same view, and the view will get recreated when switching e.g. tabs or recommendations. This makes the UI feel forgetful, inconsistent and even buggy when using it on the main page on TV. A local session cache on the url would fix this.
  5. Using .isEnabled to store state will lead to inconsistent state, especially when using it in a recycleview.

titleView.isVisible = false
titleView.isClickable = true
titleView.isFocusable = true
titleView.isFocusableInTouchMode = true
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We normally do isFocusableInTouchMode = isLayout(TV) in CloudStream.

@VyomVyas4765
Copy link
Copy Markdown
Author

VyomVyas4765 commented May 6, 2026

The details you gave actually helped a bunch, appreciate it. I've reworked the logic to fix the layout judder by dropping the animations, and hooked it up to a LruCache so the toggle state persists across the RecyclerView. I also dropped the .isEnabled hack to prevent state bleeding and cleaned up the TV focus outlines. Let me know if this looks better

@VyomVyas4765 VyomVyas4765 requested a review from fire-light42 May 6, 2026 11:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants