Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Spinner.qml does not allow going through the list backwards #3

Open
ghost opened this issue Mar 30, 2014 · 2 comments
Open

Spinner.qml does not allow going through the list backwards #3

ghost opened this issue Mar 30, 2014 · 2 comments

Comments

@ghost
Copy link

ghost commented Mar 30, 2014

I am not sure if this is a limitation imposed by ListView, but I have hacked around in the file to try to get it not to crash.
onValueChanged: {
if (value >0){listView.currentIndex = value - minValue}
else if(value<0){listView.currentIndex = listView.count - value}
else if(value===0){listView.currentIndex=0}
}
and I think this should (in theory) work... but it does not acquire the correct information
(the Bible verses are not displayed, though the correct books/chapter amounts are)
Basically if (value <=0) {CRASH} in the current state.
Am I missing something?

@iBelieve
Copy link
Owner

iBelieve commented Apr 2, 2014

I think the reason is that my Spinner implementation is quite buggy :(

I was using it for a DatePicker and I was having some issues, so I ended up switching to the built in SDK DatePicker and created a custom style for it to make it look nicer. (See here).

I wonder if there's a component in the SDK that would work for selecting Bible verses, not just dates? I'll investigate.

@ghost
Copy link
Author

ghost commented Apr 3, 2014

Picker is the correct thing to use. I already pushed the change in uBible.
You should check it out, and clean it up if there is a better way of doing it. It doesn't fit the style yet... but the implementation functions quite well for me.

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

No branches or pull requests

1 participant