Comments (4)
I also see this when trying to edit my preferences. I looked into the code, and I believe this is the bug. In MaterialSeekBarController.java, line 89:
mCurrentValue = attrs.getAttributeIntValue(android.R.attr.defaultValue, DEFAULT_CURRENT_VALUE);
The AttributeSet method getAttributeValue takes an int which is an index into the set, but android.R.attr.defaultValue is a constant value (16843245 in my case). So this throws an exception. It is caught, so it defaults to 50.
From reading, I think the correct call should be:
mCurrentValue = attrs.getAttributeIntValue("http://schemas.android.com/apk/res/android", "defaultValue", DEFAULT_CURRENT_VALUE);
I cannot test since I am hooking into the original package via gradle, and am not up for forking and testing that way. :-) I would be curious to know if I am right though.
- Tyler
Update: After posting this comment, I saw the pull request that is waiting. This is the fix for this issue. Request to author to accept the pull request.
from materialseekbarpreference.
This pull request solves the problem: #23
from materialseekbarpreference.
I understand that, but the owner of this repo needs to accept this pull request, yes? I tried a trick to get your fork via gradle and jitpick.io, but haven't gotten it working quite yet. I wasn't really up for doing my own fork just for a one line fix. Thanks!
from materialseekbarpreference.
@manj1790 @tylerwilson @dmytroKarataiev
Sorry for not responding for so long, but I finally came back to work on this lib. I just pushed a new release that fixed most of the known bugs(and added a bit of a new stuff). Though notice that it has some breaking changes, so you'll have to edit couple of xml/java lines manually to make it to work.
Read README.md for more deteils :D
from materialseekbarpreference.
Related Issues (20)
- dependency tag does not enable SeekBarPreference HOT 2
- Bug
- Особые параметры
- Does it support icon setting? HOT 1
- measurement unit for singular item
- Default Value does not works
- Duplicate seek bar in a RecyclerView HOT 1
- Dependency upon activity android:theme setting
- Two seekbars, one doesn't update. HOT 1
- seek bar does not catch drag when used in a navigation drawer
- value not shown with narrow view
- Support library conflicts HOT 1
- Measurement unit value update
- MAX and MIN AND INTERVAL BUG
- Rendering does not match with other preferences on legacy api levels
- Dialog translation for "Wrong Input!"
- Exception raised during rendering
- Class cast exception HOT 2
- setCurrentValue(int) doesn't work?
- update androidX HOT 2
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 materialseekbarpreference.