Comments (5)
Thanks for the feedback. I too use the widget in a scrollable layout, but don't
experience this problem. Only if I get too far away from the slider handle when
dragging, the motion event gets routed to the scrollable container (which in my
opinion is the correct behaviour).
Could you be more specific about your setting (Android version, UI classes
being used, etc.)? I'm willing to help, but be aware I'm far from being an
Android UI expert :)
Original comment by [email protected]
on 19 Jan 2012 at 4:01
from range-seek-bar.
By now I found out some more details:
- The layout has an EditText field above the widget
- It's the EditText that gets the focus (and thus the ScrollView scrolls there)
as soon as the slider is moved
- A stock SeekBar view does not invoke that focusing/scrolling when sliding
- If I comment out the overwritten onDraw(Canvas canvas) in RangeSeeker.java,
the effect is gone (but now drawing of course)
- Even if the code in onDraw() is commented out but merely the empty
overwritten onDraw() remains, the effect is there
I tried different focus settings but haven't found a solution yet. Any help
welcome :)
Original comment by [email protected]
on 19 Jan 2012 at 6:09
from range-seek-bar.
Still couldn't reproduce, but this sounds like a focus issue.
Does it help, if you add these 2 lines in the constructor of RangeSeekBar.java:
setFocusable(true);
setFocusableInTouchMode(true);
This should prevent the EditText to gain the focus while interacting with the
seek bar.
Original comment by [email protected]
on 20 Jan 2012 at 9:38
from range-seek-bar.
Making the range seeker focusable indeed helped - thanks a lot for the hint
(pretty obvious actually, but, heck, I searched elsewhere first :) Maybe you
want to add that to the code too.
Original comment by [email protected]
on 20 Jan 2012 at 2:16
from range-seek-bar.
I updated the code. Thanks for the feedback.
Original comment by [email protected]
on 20 Jan 2012 at 2:26
- Changed state: Fixed
from range-seek-bar.
Related Issues (20)
- Code review request
- Implemented XML usage of widget. HOT 3
- Setting the Min And Max of RangSeeBar after onlistener is called HOT 2
- Code review request
- Need Listener like OnProgressChanged of Seekbar HOT 2
- how to set min and max progress just like calling setProgress(10) HOT 1
- Integer rounding bug.
- Code review request
- Code review request
- Provide widget via Maven
- provide thumbs also for xxhdpi devices
- InstantiationException: HOT 1
- Code review request
- How to use seekbar dynamic
- Code review request
- How to set new range limit? HOT 1
- is this possible to change progress interval to 500,1000,1500 instead of 1,2,3 in range seekbar..? HOT 3
- Displaying the minimum and maximum values by the side of thumbs say in textview HOT 3
- Code review request
- Move project to Github
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 range-seek-bar.