All Projects → pirrip90 → CeilingLayout

pirrip90 / CeilingLayout

Licence: other
CeilingLayout用来控制子View的吸顶联滑,理论上支持实现了NestedScrollingChild的联滑控件,如NestedScrollView、RecyclerView、SmartRefreshLayout等;只需要在xml里配置需要吸顶子View的位置索引就能自动实现吸顶联滑效果。

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to CeilingLayout

Discretescrollview
A scrollable list of items that centers the current element and provides easy-to-use APIs for cool item animations.
Stars: ✭ 5,533 (+21180.77%)
Mutual labels:  recyclerview, android-ui
Easyadapter
Recyclerview adapter library- Create adapter in just 3 lines of code
Stars: ✭ 122 (+369.23%)
Mutual labels:  recyclerview, android-ui
Codeview Android
Display code with syntax highlighting ✨ in native way.
Stars: ✭ 748 (+2776.92%)
Mutual labels:  recyclerview, android-ui
Androidribbon
🎀 The simple way to implement a beautiful ribbon with the shimmering on Android.
Stars: ✭ 502 (+1830.77%)
Mutual labels:  recyclerview, android-ui
android-tableview-kotlin
Android's missing TableView component.
Stars: ✭ 40 (+53.85%)
Mutual labels:  recyclerview, android-ui
Android Zblibrary
🔥Android MVP 快速开发框架,做国内 「示例最全面」「注释最详细」「使用最简单」「代码最严谨」的 Android 开源 UI 框架。 🔥An Android MVP Framework with many demos, detailed documents, simple usages and strict codes.
Stars: ✭ 5,000 (+19130.77%)
Mutual labels:  recyclerview, smartrefreshlayout
Multilinedivider
Multi divider in RecyclerView on Android.
Stars: ✭ 13 (-50%)
Mutual labels:  recyclerview, android-ui
Stacklayoutmanager
customized layoutmanager,let item pile up like stackview/类似最美有物卡片堆叠效果
Stars: ✭ 343 (+1219.23%)
Mutual labels:  recyclerview, android-ui
Pageindicator
An Instagram like page indicator compatible with RecyclerView and ViewPager.
Stars: ✭ 236 (+807.69%)
Mutual labels:  recyclerview, android-ui
Notzz App
📝 A Simple Note-Taking App built to demonstrate the use of Modern Android development tools - (Kotlin, Coroutines, State Flow, Hilt-Dependency Injection, Jetpack DataStore, Architecture Components, MVVM, Room, Material Design Components).
Stars: ✭ 158 (+507.69%)
Mutual labels:  recyclerview, android-ui
recycler-adapter
RecyclerView-driven declarative UIs
Stars: ✭ 124 (+376.92%)
Mutual labels:  recyclerview, android-ui
Bouncy
RecyclerView and NestedScrollView with physics-based bouncy overscroll effect
Stars: ✭ 166 (+538.46%)
Mutual labels:  recyclerview, nestedscrollview
Scrollingpagerindicator
Pager indicator inspired by Instagram. Lightweight and easy to set up.
Stars: ✭ 419 (+1511.54%)
Mutual labels:  recyclerview, android-ui
Zoomrecylerlayout
🎢 Zoom Recycler Layout Manager For Android Kotlin
Stars: ✭ 618 (+2276.92%)
Mutual labels:  recyclerview, android-ui
Recyclerstickyheaderview
Sticky header view or suspending view for RecyclerView.
Stars: ✭ 347 (+1234.62%)
Mutual labels:  recyclerview, android-ui
Androidveil
🎭 An easy, flexible way to implement veil skeletons and shimmering effect for Android.
Stars: ✭ 792 (+2946.15%)
Mutual labels:  recyclerview, android-ui
Tableview
TableView is a powerful Android library for displaying complex data structures and rendering tabular data composed of rows, columns and cells.
Stars: ✭ 2,928 (+11161.54%)
Mutual labels:  recyclerview, android-ui
Fastadapter
The bullet proof, fast and easy to use adapter library, which minimizes developing time to a fraction...
Stars: ✭ 3,512 (+13407.69%)
Mutual labels:  recyclerview, android-ui
Carouselrecyclerview
Carousel Recyclerview let's you create carousel layout with the power of recyclerview by creating custom layout manager.
Stars: ✭ 107 (+311.54%)
Mutual labels:  recyclerview, android-ui
recyclerfragment
An Android Fragment that displays a set of items in a RecyclerView.
Stars: ✭ 16 (-38.46%)
Mutual labels:  recyclerview, android-ui

1、描述

CeilingLayout用来控制子View的吸顶联滑,理论上支持实现了NestedScrollingChild的联滑控件,如NestedScrollViewRecyclerViewSmartRefreshLayout等;只需要在xml里配置需要吸顶子View的位置索引就能自动实现吸顶联滑效果。

2、模型图

CeilingLayoutLinearLayout的子类,使用方法与竖向LinearLayout一致。

如模型图所示,CeilingLayout竖向排列子View时,吸顶子View之后有且只能再排列一个子View,一般为联动View或包裹住联动View的父容器。

3、xml属性

方法名 参数 描述
ceiling_childIndex integer 吸顶子View的位置索引

4、使用

  • xml配置
    <!-- 设置位置索引为1的子View吸顶 -->
    <com.github.xubo.statuslayout.CeilingLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        app:ceiling_childIndex="1">
        
        <View
            android:layout_width="match_parent"
            android:layout_height="100dp"/>
                    
        <TextView
            android:layout_width="match_parent"
            android:layout_height="100dp"
            android:text="我是吸顶View"/>
        
        <android.support.v7.widget.RecyclerView
            android:layout_width="match_parent"
            android:layout_height="match_parent"/>
            
    </com.github.xubo.statuslayout.StatusLayout>

5、gradle

add the dependency:

dependencies {
    ...
    
    implementation 'com.github.xubo.ceilinglayout:CeilingLayout:1.1.1'
}

6、sample

示例

7、注意事项

1)、已验证联动View表

  • NestedScrollView
  • RecyclerView
  • SmartRefreshLayout

2)、SmartRefreshLayout-1.1.0已不支持联动

由于SmartRefreshLayout1.1.0注释了NestedScrollingChild接口实现,表明无法支持与Parent View的嵌套滑动,所以CeilingLayout目前无法支持SmartRefreshLayout-1.1.0联动。 如果需要与SmartRefreshLayout联动,建议把SmartRefreshLayout降级到1.0.5

3)、错误的位置索引配置

  • 不存在的子View位置索引
  • 位置索引为0,索引为0吸顶毫无意义
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].