{"id":13638990,"url":"https://github.com/sergejsha/pinned-section-listview","last_synced_at":"2025-12-16T16:45:17.194Z","repository":{"id":8426141,"uuid":"10013861","full_name":"sergejsha/pinned-section-listview","owner":"sergejsha","description":"Easy to use ListView with pinned sections for Android.","archived":true,"fork":false,"pushed_at":"2020-02-23T15:16:35.000Z","size":825,"stargazers_count":2597,"open_issues_count":27,"forks_count":811,"subscribers_count":171,"default_branch":"master","last_synced_at":"2024-05-22T06:10:13.689Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sergejsha.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-05-12T13:22:19.000Z","updated_at":"2024-05-15T15:22:00.000Z","dependencies_parsed_at":"2022-09-26T22:01:26.325Z","dependency_job_id":null,"html_url":"https://github.com/sergejsha/pinned-section-listview","commit_stats":null,"previous_names":["beworker/pinned-section-listview"],"tags_count":6,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sergejsha%2Fpinned-section-listview","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sergejsha%2Fpinned-section-listview/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sergejsha%2Fpinned-section-listview/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sergejsha%2Fpinned-section-listview/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sergejsha","download_url":"https://codeload.github.com/sergejsha/pinned-section-listview/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":234410351,"owners_count":18828187,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-02T01:00:56.417Z","updated_at":"2025-09-27T07:32:08.418Z","avatar_url":"https://github.com/sergejsha.png","language":"Java","funding_links":[],"categories":["ListView"],"sub_categories":[],"readme":"Easy to use ListView with pinned sections for Android 2.1 and higher. Pinned section is a header view which sticks to the top\nof the list until at least one item of that section is visible.\n\n![Screenshot 1](web/screen1.png)\u0026nbsp;\n![Screenshot 2](web/screen2.png)\u0026nbsp;\n![Screenshot 3](web/screen3.png)\n\n# Features\n\nThis list properly implements many features which are missing from other implementations. These are\n * Fast scroll\n * Headers and footers\n * Clickable pinned sections\n\nBesides this it doesn't create any unnecessary views, layouts etc. It's really lean.\n\nWatch [this video][1] to see `PinnedSectionListView` in action.\n\n# Usage example\n\n 1. Replace standard `ListView` with `de.halfbit.pinnedsection.PinnedSectionListView` in your `layout.xml` file.\n\n```xml\n  \u003cde.halfbit.pinnedsection.PinnedSectionListView\n      android:id=\"@android:id/list\"\n      android:layout_width=\"match_parent\"\n      android:layout_height=\"wrap_content\" \n      /\u003e\n```\n        \n 2. Extend your `ListAdapter` in a way that it implements `PinnedSectionListAdapter` interface, in addition to\n    what it already implements. Basically you need to add a single `isItemViewTypePinned(int viewType)` \n    method. This method must return `true` for all view types which have to be pinned.\n\n```java\n  // Our adapter class implements 'PinnedSectionListAdapter' interface\n  class MyPinnedSectionListAdapter extends BaseAdapter \n          implements PinnedSectionListAdapter {\n  \n      ...\n    \n      // We implement this method to return 'true' for all view types we want to pin\n      @Override\n      public boolean isItemViewTypePinned(int viewType) {\n          return viewType == \u003ctype to be pinned\u003e;\n      }\n  }\n```\n\nThat's all. You are done! A working example can also be found in `example` folder. \n\n# Use with Gradle\n\nAdd this to your module-level `build.gradle`:\n\n```groovy\ndependencies {\n    compile \"de.halfbit:pinned-section-listview:1.0.0\"\n}\n```\n\nUsed by\n=======\nLet us know if you use this library in your application and we will mention it here.\n\n[Grocery Sum][2]\n\n[Slack][3]\n\nLicense\n=======\n\n    Copyright 2013-2016 Sergej Shafarenka, halfbit.de\n\n    Licensed under the Apache License, Version 2.0 (the \"License\");\n    you may not use this file except in compliance with the License.\n    You may obtain a copy of the License at\n\n       http://www.apache.org/licenses/LICENSE-2.0\n\n    Unless required by applicable law or agreed to in writing, software\n    distributed under the License is distributed on an \"AS IS\" BASIS,\n    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n    See the License for the specific language governing permissions and\n    limitations under the License.\n\n\n[1]: http://www.youtube.com/watch?v=mI3DpuoIIhQ\n[2]: https://play.google.com/store/apps/details?id=org.codechimp.grocerysum\n[3]: https://play.google.com/store/apps/details?id=com.Slack\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsergejsha%2Fpinned-section-listview","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsergejsha%2Fpinned-section-listview","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsergejsha%2Fpinned-section-listview/lists"}