Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.mobile.android > #154287
| From | ram@zedat.fu-berlin.de (Stefan Ram) |
|---|---|
| Newsgroups | comp.mobile.android |
| Subject | Re: how to get button max position at recylcerView |
| Date | 2026-06-23 14:09 +0000 |
| Organization | Stefan Ram |
| Message-ID | <formatting-20260623150735@ram.dialup.fu-berlin.de> (permalink) |
| References | <111e026$1dukm$1@paganini.bofh.team> <button-20260623145712@ram.dialup.fu-berlin.de> |
ram@zedat.fu-berlin.de (Stefan Ram) wrote or quoted: >| Kotlin: >| >| val layoutManager = recyclerView.layoutManager as >| LinearLayoutManagerval maxPosition = >| layoutManager.findLastVisibleItemPosition() Sorry, the formatting of source text went wrong! The code parts were meant to read, | Kotlin: | val layoutManager = recyclerView.layoutManager as LinearLayoutManager | val maxPosition = layoutManager.findLastVisibleItemPosition() | Java: | LinearLayoutManager layoutManager = (LinearLayoutManager) recyclerView.getLayoutManager(); | int maxPosition = layoutManager.findLastVisibleItemPosition(); | Kotlin: | val location = IntArray(2) | myButton.getLocationOnScreen(location) | val x = location | val y = location . My formatting script actually is working fine. The Markdown I got from the chatbot already had joined source code lines into one line.
Back to comp.mobile.android | Previous | Next — Previous in thread | Find similar | Unroll thread
how to get button max position at recylcerView Jakub <jak74@interia.pl> - 2026-06-23 15:01 +0200
Re: how to get button max position at recylcerView ram@zedat.fu-berlin.de (Stefan Ram) - 2026-06-23 13:59 +0000
Re: how to get button max position at recylcerView ram@zedat.fu-berlin.de (Stefan Ram) - 2026-06-23 14:09 +0000
csiph-web