Code Monkey home page Code Monkey logo

Comments (3)

yanzhenjie avatar yanzhenjie commented on May 26, 2024

在onBindViewHolder中操作本来就是违规的,不能在适配器中操作,全部数据初始化完成后再打开。

from swiperecyclerview.

Leo199206 avatar Leo199206 commented on May 26, 2024

那如果有一个需求是点击某个按钮,然后打开列表所有的item删除按钮,这个就没有办法实现了对吗?我试过demo中的下拉刷新,加载更多的demo,如果调用 mSwipeMenuRecyclerView.smoothOpenRightMenu();这个句代码去打开全部的按钮,滑动时,按钮状态会出错。代码如下
···
@OverRide
public boolean onOptionsItemSelected(MenuItem item) {
if (item.getItemId() == android.R.id.home) {
finish();
} else if (item.getItemId() == R.id.menu_open_rv_menu) {
for (int i = 0; i < mMenuAdapter.getItemCount(); i++) {
mSwipeMenuRecyclerView.smoothOpenRightMenu(i);
}
}
return true;
}
···

from swiperecyclerview.

yanzhenjie avatar yanzhenjie commented on May 26, 2024

点击某个item按钮可以打开对应的菜单,不能打开全部的,只能同时打开一个菜单。

from swiperecyclerview.

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.