Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wheel width smaller than content #35

Open
GoogleCodeExporter opened this issue Nov 12, 2015 · 3 comments
Open

Wheel width smaller than content #35

GoogleCodeExporter opened this issue Nov 12, 2015 · 3 comments

Comments

@GoogleCodeExporter
Copy link

1. Create wheel with array addapter
2. Array content ["1","2","3","4","5","60","70","80","900",]
3. if only one digit e.g. 1,2,3 are visible, wheel calculates width for 1 
digit. Then if you scroll to 60,70... you will see only 6,7  

What is the expected output? What do you see instead?


What version of the product are you using? On what operating system?
2.1 

Please provide any additional information below.
This bug can is also in demo -> Time 2 ->hours column

Original issue reported on code.google.com by martin.v...@gmail.com on 21 Mar 2012 at 2:36

@GoogleCodeExporter
Copy link
Author

A workaround for this bug is to pass the new NumericWheelAdapter a C-style 
format string as the third paramter, i.e. "%02d" for a 2 digit decimal number 
with 0 padding.

Original comment by blaz...@gmail.com on 22 Apr 2012 at 6:11

@GoogleCodeExporter
Copy link
Author

I had the same problem, fix it changing:
int WheelView at function:
private void buildViewForMeasuring
replace
int addItems = visibleItems / 2;
with
int addItems = viewAdapter.getItemsCount()

Original comment by cjr...@gmail.com on 13 May 2012 at 8:08

@GoogleCodeExporter
Copy link
Author

I'm thinking about this issue.
And I think the best approach is to set the wheel width manually or use items 
with the same width, or use the approach from Comment #1.
The fix above (Comment #2) is not so good since there can be a lot of wheel 
items, or items are loaded from somewhere, so there would be performance issues.

Original comment by yuri.kan...@gmail.com on 14 May 2012 at 11:16

  • Changed state: Accepted

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant