GithubHelp home page GithubHelp logo

skdhruv / customtvrecyclerview Goto Github PK

View Code? Open in Web Editor NEW

This project forked from eliasdevlb/customtvrecyclerview

0.0 1.0 0.0 42 KB

Android TV Custom RecyclerView that has netflix-like navigation functionality.

Java 100.00%

customtvrecyclerview's Introduction

CustomTVRecyclerView

This recyclerView is optimized for TVs and D-Pad remotes. Make sure to add this library to your project first https://github.com/zhousuqiang/TvRecyclerView

Main features:

Additional Notes and explanations

  • In order to add netflix styled cards carousels, all you need to do is define an additional vertical recyclerView from the custom recyclerView class in your project and use the horiztonal_grid_item for singular items in rows.
  • In order to change the focus offset (currently set to the first item), you need to change app:tv_selectedItemOffsetEnd="656dp" and you can also change the calculations for dx and dy to find child rectangles in the CustomRecyclerView (The function name is requestChildRectangleOnScreen). This will also depend on your item's height, so make sure to change the offsets when you change the item sizes.
  • As a final note, the purpose of the PersistentFocusWrapper is to fix an android AOSP bug that makes the cursor lose focus when scrolling up and down in horizontal and vertical recyclerViews.

If you require more help, feel free to make an issue.

customtvrecyclerview's People

Contributors

eliasdevlb avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.