Giter Site home page Giter Site logo

手指开始右滑的时候,给一个imageview.setImageResource更换图片然后再取消右滑,整个页面所有第一次view.setvisible(VISIBLE)操作view将显示不出来 about smartswipe HOT 6 OPEN

LvBing1995 avatar LvBing1995 commented on June 12, 2024
手指开始右滑的时候,给一个imageview.setImageResource更换图片然后再取消右滑,整个页面所有第一次view.setvisible(VISIBLE)操作view将显示不出来

from smartswipe.

Comments (6)

SimFG avatar SimFG commented on June 12, 2024

这个你有demo工程吗,看着这个有点抽象

from smartswipe.

wapalxj avatar wapalxj commented on June 12, 2024

我也遇到了,只要是滑动的时候,手指不放开,取消滑动,就会出现view不显示的情况
SmartSwipe.wrap(this)
.addConsumer(SlidingConsumer()
.setDrawerExpandable(true) //horizontal menu
.setHorizontalDrawerView(horizontalMenuWrapper)
//遮罩颜色
.setScrimColor(ResUtils.getColor(R.color.color_40_000000))
.setEdgeSize(100)
.as(SlidingConsumer::class.java))
场景:主页面为viewpager,SlidingConsumer在最上层,手指右滑不放开,滑到一半再左滑隐藏,然后viewpager切换之后,tab里面的view不会显示了

from smartswipe.

SimFG avatar SimFG commented on June 12, 2024

试试把SmartSwipeWrapper中wrapperNestedScroll方法将mHelp置为空的那一部分代码删除试试

mHelper.nestedScrollingDrag(dxUnconsumed, dyUnconsumed, consumed, false);
// 删除这个mHelper清空的试试
if (consumer.getProgress() >= maxProgress || consumer.getProgress() <= 0) {
    mHelper = null;
}

from smartswipe.

LvBing1995 avatar LvBing1995 commented on June 12, 2024

https://github.com/LvBing1995/TestPlayer.git 我用textureview侧滑取消有时候会出现setvisible无效问题,surfaceview也试了试没复现

from smartswipe.

wapalxj avatar wapalxj commented on June 12, 2024

试试把SmartSwipeWrapper中wrapperNestedScroll方法将mHelp置为空的那一部分代码删除试试

mHelper.nestedScrollingDrag(dxUnconsumed, dyUnconsumed, consumed, false);
// 删除这个mHelper清空的试试
if (consumer.getProgress() >= maxProgress || consumer.getProgress() <= 0) {
    mHelper = null;
}

没有用

from smartswipe.

SimFG avatar SimFG commented on June 12, 2024

找到的原因是:View中的requestLayout方法失效了,调用mParent.isLayoutRequested()这个条件一直为true了,看了下好像是PointsSeekBar这个类下中onDraw方法中addThumbAndPointViews这个调用,把这个删除我就没有复现了。没有找到为什么这个状态没有恢复。

from smartswipe.

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.