Comments (5)
我的解决方案是继承ArcDragMenu,重写事件的分发方法,在down按下事件直接让父容器不要拦截,把事件交由ArcDragMenu处理即可。具体解决滑动冲突,要根据实际情况,自己继承ArcDragMenu处理,我这里只是简单处理ViewPager嵌套了ArcDragMenu这种情况。哪位兄弟要是看到了,有更好的解决方案,欢迎发送邮件讨论,[email protected]
from arcmenu.
另外一个问题是每个子view的布局位置是比较窄的时候,要想滑动,手指必须点击的是子View。如果点击是子view之间的空白间隔,事件并没有消费到,导致无法滑动。我简单截图说明了一下。黑色箭头表示这个空白间隔,
from arcmenu.
我有另外一个想法就是改源码,但是太复杂,作罢,有谁可以试一下!
from arcmenu.
看了一下ViewGroup的测量子view宽高的方法,是包括padding的内边距的。简单的解决方案就是子view的布局添加padding,当然这是无法适配子view个数少于5个的情况,目前我的项目子view至少是5个以上,暂时这样解决,有更好的处理方案,欢迎邮件讨论,[email protected]
from arcmenu.
修改了一下,你再看下是否还有问题
from arcmenu.
Related Issues (5)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from arcmenu.