Code Monkey home page Code Monkey logo

Comments (16)

asker517 avatar asker517 commented on July 30, 2024 4

建议在demo中添加一下java使用方式,现在还是用java写程序的比较多可能有些不会用放弃使用这个库

也会不会因为这个库让他们开始学习kotlin呢:D

from dsltablayout.

asker517 avatar asker517 commented on July 30, 2024 2

demo就是最好的文档... :D

from dsltablayout.

angcyo avatar angcyo commented on July 30, 2024 1

过于简单的强大,让你束手无策?

from dsltablayout.

yanlianhanlin avatar yanlianhanlin commented on July 30, 2024 1

建议在demo中添加一下java使用方式,现在还是用java写程序的比较多可能有些不会用放弃使用这个库

from dsltablayout.

lydlovezjr avatar lydlovezjr commented on July 30, 2024 1

建议在demo中添加一下java使用方式,现在还是用java写程序的比较多可能有些不会用放弃使用这个库

from dsltablayout.

angcyo avatar angcyo commented on July 30, 2024

需要补充什么文档? 提出来了, 我就会加.

from dsltablayout.

YumikoAzu avatar YumikoAzu commented on July 30, 2024

需要补充什么文档? 提出来了, 我就会加.

就是具体使用,直接看DEMO代码发现你还用了dsladapter的库,项目不想引入dsladapter。

from dsltablayout.

YumikoAzu avatar YumikoAzu commented on July 30, 2024

库是好库,只是这个文档看得我一脸懵逼,希望可以规范完善一下,可以省了很多接入的时间。

view_pager.adapter = object : FragmentStateAdapter(this) {
override fun getItemCount() = 3

        override fun createFragment(position: Int): Fragment {
            return when (position) {
                0 -> MyComicFragment()
                1 -> MyNovelFragment()
                else -> MyNewsFragment()
            }
        }
    }
    tab_layout.setupViewPager(ViewPager2Delegate(view_pager, tab_layout))

from dsltablayout.

angcyo avatar angcyo commented on July 30, 2024

Demo用了DslAdapter库, 是为了创建Demo使用, DslTabLayout库, 无任何第三方库的依赖, 包括ViewPagerViewPager2, 都没有依赖.

from dsltablayout.

longyuan5 avatar longyuan5 commented on July 30, 2024

文档写的太简单,太简单啥事也干不了,并不是越简单越好

from dsltablayout.

harryhasai avatar harryhasai commented on July 30, 2024

过于简单的强大,让你束手无策?

真的是过于简单强大,,, 我这边用的是java,, 没明白Item选中事件到底怎么做...

from dsltablayout.

angcyo avatar angcyo commented on July 30, 2024

过于简单的强大,让你束手无策?

真的是过于简单强大,,, 我这边用的是java,, 没明白Item选中事件到底怎么做...

点击事件, 就是文档中的选中回调.

https://github.com/angcyo/DslTabLayout/wiki/Item%E9%80%89%E4%B8%AD%E4%BA%8B%E4%BB%B6#%E5%A4%A7%E8%87%B4%E4%BD%BF%E7%94%A8%E4%BB%A3%E7%A0%81

from dsltablayout.

harryhasai avatar harryhasai commented on July 30, 2024

过于简单的强大,让你束手无策?

真的是过于简单强大,,, 我这边用的是java,, 没明白Item选中事件到底怎么做...

点击事件, 就是文档中的选中回调.

https://github.com/angcyo/DslTabLayout/wiki/Item%E9%80%89%E4%B8%AD%E4%BA%8B%E4%BB%B6#%E5%A4%A7%E8%87%B4%E4%BD%BF%E7%94%A8%E4%BB%A3%E7%A0%81

大佬! 文档我看了, 原谅我比较菜,, 没搞明白应该怎么调用 选中事件的回调

private void initViewPager() {
        MyViewPagerAdapter adapter = new MyViewPagerAdapter(this);
        adapter.addFragment(DoExercisesChildren1Fragment.getInstance());
        adapter.addFragment(DoExercisesChildren2Fragment.getInstance());
        adapter.addFragment(DoExercisesChildren3Fragment.getInstance());
        viewPager.setAdapter(adapter);
        ViewPager1Delegate.Companion.install(viewPager, tabLayout);
 }

image

还没有认真看kotlin , 所以这里应该怎么处理

from dsltablayout.

angcyo avatar angcyo commented on July 30, 2024

已更新了java设置监听的代码.

https://github.com/angcyo/DslTabLayout/wiki/Item%E9%80%89%E4%B8%AD%E4%BA%8B%E4%BB%B6

from dsltablayout.

Dboy233 avatar Dboy233 commented on July 30, 2024

文档的图片全看不了啊

from dsltablayout.

angcyo avatar angcyo commented on July 30, 2024

文档的图片全看不了啊

文档引用的是Gitee的图片链接, 可能无法在Github查看, 之前是可以的.

可以去 https://gitee.com/angcyo/DslTabLayout 查看文档.

from dsltablayout.

Related Issues (20)

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.